EJB Interview Questions & Answers

EJB Interview Online Test

Technical interview questions and answers are crucial for clearing an EJB Interview because Enterprise JavaBeans are widely used in enterprise-level, distributed, and transactional applications. Companies evaluate your understanding of session beans, entity beans, message-driven beans, JNDI, lifecycle methods, and container-managed transactions. These concepts often appear in Java developer interviews conducted by TCS, Wipro, Infosys, Cognizant, and Accenture. For freshers and job seekers planning to enter Java-based development roles, EJB forms an important part of backend and enterprise Java interviews. This guide provides the most frequently asked EJB interview questions with answers, explained in simple language to help you understand real-time use cases. Preparing these questions will help you succeed in technical rounds and placement tests focused on Java EE technologies.

Java developers should also master J2EE concepts and explore J2SE fundamentals  for comprehensive enterprise development expertise 

1. What are the two important TCP Socket classes?

Show Answer

2. What technologies are included in J2EE?

Show Answer

3. What is the difference between EJB and Java beans?

Show Answer

4. What is EJB role in J2EE?

Show Answer

5. What is Enterprise JavaBeans (EJB) container?

Show Answer

6. What is in-memory replication?

Show Answer

7. What is Ripple Effect?

Show Answer

8. What is a Clone?

Show Answer

9. What are the types of Scaling

Show Answer

10. What is a Server Group?

Show Answer

11. What is the new basic requirement for a CMP entity bean class in 2.0 from that of ejb 1.1?

Show Answer

12. whats new in the EJB 2.0 specification?

Show Answer

13. How can I access EJB from ASP?

Show Answer

14. What is the relationship between local interfaces and container-managed relationships?

Show Answer

15. What is EJBDoclet?

Show Answer

16. What is the difference between session and entity beans?

Show Answer

17. Is it legal to have static initializer blocks in EJB?

Show Answer

18. What are transaction isolation levels in EJB?

Show Answer

19. Can Entity Beans have no create() methods?

Show Answer

20. When should I adopt BMP and when I should use CMP?

Show Answer

21. Can I develop an Entity Bean without implementing the create() method in the home interface?

Show Answer

22. What is the need of Remote and Home interface. Why cant it be in one?

Show Answer

23. What is bean managed transaction?

Show Answer

24. What is an EJB Context?

Show Answer

25. How can I call one EJB from inside of another EJB?

Show Answer

26. What happens if remove( ) is never invoked on a session bean?

Show Answer

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

Show Answer

28. What is an EJB Context?

Show Answer

29. What happens if remove( ) is never invoked on a session bean?

Show Answer

30. How EJB Invocation happens?

Show Answer

31. How does a servlet communicate with a JSP page?

Show Answer

32. What is abstract schema?

Show Answer

33. What is local interface. How values will be passed?

Show Answer

34. What is Message Driven Bean?

Show Answer

35. What are the call back methods in Entity bean?

Show Answer

36. What are the services provided by container?

Show Answer

37. What is deployment descriptor?

Show Answer

38. How many EJB Objects are created for a Bean?

Show Answer

39. What is re-entrant. Is session beans reentrant. Is entity beans reentrant?

Show Answer

40. Can i map more than one table in a CMP?

Show Answer

41. Is Decorator an EJB design pattern?

Show Answer

42. What is the difference between sessioncontext and entitycontext?

Show Answer

43. Does stateless Session bean create() method contain any parameters?

Show Answer

44. What is difference between EJB 1.1 and EJB 2.0?

Show Answer

45. What is the difference between ejbCreate() and ejbPostCreate

Show Answer

46. Why does EJB needs two interfaces(Home and Remote Interface)

Show Answer

47. What are the optional clauses in EJB QL?

Show Answer

48. Can I invoke Runtime.gc() in an EJB?

Show Answer

49. What is Remote client view?

Show Answer

50. What is Local client view?

Show Answer

51. What is EJB client JAR file?

Show Answer

52. What is EJB container?

Show Answer

53. What is Deployment descriptor?

Show Answer

54. What is EJB server?

Show Answer
Questions and Answers for Competitive Exams Various Entrance Test