Hello.

Given:

  • have a fat client. Containing a bit of business logic, which he would not know.
  • There is a database with an "interface" in the form of stored procedures that implement a lot of business logic. There is an interface for the client and an interface for the server.
  • There is a server that does not perform server functions in the full sense, but performs some of the functions that cannot be performed by stored procedures. There is an interface for the client.

The thick client, respectively, interacts directly with the database (in terms of data manipulation) and with the non-server (in terms of obtaining functions implemented there). The underserver also interacts with the database for data manipulation and with the client (one of the options for interacting with the client is the subscriber publisher).

Task:

It is necessary to implement new functions of the system. This can be done in several ways, and the estimate in hours in both cases is approximately equal.

  1. Implement everything new in the stored procedures on the database side and some functions on the client side, do not touch the server
  2. Implement everything new on the server side, slightly touching both the stored procedures (in terms of increasing the data presentation options) and the client (in terms of displaying new functions).

Problem

My intuitive “better” says that it is right to move in the direction of the classic three-link, respectively, without loading the client and the database with new functions, but loading the server. And if possible, if the clock will allow, then unload the database and the client from the business logic that they do not need. But even if this cannot be done, it is still better to move in that direction.

The lobby of aggressive basist-oraklisto-msskuelnikov believes that everything must be done first option.

And here comes the argument. What are the pros and cons of these options? Than three-star is better, and the worse the client-base interaction? Maybe my instinct fails me?

Arguments I Found

  • security. Three-link will allow theoretically in general to block access to the database from the client machine, thus securing this database. Client-base is not.
  • scalability. In the case of an increase in the number of databases or servers, a client who does not have a direct connection with the data may be unaware of their device and organization. The maximum that he will need to know is the addresses of other servers. There is no client-base, and there you have to either seriously finish the client's logic, or form db-links and finish the logic of the "correct" database, forming the hierarchy of the database.
  • performance. Scalability allows you to significantly affect performance.

Something else? Or something written - sucked from the finger? Thank you in advance.

Update

The server was needed because there is a network of information collectors, the accumulation of data from which it is reasonable to do on the server. Then this information should get into the database, and if there is a subscription from the client for some information, the client should be notified of its receipt. The fact that we are wise - yes, and this is obvious. The fact that, in theory, the server should carry the business logic - yes, but why?

Update 2

Business logic from a client can be transferred not to a server, but to stored procedures. Now my colleague suggested that requests to the database with JOINs can increase the load exponentially, and one request to the database with the 3rd join can cost more in time and workload than 3 requests to the database and management unloaded on the server side in the RAM.

  • @smallFish want to leave behind the server only the accumulation and alerts? - smackmychi
  • @smackmychi, no, I want to pick up a set of arguments that would convince the aggressive basist lobby so that they do not remain offended when I say that we will do the server. - Arkady
  • You did not describe the volumes. If three people drive in two documents a day, then the Excel will cope ... The three-star scales easily, it’s true, but for the three clients, it’s possible to set up dedicated servers — it smells like a cut. :) - Yura Ivanov
  • @Yura Ivanov right now with the cut is not so simple. MB just people did not go into details. - smackmychi
  • @Yura Ivanov, we are talking about the architecture of software, and not PAK. Yes, and usually cut, without asking the development team. ) - Arkady

2 answers 2

Something confuses me. If a fat client was developed, then why did the server have to be done with those functions that could be implemented in a fat client? In other words, people did three-tier architecture, but they were too smart. In theory, the server should carry a large, if not all, if possible, business logic.

Update

You have already listed. And configurability in the pros. Again, the presence of business logic on the client increases the load on the communication channel. Developing a thin client for various platforms is obviously easier.

    Agree with Nicolas Chabanovsky. But I want to add that the presence of business logic in a thick client, possibly due to risks - lack of communication? The three-tier architecture, in my opinion, is easier to maintain business logic in one place, data in another, everything is logical, clear and understandable.

    As an option, in order to circumvent this risk, while not using a fat client, this is using a distributed architecture. Those. install server (server, database) + thin client on each information object. Collects data - the central server.