JBoss Community

how to deploy a service pojo depending on ejb timer

reply from Maria Luisa Della Vedova in EJB 3.0 - View the full discussion

on line 39 there is a call to the ejb method for the creation of the timer (ctx.getTimerService().createTimer)

 

with the lookup of the EJB the same code give me no problem.

 

@Service

@Local(MyInterfaceService.class)

@Depends("jboss.j2ee:ear=earname.ear,jar=jarname.jar,name=TheTimerBean,service=EB3")

public class MyService implements MyInterfaceService {

@EJB

private ITimer myEJBTimer;

 

@Override

public void create() throws Exception {

line 39           myEJBTimer.attiva();

      }

 

}

 

thanks

Reply to this message by going to Community

Start a new discussion in EJB 3.0 at Community