Jboss, JDBC, and Cache failing on a null pointer in the driver

296 views
Skip to first unread message

Nicholas Ilacqua

unread,
Feb 11, 2016, 12:28:13 PM2/11/16
to Caché, Ensemble, DeepSee
I'm working on trying out our java app (which connects to Cache DB through the jdbc driver) on the Wildfly App Server. We've been demoing on glassfish so far and it has worked fine. I'm getting a strange error and I wondered if someone had seen it before. The error is actually happening in the jdbc driver. Looking through the byte code of the driver (I think I know how to read it), it looks like theres a .equals on the host name, and somehow the host name is null. This error is happening when running the app and when running the test connection in the admin console. I believe the jdbc driver is the latest. Any help is appreciated.

Server:server-one] 09:17:53,348 WARN  [org.jboss.jca.core.connectionmanager.poo
l.strategy.OnePool] (ServerService Thread Pool -- 59) IJ000604: Throwable while
attempting to get a new connection: null: javax.resource.ResourceException: IJ03
1084: Unable to create connection
[Server:server-one]     at org.jboss.jca.adapters.jdbc.local.LocalManagedConnect
ionFactory.createLocalManagedConnection(LocalManagedConnectionFactory.java:343)
[Server:server-one]     at org.jboss.jca.adapters.jdbc.local.LocalManagedConnect
ionFactory.getLocalManagedConnection(LocalManagedConnectionFactory.java:350)
[Server:server-one]     at org.jboss.jca.adapters.jdbc.local.LocalManagedConnect
ionFactory.createManagedConnection(LocalManagedConnectionFactory.java:285)
[Server:server-one]     at org.jboss.jca.core.connectionmanager.pool.mcp.Semapho
reConcurrentLinkedDequeManagedConnectionPool.createConnectionEventListener(Semap
horeConcurrentLinkedDequeManagedConnectionPool.java:1319)
[Server:server-one]     at org.jboss.jca.core.connectionmanager.pool.mcp.Semapho
reConcurrentLinkedDequeManagedConnectionPool.getConnection(SemaphoreConcurrentLi
nkedDequeManagedConnectionPool.java:496)
[Server:server-one]     at org.jboss.jca.core.connectionmanager.pool.AbstractPoo
l.internalTestConnection(AbstractPool.java:1061)
[Server:server-one]     at org.jboss.jca.core.connectionmanager.pool.strategy.On
ePool.testConnection(OnePool.java:93)
[Server:server-one]     at org.jboss.as.connector.subsystems.common.pool.PoolOpe
rations$TestConnectionInPool.invokeCommandOn(PoolOperations.java:234)
[Server:server-one]     at org.jboss.as.connector.subsystems.common.pool.PoolOpe
rations$1.execute(PoolOperations.java:90)
[Server:server-one]     at org.jboss.as.controller.AbstractOperationContext.exec
uteStep(AbstractOperationContext.java:890)
[Server:server-one]     at org.jboss.as.controller.AbstractOperationContext.proc
essStages(AbstractOperationContext.java:659)
[Server:server-one]     at org.jboss.as.controller.AbstractOperationContext.exec
uteOperation(AbstractOperationContext.java:370)
[Server:server-one]     at org.jboss.as.controller.OperationContextImpl.executeO
peration(OperationContextImpl.java:1344)
[Server:server-one]     at org.jboss.as.controller.ModelControllerImpl.internalE
xecute(ModelControllerImpl.java:392)
[Server:server-one]     at org.jboss.as.controller.ModelControllerImpl.execute(M
odelControllerImpl.java:217)
[Server:server-one]     at org.jboss.as.controller.remote.TransactionalProtocolO
perationHandler.internalExecute(TransactionalProtocolOperationHandler.java:247)
[Server:server-one]     at org.jboss.as.controller.remote.TransactionalProtocolO
perationHandler$ExecuteRequestHandler.doExecute(TransactionalProtocolOperationHa
ndler.java:185)
[Server:server-one]     at org.jboss.as.controller.remote.TransactionalProtocolO
perationHandler$ExecuteRequestHandler$1.run(TransactionalProtocolOperationHandle
r.java:138)
[Server:server-one]     at org.jboss.as.controller.remote.TransactionalProtocolO
perationHandler$ExecuteRequestHandler$1.run(TransactionalProtocolOperationHandle
r.java:134)
[Server:server-one]     at java.security.AccessController.doPrivileged(Native Me
thod)
[Server:server-one]     at javax.security.auth.Subject.doAs(Subject.java:360)
[Server:server-one]     at org.jboss.as.controller.AccessAuditContext.doAs(Acces
sAuditContext.java:81)
[Server:server-one]     at org.jboss.as.controller.remote.TransactionalProtocolO
perationHandler$ExecuteRequestHandler$2$1.run(TransactionalProtocolOperationHand
ler.java:157)
[Server:server-one]     at org.jboss.as.controller.remote.TransactionalProtocolO
perationHandler$ExecuteRequestHandler$2$1.run(TransactionalProtocolOperationHand
ler.java:153)
[Server:server-one]     at java.security.AccessController.doPrivileged(Native Me
thod)
[Server:server-one]     at org.jboss.as.controller.remote.TransactionalProtocolO
perationHandler$ExecuteRequestHandler$2.execute(TransactionalProtocolOperationHa
ndler.java:153)
[Server:server-one]     at org.jboss.as.protocol.mgmt.AbstractMessageHandler$Man
agementRequestContextImpl$1.doExecute(AbstractMessageHandler.java:363)
[Server:server-one]     at org.jboss.as.protocol.mgmt.AbstractMessageHandler$Asy
ncTaskRunner.run(AbstractMessageHandler.java:472)
[Server:server-one]     at java.util.concurrent.ThreadPoolExecutor.runWorker(Thr
eadPoolExecutor.java:1142)
[Server:server-one]     at java.util.concurrent.ThreadPoolExecutor$Worker.run(Th
readPoolExecutor.java:617)
[Server:server-one]     at java.lang.Thread.run(Thread.java:745)
[Server:server-one]     at org.jboss.threads.JBossThread.run(JBossThread.java:32
0)
[Server:server-one] Caused by: java.sql.SQLException: [Cache JDBC] Communication
 link failure: null
[Server:server-one]     at com.intersys.jdbc.CacheConnection.connect(CacheConnec
tion.java:1154)
[Server:server-one]     at com.intersys.jdbc.CacheConnection.<init>(CacheConnect
ion.java:434)
[Server:server-one]     at com.intersys.jdbc.CacheDataSource.getConnection(Cache
DataSource.java:115)
[Server:server-one]     at org.jboss.jca.adapters.jdbc.local.LocalManagedConnect
ionFactory.createLocalManagedConnection(LocalManagedConnectionFactory.java:312)
[Server:server-one]     ... 31 more
[Server:server-one] Caused by: java.lang.NullPointerException
[Server:server-one]     at com.intersys.jdbc.CacheConnection.connect(CacheConnec
tion.java:1019)
[Server:server-one]     ... 34 more
[Server:server-one]
[Server:server-one] 09:17:53,350 ERROR [org.jboss.as.controller.management-opera
tion] (ServerService Thread Pool -- 59) WFLYCTL0013: Operation ("test-connection
-in-pool") failed - address: ([
[Server:server-one]     ("subsystem" => "datasources"),
[Server:server-one]     ("data-source" => "CacheDb")
[Server:server-one] ]) - failure description: "WFLYJCA0040: failed to invoke ope
ration: WFLYJCA0047: Connection is not valid"
.

Kevin Mayfield

unread,
Feb 11, 2016, 2:36:54 PM2/11/16
to Caché, Ensemble, DeepSee
What's your connection String?

Nicholas Ilacqua

unread,
Feb 12, 2016, 12:33:15 PM2/12/16
to intersystems...@googlegroups.com
Here's the connection string with the secure bits replaced.

jdbc:Cache://192.168.xxx.xxx:1972/namespace

This connection string has been working properly in glassfish and SQuirreL SQL Client. 

This is probably an issue with Wildfly. I mentioned both JBoss and Wildfly in my original post. I actually used Wildfly 10.0.0-Final. After the post, I retried with JBoss 6.4 and it worked properly. The Wildlfly version is hot off the presses so maybe it needs some hardening still, or maybe something about Wildfly doesn't like the Cache JDBC driver. 

On Thu, Feb 11, 2016 at 11:36 AM, Kevin Mayfield <mayfiel...@gmail.com> wrote:
What's your connection String?

--
--
Caché, Ensemble, DeepSee

---
You received this message because you are subscribed to a topic in the Google Groups "Caché, Ensemble, DeepSee" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/intersystems-public-cache/AV_pu9kAKhg/unsubscribe.
To unsubscribe from this group and all its topics, send an email to intersystems-publi...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Kevin Mayfield

unread,
Feb 12, 2016, 4:17:58 PM2/12/16
to Caché, Ensemble, DeepSee
Sorry. Same as I'm using for camel and tomcat 8.
Reply all
Reply to author
Forward
0 new messages