Uploaded image for project: 'MariaDB Connector/J'
  1. MariaDB Connector/J
  2. CONJ-616

Null Pointer Exception on getConnection()

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 2.2.4, 2.2.5, 2.2.6
    • Fix Version/s: 2.3.0, 1.8.0
    • Component/s: Failover
    • Labels:
      None
    • Environment:
      Amazon Linux
      Java 8

      Description

      We are connecting to an AWS Aurora RDS datasource using a connection string that looks like this:
      jdbc:mariadb:aurora://XXXXX.cluster-XXXXX.eu-west-1.rds.amazonaws.com:3306/XXXXX?socketTimeout=0&useSSL=true&connectTimeout=31000

      When calling getConnection(), we see this error message. It looks like there is a NullPointerException occuring somewhere within the driver code:

      java.lang.NullPointerException: null
      	at org.mariadb.jdbc.internal.failover.AbstractMastersListener.throwFailoverMessage(AbstractMastersListener.java:506)
      	at org.mariadb.jdbc.internal.failover.impl.MastersSlavesListener.checkInitialConnection(MastersSlavesListener.java:300)
      	at org.mariadb.jdbc.internal.failover.impl.MastersSlavesListener.initializeConnection(MastersSlavesListener.java:169)
      	at org.mariadb.jdbc.internal.failover.FailoverProxy.<init>(FailoverProxy.java:116)
      	at org.mariadb.jdbc.internal.util.Utils.retrieveProxy(Utils.java:485)
      	at org.mariadb.jdbc.MariaDbConnection.newConnection(MariaDbConnection.java:155)
      	at org.mariadb.jdbc.MariaDbDataSource.getConnection(MariaDbDataSource.java:288)
      

      We first saw this after upgrading to 2.2.5.

        Attachments

          Activity

            People

            • Assignee:
              diego dupin Diego Dupin
              Reporter:
              joseph.witthuhn Joseph Witthuhn
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: