Enterprise-level projects never thought about how huge they would be from the beginningFramework, because the initial pressure will not be great. Therefore, scalability has become the core requirement.
Traditional three-tier application layer. Logic layer and data persistence layer. In view of the need to separate servers to reduce server pressure, they are divided into Web servers, business servers, and database servers; and the reasonable and smooth data logic calls between the three, especially the front-end and back-end, are what I need to record. Key point.
Front-end application service, request
apiInterface, Get the data rendering page. 1. Build the
MVC framework, introduce the public Model and interface call class library. Use . The bootstrap
framework builds a mobile-first front-end page framework. 3. Call the back-end interface and render the page according to business needs.
1. Under the premise that the interface is stateless, determine the permission level and corresponding response of the request. Legality. (Rewrite Http request, add request legality judgment, AOP-like aspect judgment)
2. Provide or base on unified data model for smooth interaction between front and back ends. Request and return models, build dependency inversion relationships. Simplify unified request code)
3. Access the database, perform logical processing, and persist the data to the database
##SqlServer database#. ##Use ibatis as the ORM framework to improve freedom and scalability on the premise of database interaction efficiency and concise code writing.
The above is the detailed content of Asp.net (1) Basic three-layer framework project: Web server, business server, database server. For more information, please follow other related articles on the PHP Chinese website!