It’s been a long time coming, but we have now published updated and new NuGet packages for RIA Services, including an update to RIAServices.EntityFramework that adds support for EntityFramework 5.0.0 (including all versions >= 4.1).
Each of the following NuGet packages was uploaded to nuget.org today with the version number of 4.2.0. Aside from improving the EntityFramework support with a detailed README, NuGet packaging updates, and the creation of a couple of new packages from existing Toolkit assets, there are no further updates across the features. I do hope the new and updates packages are helpful though!
RIAServices.EntityFramework
RIAServices.EntityFramework provides the DbDomainService<T> class which can be used to create Domain Service classes for use with a DbContext from the EntityFramework package. This package supports versions of EntityFramework starting with EF 4.1, including EntityFramework 5.0.0.
Special thanks to the EF Team’s Brice Lambson, as this package would not have been possible without his work on it. The package includes a README.txt that NuGet will open automatically, as there are some known installation issues with the package, but they all have straight-forward solutions within your web.config file.
For more information, Varun Puranik’s blog post from when this package was initially published is still applicable.
Note that while the NuGet packages are now compatible, there may be features in EF 5.0+ that will not be compatible with RIA Services due to how it serializes entities. Unless a property’s data type is known to RIA Services, it is unable to serialize the property. Therefore, properties such as Geometry will not be supported.
RIAServices.EF4
RIAServices.EF4 provides the LinqToEntitiesDomainService<T> class which can be used to create Domain Service classes for use with an ObjectContext from Entity Framework 4.0. This package can be used in place of a GAC reference to the System.ServiceModel.DomainServices.EntityFramework assembly, making bin-deployment easier. The dependency on RIAServices.Server provides the other assemblies that are needed for the server-side runtime of RIA Services.
RIAServices.LinqToSql
RIAServices.LinqToSql provides the LinqToSqlDomainService<T> class which can be used to create Domain Service classes for use with a DataContext class from Linq to Sql.
RIAServices.WindowsAzure
RIAServices.WindowsAzure provides the TableDomainService<T> class, as well as the TableEntity and TableEntityContext classes that can be used to create Domain Services backed by Windows Azure Table Storage.
For more information, Kyle McClellan’s blog has some good documentation:
- http://blogs.msdn.com/b/kylemc/archive/2010/11/01/ria-services-and-windows-azure-table-storage.aspx
- http://blogs.msdn.com/b/kylemc/archive/2010/11/19/azure-table-storage-associations-with-ria-services.aspx
- http://blogs.msdn.com/b/kylemc/archive/2010/11/19/windows-azure-table-partitionkey-options-for-tabledomainservices.aspx
RIAServices.Server
RIAServices.Server provides the System.ServiceModel.DomainServices.Hosting and System.ServiceModel.DomainServices.Server assemblies in place of the GAC references, making bin-deployment easier. The web.config.transform adds the necessary configSections, HTTP modules, and system.serviceModel elements to make your Domain Services available at runtime. The package also includes a targets file and tools assembly that provides build-time validation of your DomainService classes.
This package can be used instead of going through the Add New Domain Service wizard to prime your ASP.NET web application with the configuration necessary to utilize WCF RIA Services on the Server.
There is one known issue, where some users have experienced duplicate web.config entries getting created as a result of installing this package. To resolve this issue, simply eliminate one of the duplicate entries -- they vary only by character case.
RIAServices.Endpoints
RIAServices.Endpoints provides the Microsoft.ServiceModel.DomainServices.Hosting assembly, which serves the SOAP and JSON endpoints for Domain Services. The necessary web.config entries are added with this package as well.
RIAServices.T4
RIAServices.T4 provides the CSharpClientCodeGenerator class, as well as many supporting classes, which can be used to override the existing code generation pattern for RIA Services.
For more information, Varun Puranik’s blog has a couple of posts:
- http://varunpuranik.wordpress.com/2010/11/05/t4-code-gen/
- http://varunpuranik.wordpress.com/2010/12/02/t4-code-generator-dec-10-update/
RIAServices.UnitTesting
RIAServices.UnitTesting provides a DomainServiceTestHost that can be used to unit test your Domain Services.
For more information, Kyle McClellan has a few blog posts on this package:
- http://blogs.msdn.com/b/kylemc/archive/2011/08/18/unit-testing-a-wcf-ria-domainservice-part-1-the-idomainservicefactory.aspx
- http://blogs.msdn.com/b/kylemc/archive/2011/08/18/unit-testing-a-wcf-ria-domainservice-part-2-the-repository-pattern.aspx
- http://blogs.msdn.com/b/kylemc/archive/2011/08/18/unit-testing-a-wcf-ria-domainservice-part-3-the-domainservicetesthost.aspx
RIAServices.WebForms
RIAServices.WebForms contains the ASP.NET DomainDataSource and DomainValidator controls for using a DomainService in an ASP.NET Web Forms application.