-
Bug
-
Resolution: Done
-
Major
-
9.0.0.CR2, 10.0.0.Alpha1
-
None
This is addition to WFLY-4569.
One more case was discovered when bean is leaked from the pool after an exception is thrown in certain methods:
- If any exception is thrown during call to instance.activate() (which includes calls to ejbActivate and ejbLoad), then cache implementations (both optimistic and pessimistic) never notifies pool that instance should be discarded.
In addition, a little correction should be made for handling exceptions thrown from ejbCreate (handling was introduced as part of WFLY-4569) – such instances should not be released to the pool, but discarded with pool notification in order to comply with EJB specification.