Receiving Caused by: java.lang.StringIndexOutOfBoundsException: String index out of range: -1 when deploying a JDBC Datasource

Solution Verified - Updated -

Issue

Receiving

[org.jboss.jca.core.connectionmanager.pool.strategy.OnePool] (MSC 
service thread 1-2) IJ000604: Throwable while attempting to get a new 
connection: null: javax.resource.ResourceException: Could not create connection
...

Caused by: java.lang.StringIndexOutOfBoundsException: String index out of range: -1     at java.lang.String.substring(String.java:1937) [:1.6.0_29]     at org.jboss.jca.adapters.jdbc.local.LocalManagedConnectionFactory.getDriver(LocalManagedConnectionFactory.java:583)     at org.jboss.jca.adapters.jdbc.local.LocalManagedConnectionFactory.getLocalManagedConnection(LocalManagedConnectionFactory.java:248)

When deploying a datasource.

Environment

  • AS 7.1
  • EAP 6

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In
Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.