[
https://issues.apache.org/jira/browse/STORM-1139?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14989921#comment-14989921
]
Robert Joseph Evans commented on STORM-1139:
--------------------------------------------
If line 88 is {code}this.jdbcClient.executeInsertQuery(this.insertQuery,
columnLists);{code} there really is only one option for what caused the NPE,
this.jdbcClient has to be null.
I assume PsqlBolt extends AbstractJdbcBolt your example code does not show
this. If so the JdbcClient is created in the prepare method. If you are
overriding the prepare method in your bolt and don't call
{code}super.prepare(...){code} the parent one will not be called and the
jdbcClient will not be created. That is the only thing I can think of that
would cause this to happen.
This analysis is something that you should be able to do yourself.
> Issues regarding storm-postgresql interface
> -------------------------------------------
>
> Key: STORM-1139
> URL: https://issues.apache.org/jira/browse/STORM-1139
> Project: Apache Storm
> Issue Type: Bug
> Reporter: hima
>
> hai
> I am trying to write storm bolt to insert data in postgesql DB.But i am
> facing issues like
> java.io.NotSerializableException:org.postgresql.jdbc4.Jdbc4Connection.
> Can anyone provide me full code for storm bolt that can insert data into
> postgres database.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)