[CONJ-616] Null Pointer Exception on getConnection() Created: 2018-05-31 Updated: 2019-02-08 Resolved: 2018-09-03 |
|
| Status: | Closed |
| Project: | MariaDB Connector/J |
| Component/s: | Failover |
| Affects Version/s: | 2.2.4, 2.2.5, 2.2.6 |
| Fix Version/s: | 2.3.0, 1.8.0 |
| Type: | Bug | Priority: | Critical |
| Reporter: | Joseph Witthuhn | Assignee: | Diego Dupin |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Environment: |
Amazon Linux |
||
| Description |
|
We are connecting to an AWS Aurora RDS datasource using a connection string that looks like this: When calling getConnection(), we see this error message. It looks like there is a NullPointerException occuring somewhere within the driver code:
We first saw this after upgrading to 2.2.5. |
| Comments |
| Comment by Joseph Witthuhn [ 2018-06-04 ] | |||||||||||
|
It turns out this wasn't related to the upgrade to 2.2.5, but 2.2.5 has a change that changed it from a meaningful exception to this NullPointerException. If we downgrade to 2.2.4, we get a better stack trace.
Despite the fact that the underlying issue is with our connection string and not a problem with the driver, I still think we wouldn't want an incorrect hostname in a connection string to lead to an NPE, so I'll leave this open, but lower the priority. | |||||||||||
| Comment by Joseph Witthuhn [ 2018-06-07 ] | |||||||||||
|
We are actually getting a different NullPointerException in 2.2.4, but at a very low frequency (about 1 time in every 200 connection attempts). We rolled back to 2.2.1 (which we have been using since January without issue), and the issue went away.
This might belong as a separate bug report - I can create a separate issue if you'd prefer it to be reported that way. | |||||||||||
| Comment by Joseph Witthuhn [ 2018-08-23 ] | |||||||||||
|
We continue to see the same NullPointerException issue from 2.2.5 in 2.2.6. Here is an updated stack trace with updated line numbers for 2.2.6:
(The context here is that the calls are coming via Flyway 4.0.3...) |