1
votes

I need to use Atomikos transaction Manager with Tomcat 8.0.36 to support JTA. Every documentation for Atomikos, recommend using com.atomikos.jdbc.AtomikosDataSourceBean as the type and com.atomikos.tomcat.EnhancedTomcatAtomikosBeanFactory as the object factory for the datasource resource (specified as resource in tomcat's context.xml)

However, if we use com.atomikos.jdbc.AtomikosDataSourceBean, Atomikos will use its own JDBC connection Pool instead of Tomcat's connection Pool.

Tomcat's connection pool provides more configurable settings than atomikos.

Is it possible to use Datasource resource, with type as javax.sql.XADatasource and factory as org.apace.tomcat.jdbc.pool.DatasourceFactory (which will use Tomcat's XA connection Pool) with Atomikos?

1

1 Answers

0
votes

I tried to use atomikos with tomcat JDBC pool i.e. I didn't use AtomikosDatasourceBean (which is the only recommended way in Atomikos documentation). So far I have tested this with 3-4 applications and it seems to work fine.

Atomikos documentation doesn't provide much detail about it, however, there is one sentence on its website which says that we can use other JDBC pool with tomcat.