This content has been marked as final.
Show 2 replies
-
1. Re: Not seeing updates in same TX?
zedmanauk Sep 20, 2001 2:32 PM (in response to zedmanauk)JBoss 3.0.0alpha as of today also has the correct behavior, like 2.4.0. Here's a snippet of code that I'm running in a transaction:
public void go(long ID, long linkID) { try { EJBTest ejbtest = getEJBTest(ID); long origLinkID = ejbtest.getLinkID(); ejbtest.setLinkID(linkID); Collection coll = getEJBTestByLinkID(origLinkID); for (Iterator i = coll.iterator(); i.hasNext(); ) { EJBTest test = (EJBTest) i.next(); System.out.println("ID: " + test.getID() + " linkID: " + test.getLinkID()); } } catch ... }
Starting with two entries:
ID=1, LinkID=1
ID=2, LinkID=1
I run go in a tx with parameters (1, 2).
In JBoss 2.4.0 (and 3.0.0alpha), the println returns:
ID: 2 linkID: 1
as it should
In JBoss 2.4.1 (and 2.4.1a) it returns:
ID: 1 linkID: 2
ID: 2 linkID: 1
which means the finder is not working correctly.
Is this a bug in JBoss? Should I go ahead and put it on the bug list? -
2. Re: Not seeing updates in same TX?
juha Sep 21, 2001 7:21 PM (in response to zedmanauk)Submit as a bug. I think the behavior should be consistent across versions.