[jbosstools-issues] [JBoss JIRA] Resolved: (JBIDE-6955) Erroroneous error about CDI observer method on session bean

Alexey Kazakov (JIRA) jira-events at lists.jboss.org
Wed Sep 1 14:25:11 EDT 2010


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

Alexey Kazakov resolved JBIDE-6955.
-----------------------------------

    Resolution: Done


> Erroroneous error about CDI observer method on session bean
> -----------------------------------------------------------
>
>                 Key: JBIDE-6955
>                 URL: https://jira.jboss.org/browse/JBIDE-6955
>             Project: Tools (JBoss Tools)
>          Issue Type: Bug
>          Components: cdi (jsr-299)
>    Affects Versions: 3.2.0.M1
>            Reporter: Pete Muir
>            Assignee: Alexey Kazakov
>             Fix For: 3.2.0.Beta
>
>
> Given this bean
> @Singleton
> public class CodeFragmentLogger
> {
>    private final List<CodeFragment> log;
>    public CodeFragmentLogger()
>    {
>       this.log = new ArrayList<CodeFragment>();
>    }
>    @Lock(LockType.WRITE)
>    public void addEntry(@Observes CodeFragment codeFragment)
>    {
>       this.log.add(codeFragment);
>    }
> }
> JBoss Tools adds an error, saying "Non-static method of a session bean class has a parameter annotated @Observes, and the method is not a business method of the EJB"
> For a start, I think this should say "Non-static method <method name> of session bean <bean class>..."
> Also, of course, this error is erroneous, the method *is* a business method of the EJB.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the jbosstools-issues mailing list