MuleSoft and SQL Server DB connection failure -
i hope can me, it's been 2 days mulesoft(ms) guru side , cannot figure issue out. put, cannot connect sql server database. using generic_database_connectory
following information:
- url:
jdbc:jtds:sqlserver://ba-crmdb01.ove.local:60520;instance=crm;user=rcapilli...
- driver class name:
com.microsoft.sqlserver.jdbc.sqlserverdriver
it's sqljdbc4.jar
file, latest. "test connection" works fine. no issues there. when run app, error (below)
anyone been able sql server db connection work???
error 2015-04-09 14:05:31,106 [pool-17-thread-1] org.mule.exception.defaultsystemexceptionstrategy: caught exception in exception strategy: null java.lang.nullpointerexception at org.mule.module.db.internal.domain.connection.defaultdbconnection.isclosed(defaultdbconnection.java:100) ~[mule-module-db-3.6.1.jar:3.6.1] at org.mule.module.db.internal.domain.connection.transactionaldbconnectionfactory.releaseconnection(transactionaldbconnectionfactory.java:136) ~[mule-module-db-3.6.1.jar:3.6.1] at org.mule.module.db.internal.processor.abstractdbmessageprocessor.process(abstractdbmessageprocessor.java:99) ~[mule-module-db-3.6.1.jar:3.6.1] at org.mule.transport.polling.messageprocessorpollingmessagereceiver$1.process(messageprocessorpollingmessagereceiver.java:164) ~[mule-core-3.6.1.jar:3.6.1] at org.mule.transport.polling.messageprocessorpollingmessagereceiver$1.process(messageprocessorpollingmessagereceiver.java:148) ~[mule-core-3.6.1.jar:3.6.1] at org.mule.execution.executecallbackinterceptor.execute(executecallbackinterceptor.java:16) ~[mule-core-3.6.1.jar:3.6.1] at org.mule.execution.handleexceptioninterceptor.execute(handleexceptioninterceptor.java:30) ~[mule-core-3.6.1.jar:3.6.1] at org.mule.execution.handleexceptioninterceptor.execute(handleexceptioninterceptor.java:14) ~[mule-core-3.6.1.jar:3.6.1] at org.mule.execution.beginandresolvetransactioninterceptor.execute(beginandresolvetransactioninterceptor.java:54) ~[mule-core-3.6.1.jar:3.6.1] at org.mule.execution.resolveprevioustransactioninterceptor.execute(resolveprevioustransactioninterceptor.java:44) ~[mule-core-3.6.1.jar:3.6.1] at org.mule.execution.suspendxatransactioninterceptor.execute(suspendxatransactioninterceptor.java:50) ~[mule-core-3.6.1.jar:3.6.1] at org.mule.execution.validatetransactionalstateinterceptor.execute(validatetransactionalstateinterceptor.java:40) ~[mule-core-3.6.1.jar:3.6.1] at org.mule.execution.isolatecurrenttransactioninterceptor.execute(isolatecurrenttransactioninterceptor.java:41) ~[mule-core-3.6.1.jar:3.6.1] at org.mule.execution.externaltransactioninterceptor.execute(externaltransactioninterceptor.java:48) ~[mule-core-3.6.1.jar:3.6.1] at org.mule.execution.rethrowexceptioninterceptor.execute(rethrowexceptioninterceptor.java:28) ~[mule-core-3.6.1.jar:3.6.1] at org.mule.execution.rethrowexceptioninterceptor.execute(rethrowexceptioninterceptor.java:13) ~[mule-core-3.6.1.jar:3.6.1] at org.mule.execution.transactionalerrorhandlingexecutiontemplate.execute(transactionalerrorhandlingexecutiontemplate.java:109) ~[mule-core-3.6.1.jar:3.6.1] at org.mule.execution.transactionalerrorhandlingexecutiontemplate.execute(transactionalerrorhandlingexecutiontemplate.java:30) ~[mule-core-3.6.1.jar:3.6.1] at org.mule.transport.polling.messageprocessorpollingmessagereceiver.pollwith(messageprocessorpollingmessagereceiver.java:147) ~[mule-core-3.6.1.jar:3.6.1] at org.mule.transport.polling.messageprocessorpollingmessagereceiver.poll(messageprocessorpollingmessagereceiver.java:138) ~[mule-core-3.6.1.jar:3.6.1] at org.mule.transport.abstractpollingmessagereceiver.performpoll(abstractpollingmessagereceiver.java:216) ~[mule-core-3.6.1.jar:3.6.1] at org.mule.transport.pollingreceiverworker.poll(pollingreceiverworker.java:80) ~[mule-core-3.6.1.jar:3.6.1] at org.mule.transport.pollingreceiverworker.run(pollingreceiverworker.java:49) ~[mule-core-3.6.1.jar:3.6.1] at java.util.concurrent.executors$runnableadapter.call(executors.java:471) ~[?:1.7.0_75] at java.util.concurrent.futuretask.runandreset(futuretask.java:304) ~[?:1.7.0_75] at java.util.concurrent.scheduledthreadpoolexecutor$scheduledfuturetask.access$301(scheduledthreadpoolexecutor.java:178) ~[?:1.7.0_75] at java.util.concurrent.scheduledthreadpoolexecutor$scheduledfuturetask.run(scheduledthreadpoolexecutor.java:293) ~[?:1.7.0_75] at java.util.concurrent.threadpoolexecutor.runworker(threadpoolexecutor.java:1145) [?:1.7.0_75] at java.util.concurrent.threadpoolexecutor$worker.run(threadpoolexecutor.java:615) [?:1.7.0_75] at java.lang.thread.run(thread.java:745) [?:1.7.0_75]
this how used configure , works me.. can try example :-
<db:generic-config name="generic_database_configuration" url="jdbc:sqlserver://anirban-pc\\sqlexpress:1433;databasename=mydbname;user=sa;password=mypassword" driverclassname="com.microsoft.sqlserver.jdbc.sqlserverdriver" doc:name="generic database configuration" />
and in mule flow :-
<db:select config-ref="generic_database_configuration" doc:name="database"> <db:parameterized-query><![cdata[select * table1]]></db:parameterized-query> </db:select>