本人配置了如下,是spring+struts+jotm的配置,但是不起作用,配置文件信息如下
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN" "http://www.springframework.org/dtd/spring-beans.dtd"><beans>
    <bean id="jotm" class="org.springframework.transaction.jta.JotmFactoryBean"/>
    <!--  数据源 -->
    
    <bean id="dataSourceOracle" class="org.enhydra.jdbc.standard.StandardXADataSource" >
<property name="transactionManager" ref="jotm"/>
<property name="driverName">
<value>oracle.jdbc.driver.OracleDriver</value>
</property>
<property name="url">
<value>jdbc:oracle:thin:@172.16.19.58:1521:gis</value>
</property>
<property name="user">
<value>mis_kkx</value>
</property>
<property name="password">
<value>mis_kkx</value>
</property>
</bean>
    
    
<bean id="dataSourceSqlServer" class="org.enhydra.jdbc.standard.StandardXADataSource" >
<property name="transactionManager" ref="jotm"/>
<property name="driverName">
<value>com.microsoft.jdbc.sqlserver.SQLServerDriver</value>
</property>
<property name="url">
<value>jdbc:microsoft:sqlserver://127.0.0.1:1433;databasename=KKX_DATA</value>
</property>
<property name="user">
<value>sa</value>
</property>
<property name="password">
<value>123456</value>
</property>
</bean>
<!-- session工厂-->
<bean id="sessionFactoryOracle"
class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">
<property name="dataSource" ref="dataSourceOracle"/>
<property name="hibernateProperties">
<props>
<prop key="hibernate.dialect">
org.hibernate.dialect.SQLServerDialect
</prop>
</props>
</property>
<property name="mappingResources">
<list>
   </list>
</property>
<property name="jtaTransactionManager" ref="jotm" />   
</bean>

<bean id="sessionFactorySqlServer"
class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">
<property name="dataSource" ref="dataSourceSqlServer"/>
<property name="hibernateProperties">
<props>
<prop key="hibernate.dialect">
org.hibernate.dialect.SQLServerDialect
</prop>
</props>
</property>
<property name="mappingResources">
<list>
   </list>
</property>
<property name="jtaTransactionManager" ref="jotm" />   
</bean>

<!--定义事务-->
<bean id="transactionManager" class="org.springframework.transaction.jta.JtaTransactionManager">
    <property name="userTransaction"><ref local="jotm"/></property>
    </bean>

<!--dao配置-->

    <bean id="baseDao" class="cn.holleygrid.mis.dao.hibernate.BaseHibernateDao">
<property name="sessionFactory">
<ref local="sessionFactoryOracle" />
</property>
</bean>

<bean id="baseDaoSql" class="cn.holleygrid.mis.dao.hibernate.BaseHibernateDao">
<property name="sessionFactory">
<ref local="sessionFactorySqlServer" />
</property>
</bean><bean id="baseDAOProxy"
class="org.springframework.transaction.interceptor.TransactionProxyFactoryBean">
<property name="transactionManager">
<ref bean="transactionManager" />
</property>
<property name="target">
<ref local="baseDao" />
</property>
<property name="transactionAttributes">
<props>
<prop key="save*">PROPAGATION_REQUIRED</prop>
<prop key="execute">PROPAGATION_REQUIRED</prop>
<prop key="delete*">PROPAGATION_REQUIRED</prop>
<prop key="executeQuery">PROPAGATION_REQUIRED,readOnly</prop>
</props>
</property>
</bean>

<bean id="baseDAOProxySql"
class="org.springframework.transaction.interceptor.TransactionProxyFactoryBean">
<property name="transactionManager">
<ref bean="transactionManager" />
</property>
<property name="target">
<ref local="baseDaoSql" />
</property>
<property name="transactionAttributes">
<props>
<prop key="save*">PROPAGATION_REQUIRED</prop>
<prop key="execute">PROPAGATION_REQUIRED</prop>
<prop key="delete*">PROPAGATION_REQUIRED</prop>
<prop key="executeQuery">PROPAGATION_REQUIRED,readOnly</prop>
</props>
</property>
</bean>


<!-- Begin Common -->
    <bean name="/Logon" class="cn.holleygrid.mis.action.LogonAction" singleton="false">
      <property name="baseDao">
          <ref bean="baseDAOProxy" />
      </property>
    </bean>   
    </beans>