When you have no way to create a
XAConnectionFactory in a javabean way, you can specify the
className argument of
PoolingConnectionFactory to be bitronix.tm.resource.jms.JndiXAConnectionFactory. This class is an implementation of
XAConnectionFactory that will wrap another implementation fetched from JNDI.
It is often required to use credentials to be able to connect to a JNDI repository. The bitronix.tm.resource.jms.JndiXAConnectionFactory class fully supports this via its
securityCredentials properties as illustrated bellow: