[cdi-dev] [JBoss JIRA] (CDI-346) Unclear relation between bean discovery and @WithAnnotations

Jozef Hartinger (JIRA) jira-events at lists.jboss.org
Sun Mar 10 05:23:41 EDT 2013


    [ https://issues.jboss.org/browse/CDI-346?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12760023#comment-12760023 ] 

Jozef Hartinger commented on CDI-346:
-------------------------------------

How does an extension distinguish a PAT fired for this additional type (only recognized as a result of @WithAnnotations - no resulting in a bean definition) from a PAT fired for a discovered type?
                
> Unclear relation between bean discovery and @WithAnnotations
> ------------------------------------------------------------
>
>                 Key: CDI-346
>                 URL: https://issues.jboss.org/browse/CDI-346
>             Project: CDI Specification Issues
>          Issue Type: Bug
>    Affects Versions: 1.1.PFD
>            Reporter: Jozef Hartinger
>            Assignee: Pete Muir
>             Fix For: 1.1.FD
>
>
> {quote}
> First the container must discover types. The container discovers:
> • each Java class, interface or enum deployed in an explicit bean archive, and
> • each Java class interface, or enum with a bean defining annotation in an implicit bean archive.
> • each session bean
> that is not excluded from discovery.
> Then, container must create an AnnotatedType representing the type and fire an event of type ProcessAnnotatedType,
> as defined in Section 11.5.6, for:
> • every type discovered
> • each Java class, interface or enum that must be delivered to a ProcessAnnotatedType observer, where the event parameter
> is annotated with @WithAnnotations.
> {quote}
> Having a class
> a) in an implicit bean archive
> b) outside of bean archive
> that does not define a bean defining annotation and the class must be delivered to a @WithAnnotation PAT observer method.
> Should this class result in a bean definition (assuming it fulfils bean requirements)?
> Would not it be easier to add the category of classes that must be delivered to @WithAnnotations PAT observer to the implicit bean archive definition?

--
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