The fix is in EntityInstanceInterceptor.invokeHome. It is inserting the bean in the cache in a finally block. It should check to see if an exception was thrown before inserting the bean into the cache. I'll fix this on 2.4.4 and 3.0.
Bill > -----Original Message----- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]On Behalf Of Ole > Husgaard > Sent: Thursday, October 18, 2001 12:49 PM > To: [EMAIL PROTECTED] > Subject: [JBoss-dev] Bug in cache > > > Hi, > > Seems that we have a entity bean cache bug in both the > stable and development series that affects both BMP and > CMP entity beans. > > This was originally reported as bug #463548 for the stable > series, and I have created a test for it with BMP in the > development series. (Please note that if the cache bug is > fixed, the test I wrote will still fail due to another bug > reported under the same bug number - it will just fail > differently until the other bug is also fixed.) > I suspect that some other reported bugs (like #472072) > are because of this bug. > > Problem is that after a successful call to the bean > instance create method, a context is added to the > cache. But afterwards, the postCreate method is called, > and if this method somehow fails (ie. throws a > CreateException), the bean instance is not removed from > the cache again. > See BMPPersistenceManager for an example - same problem > with CMP. > > I would like to fix this, but unfortunately I am not > very familiar with the cache, and an educated guess > after a few hours of cache code reading _could_ be > wrong. > > Maybe, if someone with more knowledge of the cache > can tell me what needs to be done in case of an > exception thrown from a postCreate method, I could > fix this, and backport the fix to the stable series. > > > Best Regards, > > Ole Husgaard. > > _______________________________________________ > Jboss-development mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-development > _______________________________________________ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
