由于SQLException,无法连接到数据源

use*_*266 5 jboss atg

ATG 10.2JBOSS上运行Motorprise应用程序并使用MySQLServer时遇到一些问题.

Unable to connect to data source because of SQLException: Could not enlist in transaction on entering meta-aware object!;
CONTAINER:atg.repository.RepositoryException; SOURCE:org.jboss.util.NestedSQLException:     Could not enlist in transaction on entering meta-aware object!; - nested throwable: (javax.transaction.SystemException: java.lang.Throwable: Unabled to enlist resource, see the previous warnings. tx=TransactionImple < ac, BasicAction: a618a4b:d503:525e
689c:1db status: ActionStatus.ABORT_ONLY >); - nested throwable: (org.jboss.resource.JBossResourceException: Could not enlist in transaction on entering meta-aware object!; - nested throwable: (javax.transaction.SystemException: java.lang.Throwable: Unabled to enlist resource, see the previous warnings. tx=TransactionImple < ac, BasicActi
on: a618a4b:d503:525e689c:1db status: ActionStatus.ABORT_ONLY >))
    at atg.adapter.gsa.GSAItemDescriptor.executeQuery(GSAItemDescriptor.java:8347)
Run Code Online (Sandbox Code Playgroud)

rad*_*mpe 5

JBoss默认假定XA驱动程序,并且不支持在同一事务中调用多个非XA资源.要在JBoss中启用多个非XA资源,请将属性com.arjuna.ats.jta.allowMultipleLastResources添加到标记jbossjta-properties.xml下的文件中<property depends="arjuna" name="jta">:

<property depends="arjuna" name="jta">
  <property name="com.arjuna.ats.jta.allowMultipleLastResources" value="true"/>
Run Code Online (Sandbox Code Playgroud)

您可能仍会在日志文件中看到警告,但ATG应用程序将正常运行.要禁止显示这些警告,请将以下内容添加到jboss-log4j.xml文件中:

<category name="com.arjuna.atg.jta.logging">
  <priority value="ERROR"/>
</category>
Run Code Online (Sandbox Code Playgroud)

这是ATG 9.3中的情况,我认为仍然适用.另一个快速参考原因在这里