I was struggling to overcome this problem! Went trough most of the similar posts over here however had no luck.
Deployment was fine but problem occurred during runtime. I am working with GlassFish 3.1.2.2 and use maven, application is deployed as a WAR with multiple JARs and using EJB3, JPA, CDI.
A stateless session bean is a type of enterprise bean, which is normally used to perform independent operations. A stateless session bean as per its name does not have any associated client state, but it may preserve its instance state.
An instance of a stateful session bean has a unique identity that is assigned by the container at create time. Stateless: A stateless session bean does not maintain conversational state. Instances of a stateless session bean have no conversational state.
A stateless session bean is a type of enterprise bean which is commonly used to do independent operations. It does not have any associated client state, but it may preserve its instance state.
There are 3 important annotations used in stateless session bean: @Stateless. @PostConstruct. @PreDestroy.
FINALY I have found the cause: In one of my jar file with session beans I had a missing beans.xml file in src/main/resources/META-INF directory.According to cdi spec this file is needed by the jar to be recognised as a bean archive.Hope this will solve problems for others as well! cheers bb
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With