Hi!
"Bordet, Simone" wrote:
> Hey,
> > Hi Simon!
> > Thanks for your answer. That will probably solve the problem. I can't
> > test it right now, because we just discovered a new bug that
> > prevents us
> > from getting through the process :-(. I have two more questions now:
> >
> > 1) If the bean is not marked reentrant and I try to call it in the
> > described way, shouldn't there be an other error message than just
> > TIMEOUT ? Perhaps we could add the hint, that it might be a
> > problem with
> > reentrant calls.
>
> EJB Spec says we should throw RemoteException in such a case. Due to a
> marginal problem we are fixing, we disabled this for now.
>
> > 2) If I mark a bean as reentrant, which effects do I have to expect ?
> > Does this also mean the bean could be visited from two or more callers
> > at the same time ?
>
> See EJB 1.1 Spec 9.1.12
...
"Second, since the container cannot, in general, tell a loopback from a
concurrent call from a different client, the client programmer must be
careful to avoif code that could lead to a concurrent call in the same
transaction context."
Does this mean if I am declaring a bean as re-entrant I not only have to
deal with loopbacks (that's a thing I can take care of) but also loose
the assertion, that there will be no concurrent calls from two different
clients ?
How will jBoss handle both situations (if the code is fixed :-) ) ?
Ciao,
Tobias
> > "Bordet, Simone" wrote:
> > >
> > > Hey,
> > >
> > > > Hi!
> > > > I wonder if the following thing is allowed by the EJB specs 1.1:
> > > >
> > > > We have: bean Alice and bean Bob deployed on the container.
> > > >
> > > > 1. AliceHome.create()
> > > > 2. -> AliceBean.ejbCreate(), done
> > > > 3. -> AliceBean.ejbPostCreate()
> > > > 4. -> BobHome.create(Alice)
> > > > 5. -> BobBean.ejbCreate(Alice), done
> > > > 6. -> BobBean.ejbPostCreate(Alice)
> > > > 7. -> Alice.getSomeAttribut(), done
> > > > 8. 6. done
> > > > 9. 4. done
> > > > 10. 3. done
> > > > 11. 1. done
> > > >
> > > > Is this allowed by the specs ? How SHOULD jBoss react ?
> > Right now the
> > > > bean hangs directly at step 7 (BobBean is left but Alice is
> > > > not reached
> > > > !) in my code.
> > >
> > > This kind of beans (Alice) is called reentrant; jboss
> > supports them of
> > > course, simply specify in ejb-jar.xml that the bean is
> > reentrant (see
> > > ejb-jar documentation on where in the xml tree specify
> > this), cause the
> > > default is that they aren't (and hence your problem).
> > > Remember though that use of this kind of beans is
> > discouraged by the EJB1.1
> > > spec.
> > >
> > > HTH,
> > >
> > > Simon
> > >
> > > >
> > > > After waiting a long time I get a TIMEOUT exception (->
> > > > ROLLBACK). There
> > > > is also a bean mentionend in the trace with som XidImpl stuff that
> > > > should not be involved in the proccess at all.
> > > >
> > > > Any ideas ?
> > > >
> > > > Tobias
--
--------------------------------------------------------------
To subscribe: [EMAIL PROTECTED]
To unsubscribe: [EMAIL PROTECTED]
Problems?: [EMAIL PROTECTED]