Life cycle methods in stateless Session Beans?

Answers were Sorted based on User's Feedback



Life cycle methods in stateless Session Beans?..

Answer / krishna

Methods are:
0) Class.newInstance()
1) ejbCreate()
2) setSessionContext()
3) ejbCreate()


Does Not Exist state & Method-Ready Pool are two status of the Beans


as per my knowledge Stateless Session Beans will not contain ejbActivate()& ejbPassivate() methods

Is This Answer Correct ?    2 Yes 0 No

Life cycle methods in stateless Session Beans?..

Answer / sulthan sheriff

The stateless session bean's life cycle has two states: the
1-------->Does Not Exist state
2-------->Method-Ready Pool.
This is the Stateless session bean Life cycle

Is This Answer Correct ?    3 Yes 2 No

Life cycle methods in stateless Session Beans?..

Answer / janet

ejbCreate()
setSessionContext()
ejbActivate -- never called
ejbPassivate()
ejbRemove()

Is This Answer Correct ?    1 Yes 1 No

Post New Answer

More EJB Interview Questions

What is an entity and its types?

0 Answers  


Life Cyle methods in Entity Bean with Bean Managed Persistence

1 Answers  


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.

0 Answers  


Which of the recommended practices to be performed in the ejbpassivate() method of a stateful session bean?

0 Answers  


In my project iam integrating telephone line using some bridge. To connect my project to that telephone line they have give some jar file. Using dat i connected with that.. To handle that event like call attented, call disposed and idle time they have give one event listener class.. I did every thing and this class is alsoo called when a particular event is fired. The only thing is i wanna call EJB from that event listener method.. But the EJB is not getting initated and exception is thrown. This below shownn error is occured only i try to call it from this event listener class. In other places EJB calling is working fine.. javax.naming.NoInitialContextException: Cannot instantiate class: org.jnp.interfaces.NamingContextFactory [Root exception is java.lang.ClassNotFoundException: org/jnp/interfaces/NamingContextFactory] at javax.naming.spi.NamingManager.getInitialContext (NamingManager.java:657) at javax.naming.InitialContext.getDefaultInitCtx (InitialContext.java:247) at javax.naming.InitialContext.init(InitialContext.java:223) at javax.naming.InitialContext.<init> (InitialContext.java:197) at com.kgisl.etrac.desk.servicelocator.ServiceLocator.getInitia lContext(ServiceLocator.java:82) at com.kgisl.etrac.commonUtils.EventListener.getAdministrationE JBRemote(EventListener.java:206) at com.kgisl.etrac.commonUtils.EventListener.CallDispositioned (EventListener.java:65) Caused by: java.lang.ClassNotFoundException: org/jnp/interfaces/NamingContextFactory at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:242) at com.sun.naming.internal.VersionHelper12.loadClass (VersionHelper12.java:42) at javax.naming.spi.NamingManager.getInitialContext (NamingManager.java:654) ... 6 more javax.naming.NoInitialContextException: Cannot instantiate class: org.jnp.interfaces.NamingContextFactory [Root exception is java.lang.ClassNotFoundException: org/jnp/interfaces/NamingContextFactory] at javax.naming.spi.NamingManager.getInitialContext (NamingManager.java:657) at javax.naming.InitialContext.getDefaultInitCtx (InitialContext.java:247) at javax.naming.InitialContext.init(InitialContext.java:223) at javax.naming.InitialContext.<init> (InitialContext.java:197) at com.kgisl.etrac.desk.servicelocator.ServiceLocator.getInitia lContext(ServiceLocator.java:82) at com.kgisl.etrac.commonUtils.EventListener.getAdministrationE JBRemote(EventListener.java:206) at com.kgisl.etrac.commonUtils.EventListener.CallDispositioned (EventListener.java:65) Caused by: java.lang.ClassNotFoundException: org/jnp/interfaces/NamingContextFactory at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:242) at com.sun.naming.internal.VersionHelper12.loadClass (VersionHelper12.java:42) at javax.naming.spi.NamingManager.getInitialContext (NamingManager.java:654) ... 6 more It would be more help full if i get the solution 10x in advance balaji

1 Answers  


What is the major difference SessionBean and EntityBean?

3 Answers   KPIT, Wipro,


Write the basic requirement of a cmp entity based class in 2.0 from ejb 1.1?

0 Answers  


What is ejb role in j2ee?

0 Answers  


Explain the concept of connection pooling feature of ejb container?

0 Answers  


What is backing bean?

0 Answers  


Describe client view of an Enterprise JavaBeans component?

1 Answers   Wipro,


What is a ejb container?

0 Answers  


Categories