tags:

views:

3080

answers:

3

We are in the middle of creating an n-tier Silverlight LOB application and are considering the use of .NET RIA Service. We are unclear where this fits in relation to our current WCF service API. Our Current architecture is:

Silverlight <--> WCF Service <--> Business Logic <--> Entity Framework Model <--> Database

Having watched Nikhils Mix 09 presentation it would appear that .NET RIA Services would replace our WCF and BusLog sections:

Silverlight <--> RIA Services <--> EF Model <--> DB

Which is fine, expect that we need to have a standard SOAP endpoint API exposed for use by other applications (Biztalk,Integration etc). Can .NET RIA Services be exposed as SOAP endpoints without the asynchronous requirement?

How easy is it to implement a WCF service over a .NET RIA Service? Do you know any good online examples of this?

Thanks, Mark

+7  A: 

Yes – In the next CTP for RIA Services we will have some very nice support for defining WCF service (via Astoria and eventual vanilla WCF) that exposes your business logic in RIA Services. So you’d have two heads on your RIA Services implementation.

Silverlight <---> RIA Services <---> EF Model <---> DB WCF Services <--->

I’d say this model makes sense if the primary goal is the Silverlight application, however if the primary goal is the WCF service, I’d hang with the model you have today.. Does that help?

..brad

Thanks brad, your advice goes along with what we are doing. It's a shame that we can't expose a WCF endpoint from .NET RIA Services as we need to have a service API, but handling entities manually over WCF is causing us a great deal of pain at present. Mark
Mark Cooper
A: 

We're looking at the exact same scenario. Right now, we're thinking of going with this model:

Silverlight <--> RIA Services <--> WCF Service <--> Business Logic <--> Entity Framework Model <--> Database

We will be able to host our WCF services in a variety of bindings. We'll use an inProc call from RIA to WCF for the Silverlight app. For external consumers of the WCF services, we'll host them with a wsHttp endpoint.

Thus in our scenario we get the best of both. RIA services becomes part a set of presentation services for our app that eases the burden of programming the Silverlight app (i.e. async). The downside is that we've added an extra layer.

Thoughts?

I'll be honest, I don't think this is a good idea. Putting RIA Services over your WCF Service, you'll lose all the benefits of your EF model once you go past the WCF layer, so you'll be building your .NET RIA Services on top of disconnected objects and proxied objects that are created by specific services, and so not compatible with other services where they are used.
Mark Cooper
Well Mark, then it appears we're heading down a bad path as well. Our path was:Silverlight <-> RIA Services or WCF Service <-> WCF Facade <-> App Services <-> Domain Model <-> nHibernate <-> SQLThe RIA services || WCF Service lives outside our firewall and is built for this app only. The Facade layer is inside, still one facade per application. The App services and domain model are POCO and shared by all of our applications.Our choice at hand is do we introduce RIA services to get simplified configuration and magical Authentication and Authorization, or plain WCF ?
basscinner
It looks like this is all change for the next release :-) RIA Services are called WCF RIA Services and will support additional end points.
Mark Cooper
A: 

Guys, sorry for stupid question, but what is a purpose of the .NET RIA Services in the structure: Silverlight <--> RIA Services <--> WCF Service <--> Business Logic <--> Entity Framework Model <--> Database ?

What does "RIA Services" layer bring into your app if you already have "Silverlight <--> WCF Service <--> Business Logic <--> Entity Framework Model <--> Database"? Authentication? Validation? Is it relly asset for you?

Probably I don't know some very useful features of the RIA Services? So could you please point me to the good doc for that?

Many thanks.

Budda
Hi Budda, You should ask this as a new question, pop a link back to this question for reference. Best, Mark
Mark Cooper