[jboss-jira] [JBoss JIRA] Updated: (EJBTHREE-1701) getTimerService() can no longer be called in @Service start()

Matt C (JIRA) jira-events at lists.jboss.org
Tue Jan 27 06:01:54 EST 2009


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

Matt C updated EJBTHREE-1701:
-----------------------------

    Environment: 5.0.0.GA
    Description: 
Calling getTimerService() is no longer allowed from the lifecycle methods of @Service.
Exception java.lang.IllegalStateException: getTimerService() not allowed during injection (EJB3 4.5.2).
This occurs in the start() method of a @Service bean. The effect is to disallow setup of application-wide timers.

This action is erroneously disallowed based on Table 2 in the EJB3 specification, section 4.5.2 (IMHO).

Service lifecycle methods are not dependency injection methods, furthermore @Service beans are outside of the EJB3 specification.
Lifecycle methods of a service should probably be considered business methods, not DI in the context of Table 2. They are in the @Management business interface.

There is no workaround yet for this backwards incompatible change which breaks apps that set up application-wide timers from Services when they are migrated to 5.0.0.GA. This used to work in 4.2.x.

  was:
Calling getTimerService() is no longer allowed from the lifecycle methods of @Service.
Exception java.lang.IllegalStateException: getTimerService() not allowed during injection (EJB3 4.5.2).
This occurs in the start() method of a @Service bean. The effect is to disallow setup of application-wide timers.

This action is erroneously disallowed based on Table 2 in the EJB3 specification, section 4.5.2 (IMHO).

Service lifecycle methods are not dependency injection methods, furthermore @Service beans are outside of the EJB3 specification.
Lifecycle methods of a service should probably be considered business methods, not DI in the context of Table 2. They are in the @Management business interface.

There is no workaround yet for this backwards incompatible change which breaks apps that set up application-wide timers from Services.



> getTimerService() can no longer be called in @Service start()
> -------------------------------------------------------------
>
>                 Key: EJBTHREE-1701
>                 URL: https://jira.jboss.org/jira/browse/EJBTHREE-1701
>             Project: EJB 3.0
>          Issue Type: Bug
>          Components: core
>    Affects Versions: trunk
>         Environment: 5.0.0.GA
>            Reporter: Matt C
>
> Calling getTimerService() is no longer allowed from the lifecycle methods of @Service.
> Exception java.lang.IllegalStateException: getTimerService() not allowed during injection (EJB3 4.5.2).
> This occurs in the start() method of a @Service bean. The effect is to disallow setup of application-wide timers.
> This action is erroneously disallowed based on Table 2 in the EJB3 specification, section 4.5.2 (IMHO).
> Service lifecycle methods are not dependency injection methods, furthermore @Service beans are outside of the EJB3 specification.
> Lifecycle methods of a service should probably be considered business methods, not DI in the context of Table 2. They are in the @Management business interface.
> There is no workaround yet for this backwards incompatible change which breaks apps that set up application-wide timers from Services when they are migrated to 5.0.0.GA. This used to work in 4.2.x.

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

        



More information about the jboss-jira mailing list