使用Quartz和JBoss 5.0.1时的EJB注入问题

使用Quartz和JBoss 5.0.1时的EJB注入问题,ejb,quartz-scheduler,Ejb,Quartz Scheduler,我需要配置一个在启动JBoss 5.0.1服务器时执行的进程。我有下一节课: @MessageDriven(activationConfig = { @ActivationConfigProperty(propertyName="cronTrigger", propertyValue="0 0/1 * * * ?") }) @ResourceAdapter("quartz-ra.rar") public class SincronizadorProcesosEnEspera implements

我需要配置一个在启动JBoss 5.0.1服务器时执行的进程。我有下一节课:

@MessageDriven(activationConfig =
{
@ActivationConfigProperty(propertyName="cronTrigger", propertyValue="0 0/1 * * * ?")
})
@ResourceAdapter("quartz-ra.rar")
public class SincronizadorProcesosEnEspera implements Job
{
// @EJB(mappedName=Constants.EJB_MAPPED_FACADE_ADMINISTRADOR_LOCAL) <----------I try with this other way, and nothing
private IAdministradorFacade administradorFacade;

public void execute(JobExecutionContext arg0) throws JobExecutionException
{
// administradorFacade = (IAdministradorFacade) JNDIResources.getAdministradorFacade(); <-------------------I try with this other way, and nothing
// administradorFacade =(IAdministradorFacade) BeanContextUtil.getBean("administradorFacade"); <------------------I try with this other way, and nothing
administradorFacade.sincronizarProcesos();<--------- When pass for this point throw a error
}
}
---请帮帮我,我只需要用Quartz执行一个进程,但EJB不能被注入,EJB在spring中声明如下:

<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:jee="http://www.springframework.org/schema/jee"
xmlns:util="http://www.springframework.org/schema/util"
xsi:schemaLocation="
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd
http://www.springframework.org/schema/jee http://www.springframework.org/schema/jee/spring-jee-3.0.xsd
http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-3.0.xsd">

<jee:local-slsb id="administradorFacade"
jndi-name="ModeloAdministradorEAR/AdministradorFacade/local"
business-interface="com.integra.ppo.modelo.administrador.facade.IAdministradorFacadeLocal"
cache-home="true" lookup-home-on-startup="true" resource-ref="true" />
</beans>

谢谢

请查看此链接:如果它对您有用的话。
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:jee="http://www.springframework.org/schema/jee"
xmlns:util="http://www.springframework.org/schema/util"
xsi:schemaLocation="
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd
http://www.springframework.org/schema/jee http://www.springframework.org/schema/jee/spring-jee-3.0.xsd
http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-3.0.xsd">

<jee:local-slsb id="administradorFacade"
jndi-name="ModeloAdministradorEAR/AdministradorFacade/local"
business-interface="com.integra.ppo.modelo.administrador.facade.IAdministradorFacadeLocal"
cache-home="true" lookup-home-on-startup="true" resource-ref="true" />
</beans>