Details
-
Wish
-
Status: Closed
-
Major
-
Resolution: Fixed
-
0.6
-
None
-
None
Description
The usage of package private methods for CDI beans leads to the situation that proxies for this bean must be definied in the same classloader that loads the bean class.
In certain environments (where lifetime of classloaders defining CDI beans >> lifecycle of the CDI context) causes really bad memory leaks (a longer discussion of the general problem can be found here: https://issues.apache.org/jira/browse/OWB-931). Mitigation is only possible if the proper classloader is chosen - but this breaks if there are package-private methods to be proxied.
Therefor I would suggest to completely refrain from defining package private methods.
So far I have only found
org.apache.deltaspike.jsf.impl.injection.AbstractBeanStorage.add()
to be such a method.