Uploaded image for project: 'Derby'
  1. Derby
  2. DERBY-3513

NullPointerException in newBrokeredStatement in app server environment

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Cannot Reproduce
    • Affects Version/s: 10.1.3.2
    • Fix Version/s: None
    • Component/s: JDBC
    • Labels:
      None
    • Environment:
      Java Version: 1.5.0
      Java Vendor: IBM Corporation
      OS name: Linux
      OS architecture: x86
      OS version: 2.6.9-55.ELsmp

      Description

      User reports in an app server environment an intermittent NullPointerException
      with the 10.1 trace:

      R java.lang.NullPointerException
      org.apache.derby.iapi.jdbc.BrokeredConnection.newBrokeredStatement(BrokeredConnection.java:448)

      ...org.apache.derby.jdbc.XAStatementControl.<init>(XAStatementControl.java:62)
      ...org.apache.derby.jdbc.EmbedXAConnection.wrapStatement(EmbedXAConnection.java:827)
      org.apache.derby.iapi.jdbc.BrokeredConnection.createStatement(BrokeredConnection.java:296)
      [snip user trace]

      The code at line 448 is simply:
      return new BrokeredStatement(statementControl, getJDBCLevel());

      so not much room for an NPE there. I added println statements to identify the state values and where the NPE is actually occurring but that seemed to make the
      problem go away. It may be a JIT issue.

      I gave them the fix for DERBY-2142 and that did not correct the problem.

        Attachments

        1. derby-3513_diff.txt
          2 kB
          Katherine Marsden

          Issue Links

            Activity

              People

              • Assignee:
                kmarsden Katherine Marsden
                Reporter:
                kmarsden Katherine Marsden
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: