基本上在JBOSS上跑一些框架都会有问题,主要是因为JBOSS使用VFS加载文件,麻烦
比如CAS
CAS的web.xml中
<context-param>
<param-name>log4jConfigLocation</param-name>
[color=red]<param-value>classpath:log4j.xml</param-value>[/color]
<param-value>/WEB-INF/classes/log4j.xml</param-value>
</context-param>
还有
[color=red]java.lang.RuntimeException: Specification violation [EJB3 JPA 6.2.1.2] - You have not defined a non-jta-data-source for a RESOURCE_LOCAL enabled persistence context named: CasPersistence[/color]
删除WEB-INF/classes/MET-INF/persistence.xml
或者
<persistence-unit name="CasPersistence" transaction-type="RESOURCE_LOCAL">
<non-jta-data-source/>
</persistence-unit>
比如CAS
CAS的web.xml中
<context-param>
<param-name>log4jConfigLocation</param-name>
[color=red]<param-value>classpath:log4j.xml</param-value>[/color]
<param-value>/WEB-INF/classes/log4j.xml</param-value>
</context-param>
还有
[color=red]java.lang.RuntimeException: Specification violation [EJB3 JPA 6.2.1.2] - You have not defined a non-jta-data-source for a RESOURCE_LOCAL enabled persistence context named: CasPersistence[/color]
删除WEB-INF/classes/MET-INF/persistence.xml
或者
<persistence-unit name="CasPersistence" transaction-type="RESOURCE_LOCAL">
<non-jta-data-source/>
</persistence-unit>