Hello

I think this relates exactly to the same problem I am having, see my post
from about 18 hours ago below. When I went back to read the ejb1.1. spec it
seems to suggest that there are 3 different ways a container may behave
between transactional calls on a bean (see mail below), it appears to me
that JBoss is taking option A, which is allowable, but not very useful for
what I want to achieve (i.e. dB access from without the bean).

I am hoping that somebody will rubbish my conclusions and tell me how we can
make JBoss call ejbLoad at the beginning of each transactional set of calls.

If you find any solution to this please do post it.

Best of luck

Luke

---------------------
FROM: Luke StudleyDATE: 07/18/2001 15:29:21SUBJECT:  [JBoss-user] JBoss
Entity Bean Transactions This message is in MIME format. Since your mail
reader does not understand
this format, some or all of this message may not be legible.

------_=_NextPart_001_01C10FD9.171B7B80
Content-Type: text/plain

Hi all
 
In the ejb 1.1 Spec (pdf) 9.5.4 and 9.5.5 (ending and starting new
transactions for entity beans) it mentions 3 options for a container to end
a transaction:
A. mark "not registered"
B. mark "invalid state"
C. ejbPassivate()
 
Which relates to the following actions for starting the next transaction:
A. Do nothing
B. ejbLoad()
C. ejbLoad()
 
Would it be true to say that JBoss implements option A? I am certainly
seeing this type of behaviour with my session wrapped entity beans, i.e. no
ejbLoad() called for new Transactions after the initial find/ejbActivate
combo.
 
If this is the case then you cannot pick up new transaction data changed in
the dB from outside of JBoss without restarting or re-deploying your beans.
Which is quite annoying for the application I have.
 
Is any / all / none of this true?
Is it possible to configure JBoss to use one of the other options mentioned
in the spec? I.e. I basically need ejbLoad to be called on the entity beans
afresh in each transaction.
 
As always any answers appreciated.
 
Thanks
 
Luke
-------------------------------------------------




Message: 3
From: Syed <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Date: Thu, 19 Jul 2001 17:58:20 +0800
Subject: [JBoss-user] ejbLoad not called even when commit-option is C
Reply-To: [EMAIL PROTECTED]

Wehave two entity beans, we use one entity bean for updation which = updates
a few tables and call it U The other entity bean just loads data only, let's
call it R. When we use the bean U to update the data, the data gets updated.
Then we call the bean R to read the data. ejbLoad in R is called the = the
latest data is loaded. Then we use bean U to change the data again and the
data is modified. Now we use findByPrimaryKey in R to find and read the data
but this = time it returns the old data not the data just updated. Then we
put some logging and found that ejbLoad is not called during = second
invocation. I think that if we give commit-option as C means that ejbLoad is
= supposed to be called before every business method invocation which
includes ejbFindByPrimarykey = also.

Is there any other setting which can make the entity beans' ejbLoad = called
whenever ejbFindByPrimaryKey is called.



_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to