Can a Session Bean be defined without ejbCreate() method?

  • The ejbCreate() methods is part of the bean's lifecycle, so, the compiler will not return an error because there is no ejbCreate() method.
  • The home interface of a Stateless Session Bean must have a single create() method with no arguments, while the session bean class must contain exactly one ejbCreate() method, also without arguments.
  • Stateful Session Beans can have arguments (more than one create method).
  •  Stateful beans can contain multiple ejbCreate() as long as they match with the home interface definition


Enter your email address to get our daily JOBS & INTERVIEW FAQ's Straight to your Inbox.

Make sure to activate your subscription by clicking on the activation link sent to your email