Skip to content
This repository has been archived by the owner on Dec 3, 2019. It is now read-only.

getting NPE when connection not connected #215

Open
oshai opened this issue Mar 25, 2017 · 1 comment
Open

getting NPE when connection not connected #215

oshai opened this issue Mar 25, 2017 · 1 comment

Comments

@oshai
Copy link

oshai commented Mar 25, 2017

This happened because I didn't call connection.connect().
If it is possible, I suggest to improve the message in such case.
Here is the stacktrace:

Exception in thread "main" java.lang.NullPointerException
at com.github.mauricio.async.db.mysql.codec.MySQLConnectionHandler.com$github$mauricio$async$db$mysql$codec$MySQLConnectionHandler$$writeAndHandleError(MySQLConnectionHandler.scala:324)
at com.github.mauricio.async.db.mysql.codec.MySQLConnectionHandler.sendPreparedStatement(MySQLConnectionHandler.scala:208)
at com.github.mauricio.async.db.mysql.MySQLConnection.sendPreparedStatement(MySQLConnection.scala:241)

@oshai
Copy link
Author

oshai commented Sep 16, 2018

I merged a fix to the fork of jasync-sql: jasync-sql/jasync-sql#14

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant