[cdi-dev] [JBoss JIRA] (CDI-292) Drop ProcessModule.getAnnotatedTypes()

Jozef Hartinger (JIRA) jira-events at lists.jboss.org
Thu Nov 8 06:41:18 EST 2012

Jozef Hartinger created CDI-292:

             Summary: Drop ProcessModule.getAnnotatedTypes()
                 Key: CDI-292
                 URL: https://issues.jboss.org/browse/CDI-292
             Project: CDI Specification Issues
          Issue Type: Feature Request
          Components: Portable Extensions
    Affects Versions: 1.1.PFD
            Reporter: Jozef Hartinger
            Assignee: Pete Muir
             Fix For: 1.1 (Proposed)

With @WithAnnotations in place it is now possible for extensions to indicate with fine granularity which container lifecycle events it is interested in and thus not to harm performance that much if the CDI implementation is efficient. 

Therefore, I don't like the ProcessModule.getAnnotatedTypes() method because:

1.) There is no granularity. If extensions start to use it inefficiently it will always harm performance heavily.
2.) I am not convinced this method is needed. It was not present in CDI 1.0. The only benefit of the method is that it allows for an extension to get an idea where a given AnnotatedType is comming from. There are other more efficient ways of exposing the same information. If we really need to do this we should probably introduce an abstraction over a bean archive (e.g. a Module object) and add a getModule() method to ProcessAnnotatedType.

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