apache ignite 1.6.0 xa resource enlist in existing jta transaction

半世苍凉 提交于 2020-01-17 00:40:10

问题


 Ignite ignite = Ignition.start();

How to make this ignite instance fall into existing jta transaction..
Tried..


 TransactionConfiguration transactionConfiguration = new TransactionConfiguration();
  Factory factory = FactoryBuilder.factoryOf(userTransactionManager);
       transactionConfiguration.setTxManagerFactory(factory);
       transactionConfiguration.setUseJtaSynchronization(true);

How to corellate these TransactionConfiguration with the instance of ignite..!! Any help..! Referred .. http://apacheignite.gridgain.org/docs/transactions#integration-with-jta ....


回答1:


TransactionConfiguration is the part of IgniteConfiguration, so you can provide it during start:

IgniteConfiguration cfg = new IgniteConfiguration();
cfg.setTransactionConfiguration(transactionConfiguration);
Ignite ignite = Ignition.start(cfg);


来源:https://stackoverflow.com/questions/38126971/apache-ignite-1-6-0-xa-resource-enlist-in-existing-jta-transaction

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!