[jboss-user] [JBoss Seam] - Re: Could not find Stateful bean

galo.navarro do-not-reply at jboss.com
Thu Sep 28 11:21:24 EDT 2006


I had the same exception in a different context but I think it might help.

I was using a Stateful bean in a servlet. It was initialized in the init() method and the reference kept in a static variable. I was running my app normally, but i let my session expire and when i tried accessing the servlet again, the exception popped up. 

Being a stateful bean, is it possible that the container destroyed that instance but the servlet kept the reference? When a new request was sent it was trying to use the old instance even though this was a new session, and thus the error.

It is a stateful bean, so it didn't make sense to share it for all the instances of the servlet. I'm now loading the bean for each session, and everything works fine. 

Could you have a similar problem somewhere?

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3974927#3974927

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3974927



More information about the jboss-user mailing list