在JBoss 6中部署Seam应用程序的问题

时间:2011-03-30 04:59:00

标签: deployment jboss seam web.xml jboss6.x

我正在尝试在JBoss 6上部署一个简单的“hello world”Seam应用程序,我在日志中遇到这些错误:

Deployment "jboss.ejb3:application=helloworld,component=TimerServiceDispatcher,module=jboss-seam,service=EjbEncFactory" is in error due to the following reason(s): Described
Deployment "org.jboss.ejb.bean.instantiator/helloworld/jboss-seam/TimerServiceDispatcher" is in error due to the following reason(s): ** NOT FOUND Depends on 'org.jboss.ejb.bean.instantiator/helloworld/jboss-seam/TimerServiceDispatcher' **
Deployment "jboss.naming:application=helloworld,component=TimerServiceDispatcher,module=jboss-seam" is in error due to the following reason(s): ** NOT FOUND Depends on 'jboss.naming:application=helloworld,component=TimerServiceDispatcher,module=jboss-seam' **
Deployment "org.jboss.ejb.bean.instantiator/helloworld/jboss-seam/EjbSynchronizations" is in error due to the following reason(s): ** NOT FOUND Depends on 'org.jboss.ejb.bean.instantiator/helloworld/jboss-seam/EjbSynchronizations' **
Deployment "jboss.ejb3:application=helloworld,component=EjbSynchronizations,module=jboss-seam,service=EjbEncFactory" is in error due to the following reason(s): Described
Deployment "jboss.naming:application=helloworld,component=EjbSynchronizations,module=jboss-seam" is in error due to the following reason(s): ** NOT FOUND Depends on 'jboss.naming:application=helloworld,component=EjbSynchronizations,module=jboss-seam' **

显然部署过程找不到TimerServiceDispatcherEjbSynchronizations,但我在web.xml注册了它们:

 <ejb-local-ref>
    <ejb-ref-name>helloworld/EjbSynchronizations/local</ejb-ref-name>
    <ejb-ref-type>Session</ejb-ref-type>
    <local>org.jboss.seam.transaction.LocalEjbSynchronizations</local>
    <ejb-link>EjbSynchronizations</ejb-link>
  </ejb-local-ref>

  <ejb-local-ref>
    <ejb-ref-name>helloworld/TimerServiceDispatcher/local</ejb-ref-name>
    <ejb-ref-type>Session</ejb-ref-type>
    <local>org.jboss.seam.async.LocalTimerServiceDispatcher</local>
    <ejb-link>TimerServiceDispatcher</ejb-link>
  </ejb-local-ref>

我做错了什么,或者我错过了什么?并注意到部署者正在寻找/helloworld/jboss-seam/TimerServiceDispatcher中的组件,而不是/helloworld/TimerServiceDispatcher中的组件(与EjbSynchronizations相同)

1 个答案:

答案 0 :(得分:0)

找到解决方案,这是包装的问题。 jboss-seam.jar库位于项目.ear文件中的lib目录中;这不再适用于JBoss 6,因为该文件现在必须位于.ear内的根级别。此外,必须相应调整jboss-seam.jar application.xml的位置。