Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Let the business return to the database

2025-04-05 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)06/01 Report--

Let's go back to 2000, when most of the popular MIS systems adopted the C PL/SQL S architecture, that is, fat clients developed by tools such as PowerBuilder/Delphi/VB directly connected to Oracle or other databases through OCI or other interfaces, and business logic was implemented on the database side, that is, stored procedures, functions, triggers, etc., were called by fat clients through PL/SQL, T-SQL language, etc. One of the big problems in Cpact S architecture is that it is not conducive to expansion. Because Client connects directly to the database, it is easy to exhaust the database resources (number of connections, server memory, etc.) when the business is busy, resulting in business interruption or even inability to handle.

In order to solve this problem, add an extra layer between Cramp S and replace C side with B side, that is, add an extra middle layer, and replace fat clients with thin clients such as browsers. The database connection is managed by the middle tier, and the business logic realized by the stored procedure is changed to the middle tier, which makes many server languages (the most famous one is Java) have been widely promoted and applied. The structure of B/S/S degenerates the role of database to the role of data storage (Data Container), plus some logic for adding, deleting, modifying and querying. With the continuous growth of the amount of data, the interaction between the middle tier and the database is becoming more and more frequent, and the contradiction between the inefficiency of data processing and users' desire to obtain results quickly and efficiently is particularly prominent. First of all, it takes time to transfer data from the database side to the middle tier; secondly, when using the middle-tier development language (most of which use Java) to deal with large quantities of data, the efficiency is much lower than that of Cpicket + (especially in the use of system resources); thirdly, if you still need to store it after processing, you also need a network transmission. How to solve this problem? Let the business return to the database is an effective solution.

To let the business return to the database does not mean that the development of the business application system should adopt the original Cmax S architecture, but on the basis of the three-tier structure, the implementation of part of the business logic (especially where frequent data interaction and data processing are needed) can be returned to the database side. At this time, efficient languages such as Cpicket + can be used to expand and develop the database. Process or analyze a large number of data on the database server to reduce the back-and-forth transmission of the network and improve the overall efficiency of the system.

How to efficiently implement the application system business logic of the database? Stored procedures are a good option for Oracle/SQLServer, and although this option feels Low and counterproductive and out of fashion, it is an effective and efficient option, especially in Oracle-centric application scenarios. If it is PostgreSQL, in addition to stored procedures, you can also develop Extension, using C +, Python, Java or even JS. Of course, nothing is more efficient than C language.

Instead of spending a lot of resources on the middle tier, it is better to invest resources in the background database to form a database cluster. In the application environment of distributed database, each node real-time data storage node is also a computing node, simple, effective and efficient.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report