Please note: You need the i-net OPTA v.2.05 fix or higher.
com.inet.tds.TdsDriver
in the file jboss.properties in the jdbc.drivers list. At has to looks like this:jdbc.drivers=org.hsql.jdbcDriver, org.enhydra.instantdb.jdbc.idbDriver,com.inet.tds.TdsDriver
<MLET CODE="org.jboss.jdbc.XADataSourceLoader" ARCHIVE="jboss.jar,Opta.jar" CODEBASE="../../lib/ext/"> <ARG TYPE="java.lang.String" VALUE="{MyConnectionPool}"> <ARG TYPE="java.lang.String" VALUE="com.inet.tds.DTCDataSource"> </MLET>
*** If you can't install the Resource Manager Proxy in the SQL Server then you can use com.inet.tds.XDataSource instead of com.inet.tds.DTCDataSource.
<mbean name="DefaultDomain:service=XADataSource,name={MyConnectionPool}"> <attribute name="Properties">serverName={YourHost}; database={YourDatabase}</attribute> <attribute name="GCMinIdleTime">1200000</attribute> <attribute name="JDBCUser">{sa}</attribute> <attribute name="MaxSize">10</attribute> <attribute name="Password">{}</attribute> <attribute name="GCEnabled">false</attribute> <attribute name="InvalidateOnError">false</attribute> <attribute name="TimestampUsed">false</attribute> <attribute name="Blocking">true</attribute> <attribute name="GCInterval">120000</attribute> <attribute name="IdleTimeout">1800000</attribute> <attribute name="IdleTimeoutEnabled">false</attribute> <attribute name="LoggingEnabled">false</attribute> <attribute name="MaxIdleTimeoutPercent">1.0</attribute> <attribute name="MinSize">0</attribute> </mbean>
java.lang.NullPointerException at org.jboss.logging.Log.log(Log.java:95) at org.jboss.logging.Log.log(Log.java:100) at org.jboss.util.ServiceMBeanSupport.init(ServiceMBeanSupport.java:62) at org.jboss.util.ServiceMBeanSupport.preRegister(ServiceMBeanSupport.java:161) at com.sun.management.jmx.MBeanServerImpl.preRegisterInvoker(MBeanServerImpl.java:2245) at com.sun.management.jmx.MBeanServerImpl.createMBean(MBeanServerImpl.java:765) at javax.management.loading.MLet.getMBeansFromURL(MLet.java:540) at javax.management.loading.MLet.getMBeansFromURL(MLet.java:369) at org.jboss.Main.<init>(Main.java:119) at org.jboss.Main$1.run(Main.java:87) at java.security.AccessController.doPrivileged(Native Method) at org.jboss.Main.main(Main.java:83)
Cause: You have to add the MLET tag to the top of the file and not at the end of the file.
[MyConnectionPool] com.inet.tds.SQLException: java.net.UnknownHostException: YourHost,database=YourDatabase [MyConnectionPool] java.net.UnknownHostException: YourHost,database=YourDatabase [MyConnectionPool] at java.net.InetAddress.getAllByName0(Unknown Source) [MyConnectionPool] at java.net.InetAddress.getAllByName0(Unknown Source) [MyConnectionPool] at java.net.InetAddress.getByName(Unknown Source) [MyConnectionPool] at java.net.Socket.<init>(Unknown Source) [MyConnectionPool] at com.inet.tds.TdsDriver.a(Unknown Source) [MyConnectionPool] at com.inet.tds.TdsDriver.connect(Unknown Source) [MyConnectionPool] at com.inet.tds.TdsDataSource.getConnection(Unknown Source) [MyConnectionPool] at com.inet.tds.DTCDataSource.getXAConnection(Unknown Source) [MyConnectionPool] at org.jboss.minerva.factories.XAConnectionFactory.createObject(XAConnectionFactory.java:232) [MyConnectionPool] at org.jboss.minerva.pools.ObjectPool.createNewObject(ObjectPool.java:801) [MyConnectionPool] at org.jboss.minerva.pools.ObjectPool.getObject(ObjectPool.java:549) [MyConnectionPool] at org.jboss.minerva.datasource.XAPoolDataSource.getConnection(XAPoolDataSource.java:169) [MyConnectionPool] at org.jboss.jdbc.XADataSourceLoader.initializePool(XADataSourceLoader.java:288) [MyConnectionPool] at org.jboss.jdbc.XADataSourceLoader.startService(XADataSourceLoader.java:252) [MyConnectionPool] at org.jboss.util.ServiceMBeanSupport.start(ServiceMBeanSupport.java:92) [MyConnectionPool] at java.lang.reflect.Method.invoke(Native Method) [MyConnectionPool] at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1628) [MyConnectionPool] at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523) [MyConnectionPool] at org.jboss.dependencies.DependencyManager.startMBean(DependencyManager.java:284) [MyConnectionPool] at org.jboss.dependencies.DependencyManager.loadService(DependencyManager.java:261) [MyConnectionPool] at org.jboss.dependencies.DependencyManager.processService(DependencyManager.java:243) [MyConnectionPool] at org.jboss.dependencies.DependencyManager.processService(DependencyManager.java:238) [MyConnectionPool] at org.jboss.dependencies.DependencyManager.startMBeans(DependencyManager.java:117) [MyConnectionPool] at org.jboss.Main.<init>(Main.java:162) [MyConnectionPool] at org.jboss.Main$1.run(Main.java:87) [MyConnectionPool] at java.security.AccessController.doPrivileged(Native Method) [MyConnectionPool] at org.jboss.Main.main(Main.java:83)
Cause: The properties need to be separated by semicolon and not by comma.
[MyConnectionPool] Initializing [MyConnectionPool] Initialized [Default] javax.management.RuntimeMBeanException: RuntimeException thrown in the MBean's setter [Default] at com.sun.management.jmx.MBeanServerImpl.setAttribute(MBeanServerImpl.java:1417) [Default] at com.sun.management.jmx.MBeanServerImpl.setAttribute(MBeanServerImpl.java:1331) [Default] at org.jboss.configuration.ConfigurationService.load(ConfigurationService.java:139) [Default] at java.lang.reflect.Method.invoke(Native Method) [Default] at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1628) [Default] at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523) [Default] at org.jboss.Main.<init>(Main.java:143) [Default] at org.jboss.Main$1.run(Main.java:87) [Default] at java.security.AccessController.doPrivileged(Native Method) [Default] at org.jboss.Main.main(Main.java:83) **Cause:** - Maybe you use an older version of i-net OPTA. You need release 2.05 fix or higher. - You have set a value for the URL. i-net OPTA's XADataSource does not need and does not support a URL. ---- <code java> [MyConnectionPool] There seems to be a problem with the JDBC URL: java.lang.NoSuchMethodException
Cause: This is only a warning because there is no method getURL() in the datasource. i-net OPTA's XADataSource does not need and does not support a URL.