Details
-
Bug
-
Status: Closed
-
Critical
-
Resolution: Fixed
-
1.2.0
-
None
Description
We currently need to pass the CreationalContext to our whole Interceptor and Decorator chain as we atm lazily create them. Sadly a few CDI SPI methods are not designed to allow passing the CreationalContext, e.g. InjectionTarget#postConstruct() and InjectionTarget#preDestroy();
We might think about switching to EAGERly creating all Interceptors instead.
As alternative we could think about storing the CreationalContext in a WeakHashMap in our wrapped CustomContextImpl if the handled context is NormalScoped.
Plus for intercepted non-NormalScoped beans we need to always create a subclass and store the CreationalContext therein.
Please add more ideas and feedback!