Atomikos Forum |
|
I am trying to setup the mbean for managing atomikos transactions via JMX.
configrations used. @Configuration public class JmxConfig { @Bean public JmxTransactionService jmxTransactionService() { JmxTransactionService jmxTransactionService = new JmxTransactionService(); return jmxTransactionService; } @Bean public MBeanServer mbeanServer() { MBeanServerFactoryBean mBeanServerFactoryBean = new MBeanServerFactoryBean(); mBeanServerFactoryBean.afterPropertiesSet(); return mBeanServerFactoryBean.getObject(); } @Bean public MBeanExporter mbeanExporter() { MBeanExporter mbeanExporter = new MBeanExporter(); mbeanExporter.setServer(mbeanServer()); Map<String, Object> beans = new HashMap<>(); beans.put("atomikos:name=tx-service", jmxTransactionService()); mbeanExporter.setBeans(beans); return mbeanExporter; } } Appreciate any help . |