The Ado.net Data Services Framework is a new extension of the. NET Framework 3.5 SP1, a feature and concept in the previous. NET 1.0-. NET3.5 technology is not a new concept, its main purpose is to be able to easily expose the database services on the network, and then through the URL of the database can be CRUD operations. Ado.net Data Services can use a restful way to showcase the information on the web. This allows applications to present data in the form of data services, which are then applied to Web clients on both the corporate network and the Internet.
REST (representational state Transfer) uses the simplest URL URLs to allow ordinary customers and applications to directly access and write to the database on the remote host. In addition, Microsoft to implement REST Ado.net Data Services, also has a security control, access rights control mechanism, do not worry about security issues.
In the. NET platform, the future. NET Framework 4.0 and Visual Studio 2010 still have versions of the Ado.net Data Services Framework 2.0, as well as a new 4.0 version of System.Data . Services class Library.
My blog site (http://blog.entlib.com/entlibforum) will show you how to use Ado.net Data Servers in n-tier applications, but this article will focus on ado.net data Services The introductory section. Complete the exercise with the following specific actions.
File > New Project > ASP.net Web application ....
Creating a ado.net Data Service through the VS 2008 SP1 is easy, and the first step is to create a asp.net Web application project:
The above will create a ASP.net project with a Default.aspx page. If you only need to create a service, you can delete the Default.aspx file. Then add a new item to the project, select Ado.net Data Service.
In this example we used the Subtextdata database (the background database of the http://blog.entlib.com Open source blog platform), so the ado.net Data Service is named Subtextdata.svc. The steps above will automatically add System.Data.Services and System.Data.Services.Client to your project. Right-click the Subtextdata.svc file and select the "Set As Start Page" option.