because it would be inconsistent. If you use a statetful it means you
need a state so if you have a new instance you loose your state
Romain Manni-Bucau
Twitter: @rmannibucau
Blog: http://rmannibucau.wordpress.com/
LinkedIn: http://fr.linkedin.com/in/rmannibucau
Github: https://github.com/rmannibucau



2014-01-30  <[email protected]>:
> Hi,
>
> I have a question related to this scenario:
>
>
>>> Hi all, given two Stateful EJBs (A and B). B is injected into A by
>>> using @EJB annotation. After $minutes the container removes my
>>> timed-out EJBs / 16.09.11
>>>
>> org.apache.openejb.core.stateful.StatefulContainer$StatefulCacheListener
>>>
>>> timedOut INFO: Removing the timed-out stateful session bean instance
>>> 583c10bfdbd326ba:a2c5b15:143e3aeafea:-7ffb/
>>> When I try to use EJB B in
>>> A's method I get the following exception *javax.ejb.NoSuchEJBException:
>>> Not Found* then, if I try again, I get: *javax.ejb.NoSuchEJBException:
>>> reference is invalid for B* Even using lookup same exceptions are
>>> returned. Is there any way to avoid this problem without annotate my
>>> EJBs with @StatefulTimeout(value = -1)?
>
>
> Why won't the container re-create the EJB Session, that is, give me a new
> instance of the same Stateful reference?
>
> I'd like to have a business process state stored in a SFSB, but give it a
> timeout, so they won't last too long fo inactive users. But I'd like also to
> have the option to restart the process anew. I can't find a way to do this
> using SFSB.
>
>
> []s, Fernando Lozano
>

Reply via email to