How do you decide whether you should use session, entity or message driven bean?



How do you decide whether you should use session, entity or message driven bean?..

Answer / Anuj Kumar Bhardwaj

The choice between Session, Entity, and Message-driven Beans depends on the specific requirements of the application. Session Beans are used for business logic, Entity Beans represent persistent data, and Message-driven Beans handle asynchronous messages. When designing an application, it's essential to consider the application's needs in terms of state management, persistence, concurrency control, transaction management, and messaging before deciding which type of EJB to use.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More EJB Interview Questions

An instance of stateful session ejb when accessed simultaneously from more than one clients on same vm results in remoteexception or ejbexception. In case the client is a servlet thread, which of the techniques can be used to avoid remoteexception/ejbexception?

1 Answers  


Can the primary key in the entity bean be a Java primitive type such as int?

2 Answers   CTS,


How 'messaging' supported in EJB 2.0 Specification?

1 Answers  


Explain the concept of connection pooling feature of ejb container?

1 Answers  


Can i write business logic methods in entitybean?

3 Answers   HCL,


can anyone explain me the workflow of EJB.I have developed an app. in WSAD using an example that contains CMP and session bean.But i am not able to understand the basic flow between diffrent packages.

1 Answers  


What is the difference between ejb and spring?

1 Answers  


What transaction attributes does Java Bean containers support?

1 Answers  


What is ejb context?

1 Answers  


What is the meaning of acid in the connection of transaction management?

1 Answers  


Can stateful session beans are persistent?

2 Answers  


What is enterprise javabeans (ejb) container?

1 Answers  


Categories