0
12kviews
What are the main components of EJB Framework?
1 Answer
3
489views
  • EJB (Enterprise Java Beans) is a server-side component that executes specific business logic.
  • It enables development and deployment of component based, robust, highly scalable & transactional business application.

enter image description here

1 ) EJB Server :

  • It provides execution environment for server components.
  • It hosts EJB containers.

2) EJB Container:

  • It serves as interface EJB and Outside World.

Container hosts following components:

  • EJB Object: A client invokes beans instance through EJB Object. It is called Request Interceptor.
  • Remote Interface: It duplicates machines of bean class.
  • Home Object: It is the object factory bean where client can create or destroy object.
  • Home Interface: It provides machine for creating and destroying, finding bean object.
  • Local Interface: It is used instead of EJB objects for faster access.

    The type of container depends on beans they contains i.e either transient or persistent beans.

3) Enterprise Beans:

  • They are EJB Components that encapsulates business functionalities in an application.
  • Container provides security to enterprise beans.
  • Types of Enterprise Beans:

    • Session Beans(Synchronous)
    • Message Driven(Asynchronous)
    • Entity Beans (Data/Records in DB).

4) EJB Client:

  • It makes use of EJB beans to perform the operations.
  • Client locates the container using JNDI (Java Naming & Directory Interface)
  • Then the client invokes JB Beans machines through container.

5) Deployment Descriptor:

  • It lists the bean properties and elements like:

    • JNDI Name for Bean.
    • Home and Remote Interface.
    • Bean Implementation Class.
    • Environment Variables.
    • Access Rules or Rights.
    • Beans Management, Etc.
Please log in to add an answer.