如何在Weblogic persistence.xml上配置DataSources

时间:2017-10-09 13:57:57

标签: java oracle weblogic persistence

我有一个persistence.xml - >

<?xml version="1.0" encoding="UTF-8"?>
<persistence version="1.0"
    xmlns="http://java.sun.com/xml/ns/persistence">

    <persistence-unit name="PU" transaction-type="JTA">
        <provider>org.hibernate.jpa.HibernatePersistenceProvider</provider>
        <jta-data-source>java:/XADS</jta-data-source>

        <properties>
            <property name="hibernate.show_sql" value="false" />
            <property name="hibernate.dialect" value="org.hibernate.dialect.MySQLDialect" />
        </properties>

    </persistence-unit>

</persistence>

我必须在Weblogic

Error org.hibernate.HibernateException: The chosen transaction strategy requires access to the JTA TransactionManager

Warning Errors were encountered while performing this operation.

DataSource在Weblogic - &gt;

中定义
XADS    Generic java:/XADS  AdminServer

我没有weblogic.xml或configDataSource.xml。我该怎么办?

0 个答案:

没有答案