3-tier web architecture: are layers profitable on separate machines?

For the client I work for, there is a standard in which they require that the data layer of the new applications be wrapped in a web service and place the machine separately from where the business layer will be located. Can someone tell me what are the benefits of this? It seems to me that this causes more problems than it solves:

  • It causes much more traffic / CPU time - it generates XML soap requests / responses, opposite to direct connection to the database.
  • It’s hard to debug - you need to debug two separate projects opposite to one

I assume this is potentially due to security issues (where presentation machines are exposed to the Internet and data-tier machines are not); however, I cannot figure out how safer it is than connecting directly to the database: the account in the database should not have more access than the web service shell.

Did I miss something?

+3
source share
6 answers

I think the reason is the same as for transferring the domain and business logic to stored procedures. Provide secure access to data for several applications and clients running on different platforms, while data integrity checking and other rules are there at the data level.

, . , .

+3

, .

, , - , , . , 3 -, , "" "" 3 , "" -. , DAL ( ).

"" . - (, ..), , , - .

, DAL/BLL/UI (, DLL ) , /.

- - -, - . -, , , -, ( ala ).

, . . , , , , . , . , - , .

, , "" . -, ( -), , "-", -, "" .

, , , , , - -, , .

+2

, -, .

  • ( , , ), (, JDBC, ODBC,...). , -.

  • -, , . -, , , . .

  • - , . , - . . webservice , , ( ), , , , .. ( , ).

, JDBC/ODBC . - - ( ).

+1

, . , .

, .

, - - COBOL.

+1

, .

  - Database Node
        | (database access protocol)
  - Data Access Layer/Business Logic Layer Node
        | (web services/RMI/CORBA/other protocol)
  - Presentation Layer Node     

- DMZ, BLL/DAL (node). - " ". DAL- -, node. - (Java,.NET, - ).

+1

So it looks like you have the Web and Business logic on one server and the data access code on the second server. This is unusual since business logic is typically separated from the web server by a data access code on a separate server. The advantage of this is that all your code logic (business) will live in a protected area (and not on a public web server) with a data access code. Your existing web services will then expose the business logic API, not just the data access code.

0
source

Source: https://habr.com/ru/post/1719389/


All Articles