[cdi-dev] [JBoss JIRA] (CDI-430) Revise the description of container lifecycle ordering during application initialization

Jozef Hartinger (JIRA) issues at jboss.org
Mon Apr 7 07:00:13 EDT 2014

     [ https://issues.jboss.org/browse/CDI-430?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jozef Hartinger reopened CDI-430:

Sorry for late review. There are several problems with the change:

1) Determining enabled alternatives, interceptors and decorators

12.4.3 has two bullets starting with:
"if the class is an enabled bean, interceptor or decorator, create ..."
and then the spec says:
"Then, the container determines which alternatives, interceptors and decorators are enabled ..."

The ordering here is clearly wrong (here since enabled beans, interceptors and decorators need to actually be determined for ProcessBean / ProcessBeanAttributes)

2) Strict ordering
The current ordering rules are way too strict. For example, the following ordering is required:

- create InjectionTarget, then
- fire ProcessInjectionTarget, and later
- create a Bean object

However, this cannot be implemented since an observer for ProcessInjectionTarget may call:
ProcessInjectionTarget.getInjectionTarget().getInjectionPoints().getBean() Since the Bean object has not been created yet the container cannot fulfil the contract. Same for ProcessInjectionPoint.

3) ProcessInjectionPoint should also be fired for InjectionPoints of producers/observers. The CDI 1.1 wording does not make that explicit. The current CDI-430 solution does not reflect this either within the new event ordering.

> Revise the description of container lifecycle ordering during application initialization
> ----------------------------------------------------------------------------------------
>                 Key: CDI-430
>                 URL: https://issues.jboss.org/browse/CDI-430
>             Project: CDI Specification Issues
>          Issue Type: Clarification
>    Affects Versions: 1.1.Final
>            Reporter: Martin Kouba
>            Assignee: Antoine Sabot-Durand
>              Labels: CDI_spec_chge, Ready_to_fix
>             Fix For: 1.2 Proposed
> E.g. it's not entirely clear when {{ProcessInjectionPoint}} if fired. Also it would be useful to mention {{ProcessBeanAttributes}} in bean discovery section.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

More information about the cdi-dev mailing list