N-Tier Web Applications using ASP.NET 2.0 and SQL Server 2005
Posted on 2008-01-11 14:34 青松阳光 阅读(342) 评论(0) 收藏 举报
Part 1
In this installment, you have understood the new features of SQL Server 2005 utilized to create stored procedures using managed language such as C#. After that, you have also seen the steps involved in creating the data access components using TableAdapter Configuration Wizard that greatly simplified the process of creating a data access component. In Part-2 of this article, we will see how to consume this data access components from a business logic layer. We will also look at the use of master pages in creating the user interface, and caching features in ASP.NET 2.0 and so on.
Part 2
In this series of articles, you have understood a wide range of ASP.NET and SQL Server 2005 features utilized to create an N-Tier ASP.NET 2.0 web based application. The sample application discussed in this article showcased the new features of .NET Framework 2.0 such as TableAdapter Configuration Wizard, and App_Code directory. This article also discussed how the ObjectDataSource control supports layered application design by allowing you to directly bind the output of an object's method directly to the controls in an ASP.NET page. The architecture used by the example application provides a number of advantages. They are as follows:
- Changes to the user interface or to the application logic are largely independent from one another, allowing the application to evolve easily to meet new requirements.
- Creating stored procedures using managed code provide performance improvements because of the compiled logic that gets executed close to the database server.
- If changes to the middle layer classes are required, they can be modified and deployed immediately onto the App_Code directory and the ASP.NET will pick up those changes immediately and compile them on-demand. This enables easy deployment of upgrades to the existing classes that contain the business logic.
- Using master pages in the presentation layer provide a huge advantage in terms of providing a consistent look and feel across all the pages in the web site.
- Caching of database tables results in increased performance. Also the new database cache invalidation provides the ability to keep the changes in the database up-to-date with the data in ASP.NET cache.
- The ability to generate data access logic classes (using Data Component Wizard) without writing a single line of code is a very powerful feature can go a long way in increasing the developers' productivity.
- ASP.NET 2.0 facilitates N-Tier application design by providing the ObjectDataSource control that is specifically suited for consuming middle tier objects. This new control enables "code-less" data binding by providing the ability to seamlessly integrate the data returned from the middle layer objects with the ASP.NET presentation layer.
 
 
                     
                    
                 
                    
                 
 
         
                
            
         浙公网安备 33010602011771号
浙公网安备 33010602011771号