Java Design Pattern - Business Delegate

I have some questions regarding Java design patterns. I want to know why search services and business services are precisely used in the business delegate template. I appreciate as much detail and information as possible.

+4
source share
2 answers

The business delegate template attempts to separate customers from business services. For this you need:

  • The business delegate , which is the object used by customers to request services;
  • a search service is a bridge used by a business delegate to search for services; it encapsulates the search algorithm in accordance with the request made by the delegate;
  • A business service is an actual service offered to customers, usually an EJB or similar J2EE concepts.

By the way, this page explains everything quite clearly.

+10
source

A business delegate acts as a business abstraction on the client side; it provides the abstraction and, therefore, the concealment of the implementation of business services.

Using a business delegate reduces the connection between presentation-level clients and the Business Services system

The business delegate uses a component called the search service. The Lookup service is responsible for hiding the basic implementation details of the business service search code.

A business service is a business-level component, such as a corporate bean or JMS component, that provides the required service to a customer. It is used to invoke business methods on behalf of the client.

Composition:

enter image description here

More information on this template can be found on the oracle website.

+2
source

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


All Articles