[weld-issues] [JBoss JIRA] Commented: (WELD-469) Exception in normal mode for incompletly annotated custom scopes.

Pete Muir (JIRA) jira-events at lists.jboss.org
Tue Nov 30 16:49:04 EST 2010


    [ https://jira.jboss.org/browse/WELD-469?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12566343#comment-12566343 ] 

Pete Muir commented on WELD-469:
--------------------------------

Wolfgang, finally read your comment, sorry, this was low priority for us.

Agreed that current behaviour is not optimal, we should either error or just warn about the lack of spec compliance and use the annotation. However your (3) is far too broad. A definition error is carefully defined in the spec as "Definition errors—occur when a single bean definition violates the rules of this specification". Clearly a poorly defined qualifier is not a "bean definition". So we do have some choice here. Having thought on this, I have decided to allow through these badly defined annotations, and log that they aren't portable.

Regarding (7), we do recommend you enable debug messages for Weld for development, we use INFO and above only for production level issues, and debug for anything you might want when debugging your app. This is in accordance with relatively recent logging guidelines from JBoss.



> Exception in normal mode for incompletly annotated custom scopes.
> -----------------------------------------------------------------
>
>                 Key: WELD-469
>                 URL: https://jira.jboss.org/browse/WELD-469
>             Project: Weld
>          Issue Type: Bug
>          Components: Bootstrap and Metamodel API, Scopes & Contexts
>    Affects Versions: 1.0.1.Final
>         Environment: n/a
>            Reporter: Wolfgang Frech
>            Priority: Minor
>             Fix For: 1.1.0.CR1
>
>
> If a custom scope is incomplete, say without the target annotation for field and type, but without method, Weld now
> - logs a warning
> - uses the context for that scope
> - marks the scope as invalid
> - returns only Java, not ClientProxy refs for Beans.
> According to the spec,the container must detect   the missing annotation.
> It should not complete the initialization.
> In addition to that behavior, it may treat it on a best-effort basis, but only in development mode.
> In normal mode, the container should throw an exception that cannot be missed.

-- 
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       



More information about the weld-issues mailing list