Design, implement a general data access layer for an ASP.NET application
Translation: nxyc_twz@163.com
Summary
In this article, we will explore the design of the N-layer architecture, and our focus will focus on the data access layer (DAT). Our goal is to design, realize an appropriate, scalable data access layer (DAT), thereby designing reliable, multiplexed web applications. I divide this article into two parts, Part 1 we will discuss the system objectives, define data sets, event logs, and httpmodules, which help us understand the Part 2 of this article. In Part 2, we created a small N-layer application, our focus will focus on design, implement the data access layer (DAT). In the following article, you need a SQL Server (Database: Northwind) and a vs.net.
table of Contents:
1. Data Access Layer (DAT) design goal
1.1 System Target
1.2 prototype setting
1.3 Define Data Set
1.4 event log
1.5 httpmodules
2.0 Implementing a general data access layer (DAT)
2.1 Implement a Super Data Access Layer (DAT) class
2.2 Test, assess the performance of SqlDataReader and DataSet objects in commercial layers
2.3 How do I extend this data access layer (DAT) to access multi-layer database?
2.4 How do I apply database transactions at different levels?
2.5 How do I insert and get image data?
The figure shows us a typical 3-layer application, which is divided into three main levels: data layer (DA), intermediate layer, and representation layer (PT).
If you are not familiar with the N layer architecture, I suggest you refer to the following documents:
http://www.c-sharpcorner.com/tutorials/building3tierapppa.asp http://www.c-sharpcorner.com/code/2002/june/adonetwindnaperspective.asp
1. Design a suitable data access layer (DAT)
1.0 system objective
Enterprise-level applications must have the following features:
Sygramability and scalability and performance reliability and management safety
Let us take a closer look at these words above, what is their true meaning?
The synergy of the system is to refer to communication capabilities between different environments, with other internal or external systems. This is very important because we need timely access to our customers in business partners. To complete this important goal, our system must be able to provide relevant Web services. (to be continued)