TX その5 デフォルトで使われるTransactionManager実装クラス

"java:/TransactionManager"のJNDI名でbindしたのはTransactionManagerServiceクラス(MBean).クラスコメントにご丁寧に説明書きが.

This is a JMX service which manages the TransactionManager.
The service creates it and binds a Reference to it into JNDI.

createServiceメソッドを見る.

XidFactoryMBean xidFactoryObj = (XidFactoryMBean) getServer().getAttribute(xidFactory, "Instance");
TransactionImpl.xidFactory = xidFactoryObj;
TransactionImpl.txManagerService = this;

// Get a reference to the TxManager singleton.
tm = TxManager.getInstance();

この間のXidFactoryもここで突っ込まれているね,そういえば.全てはこのMBeanから始まっているということなのかな.そんなわけで,デフォルトのTransactionManager実装クラスは"org.jboss.tm.TxManager"に確定.
TxManagerのクラスコメントにもこのように書いてある.

Our TransactionManager implementation.

あとはCMTが"java:/TransactionManager"をlookupして使っているということが証明できれば,CMT/BMTといったレイヤーの話を切り捨ててTransactionManager以下のレイヤーのみで話を進められる.