db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dag H. Wanvik (Commented) (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (DERBY-3823) NullPointerException in stress.multi test
Date Wed, 28 Sep 2011 21:26:45 GMT

    [ https://issues.apache.org/jira/browse/DERBY-3823?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13116814#comment-13116814

Dag H. Wanvik commented on DERBY-3823:

The most likely way we could get NPE in this method is if the variable preparedStatement is
null. That only happens if EmbedPreparedStatement was closed prior to calling getMetaData
on it, I think.
PreparedStatement#close calls EmbedPreparedStatement#closeActions which nulls out EmbedPreparedStatement#preparedStatement
(line 244).
That variable is first consulted in line 1081:

//bug 4579 - if the statement is invalid, regenerate the metadata info
if (preparedStatement.isValid() == false)
   //need to revalidate the statement here, otherwise getResultDescription would
   //still have info from previous valid statement
   rMetaData = null;

No idea yet how this can happen.

> NullPointerException in stress.multi test
> -----------------------------------------
>                 Key: DERBY-3823
>                 URL: https://issues.apache.org/jira/browse/DERBY-3823
>             Project: Derby
>          Issue Type: Bug
>          Components: Network Server
>    Affects Versions:,
>            Reporter: Kathey Marsden
>              Labels: derby_triage10_5_2
>         Attachments: derby.log
> I saw the following NPE in stress.multi running on 10.3 with derbyclient.
> java.lang.NullPointerException
>         at org.apache.derby.impl.jdbc.EmbedPreparedStatement.getMetaData(Unknown
>  Source)
>         at org.apache.derby.impl.drda.DRDAConnThread.writeSQLDARD(Unknown Source
> )
>         at org.apache.derby.impl.drda.DRDAConnThread.processCommands(Unknown Sou
> rce)
>         at org.apache.derby.impl.drda.DRDAConnThread.run(Unknown Source)
> Cleanup action completed

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira


View raw message