in Design Patterns by

What are the entities of Service Locator pattern?

► Click here to show 1 Answer

0 votes

Following are the entities of this type of design pattern.

  • Service - Actual Service which will process the request. Reference of such service is to be looked upon in JNDI server.

  • Context / Initial Context - JNDI Context carries the reference to service used for lookup purpose.

  • Service Locator - Service Locator is a single point of contact to get services by JNDI lookup caching the services.

  • Cache - Cache to store references of services to reuse them.

  • Client - Client is the object that invokes the services via ServiceLocator.

Learn More with Madanswer

Related questions

0 votes
asked Oct 16, 2019 in Design Patterns by DavidAnderson