You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by "Kathey Marsden (Updated) (JIRA)" <ji...@apache.org> on 2012/02/17 18:53:59 UTC

[jira] [Updated] (DERBY-5317) NullPointerException in org.apache.derby.client.net.Request.sendBytes() with client

     [ https://issues.apache.org/jira/browse/DERBY-5317?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Kathey Marsden updated DERBY-5317:
----------------------------------

    Labels: derby_triage10_9  (was: )

Triaged for 10.9.  Keeping urgency as urgent as it is a client crash and has a simple reproduction.

I confirmed the issue reproduces with Repro5317.java  attached and very quickly (in case someone has been shying away from this issue because I mentioned it takes a long time to reproduce with LobLimitsTest.


$ java Repro5317
Fri Feb 17 09:49:50 PST 2012 : Apache Derby Network Server - 10.9.0.0 alpha - (1242867M) started and ready to accept con
nections on port 1527
========================================
START insert  clob  -insertClob of size = 31744
Insert Clob (31744) rows= 2 = 382
Rows inserted with clob of size (31744) = 2
========================================
========================================
START ClobTest #4 - select and then update clob of size= 31744 - Uses setClob api
Fri Feb 17 09:49:52 PST 2012 : Execution failed because of a Distributed Protocol Error:  DRDA_Proto_SYNTAXRM; CODPNT ar
g  = 200d; Error Code Value = 1d. Plaintext connection attempt from an SSL enabled client?
org.apache.derby.impl.drda.DRDAProtocolException: Execution failed because of a Distributed Protocol Error:  DRDA_Proto_
SYNTAXRM; CODPNT arg  = 200d; Error Code Value = 1d. Plaintext connection attempt from an SSL enabled client?
        at org.apache.derby.impl.drda.DRDAConnThread.throwSyntaxrm(DRDAConnThread.java:537)
        at org.apache.derby.impl.drda.DRDAConnThread.invalidCodePoint(DRDAConnThread.java:8295)
        at org.apache.derby.impl.drda.DRDAConnThread.parseEXCSQLSTTobjects(DRDAConnThread.java:4366)
        at org.apache.derby.impl.drda.DRDAConnThread.parseEXCSQLSTT(DRDAConnThread.java:4175)
        at org.apache.derby.impl.drda.DRDAConnThread.processCommands(DRDAConnThread.java:1063)
        at org.apache.derby.impl.drda.DRDAConnThread.run(DRDAConnThread.java:295)
Fri Feb 17 09:49:52 PST 2012 : Execution failed because of a Distributed Protocol Error:  DRDA_Proto_SYNTAXRM; CODPNT ar
g  = 200d; Error Code Value = 1d. Plaintext connection attempt from an SSL enabled client?
org.apache.derby.impl.drda.DRDAProtocolException: Execution failed because of a Distributed Protocol Error:  DRDA_Proto_
SYNTAXRM; CODPNT arg  = 200d; Error Code Value = 1d. Plaintext connection attempt from an SSL enabled client?
        at org.apache.derby.impl.drda.DRDAConnThread.throwSyntaxrm(DRDAConnThread.java:537)
        at org.apache.derby.impl.drda.DRDAConnThread.invalidCodePoint(DRDAConnThread.java:8295)
        at org.apache.derby.impl.drda.DRDAConnThread.parseEXCSQLSTTobjects(DRDAConnThread.java:4366)
        at org.apache.derby.impl.drda.DRDAConnThread.parseEXCSQLSTT(DRDAConnThread.java:4175)
        at org.apache.derby.impl.drda.DRDAConnThread.processCommands(DRDAConnThread.java:1063)
        at org.apache.derby.impl.drda.DRDAConnThread.run(DRDAConnThread.java:295)
Exception in thread "main" java.lang.NullPointerException
        at org.apache.derby.client.net.Request.sendBytes(Request.java:1212)
        at org.apache.derby.client.net.Request.flushScalarStreamSegment(Request.java:604)
        at org.apache.derby.client.net.Request.padScalarStreamForError(Request.java:660)
        at org.apache.derby.client.net.Request.writePlainScalarStream(Request.java:323)
        at org.apache.derby.client.net.Request.writeScalarStream(Request.java:247)
        at org.apache.derby.client.net.Request.writeScalarStream(Request.java:500)
        at org.apache.derby.client.net.NetStatementRequest.buildEXTDTA(NetStatementRequest.java:1042)
        at org.apache.derby.client.net.NetStatementRequest.writeExecute(NetStatementRequest.java:151)
        at org.apache.derby.client.net.NetPreparedStatement.writeExecute_(NetPreparedStatement.java:174)
        at org.apache.derby.client.am.PreparedStatement.writeExecute(PreparedStatement.java:1806)
        at org.apache.derby.client.am.PreparedStatement.flowExecute(PreparedStatement.java:2036)
        at org.apache.derby.client.am.PreparedStatement.executeUpdateX(PreparedStatement.java:417)
        at org.apache.derby.client.am.PreparedStatement.executeUpdate(PreparedStatement.java:403)
        at Repro5317.selectUpdateClob(Repro5317.java:170)
        at Repro5317.main(Repro5317.java:42)

kmarsden@IBM-JDPM42DBIO2 ~/repro/derby-5317























think Urgent is correct as 
                
>  NullPointerException in org.apache.derby.client.net.Request.sendBytes()  with client
> -------------------------------------------------------------------------------------
>
>                 Key: DERBY-5317
>                 URL: https://issues.apache.org/jira/browse/DERBY-5317
>             Project: Derby
>          Issue Type: Bug
>          Components: Network Client
>    Affects Versions: 10.9.0.0
>            Reporter: Kathey Marsden
>              Labels: derby_triage10_9
>         Attachments: Repro5317.java, Repro5317.java, traces_10_2and10_9.zip
>
>
> Investigating DERBY-5308, I found that the LobLimits.java test run with client fails with a NullPointerException.
>  
> END setup
> ========================================
> START ClobTest #1  -insertClob of size = 2147483647
> Rows inserted with clob of size (2147483647) = 2
> ========================================
> ========================================
> START ClobTest #2 - SELECT CLOB of size = 2147483647
> Matched rows selected with clob of size(2147483647) =1
> ========================================
> ========================================
> START ClobTest #3 - SELECT CLOB of size = 2147483647
> Matched rows selected with clob of size(2147483647) =1
> ========================================
> ========================================
> START ClobTest #4 - select and then update clob of size= 2147483647 - Uses setClob api
> FAIL -- Unexpected exception:
> java.lang.NullPointerException
>         at org.apache.derby.client.net.Request.sendBytes(Unknown Source)
>         at org.apache.derby.client.net.Request.flushScalarStreamSegment(Unknown Source)
>         at org.apache.derby.client.net.Request.padScalarStreamForError(Unknown Source)
>         at org.apache.derby.client.net.Request.writePlainScalarStream(Unknown Source)
>         at org.apache.derby.client.net.Request.writeScalarStream(Unknown Source)
>         at org.apache.derby.client.net.Request.writeScalarStream(Unknown Source)
>         at org.apache.derby.client.net.NetStatementRequest.buildEXTDTA(Unknown Source)
>         at org.apache.derby.client.net.NetStatementRequest.writeExecute(Unknown Source)
>         at org.apache.derby.client.net.NetPreparedStatement.writeExecute_(Unknown Source)
>         at org.apache.derby.client.am.PreparedStatement.writeExecute(Unknown Source)
>         at org.apache.derby.client.am.PreparedStatement.flowExecute(Unknown Source)
>         at org.apache.derby.client.am.PreparedStatement.executeUpdateX(Unknown Source)
>         at org.apache.derby.client.am.PreparedStatement.executeUpdate(Unknown Source)
>         at org.apache.derbyTesting.functionTests.tests.largedata.LobLimits.selectUpdateClob(LobLimits.java:115
> 7)
>         at org.apache.derbyTesting.functionTests.tests.largedata.LobLimits.clobTests(LobLimits.java:313)
>         at org.apache.derbyTesting.functionTests.tests.largedata.LobLimits.runTests(LobLimits.java:177)
>         at org.apache.derbyTesting.functionTests.tests.largedata.LobLimits.main(LobLimits.java:151)
> ========================================
> START ClobTest #12.1  -insertClob of size = 104857600
> NEGATIVE TEST - Expected Exception:
> EXPECTED SQL Exception: (08003) No current connection.
> ========================================
> START ClobTest #12.2 - SELECT CLOB of size = 104857600
> FAIL -- Unexpected exception:
> java.sql.SQLNonTransientConnectionException: No current connection.
>         at org.apache.derby.client.am.SQLExceptionFactory40.getSQLException(Unknown Source)
>         at org.apache.derby.client.am.SqlException.getSQLException(Unknown Source)
>         at org.apache.derby.client.am.PreparedStatement.setInt(Unknown Source)
>         at org.apache.derbyTesting.functionTests.tests.largedata.LobLimits.selectClob(LobLimits.java:1007)
> In the derby.log I see
> derby.system.home=/local0/kmarsden/repro/largeData/testtrunkdnc/DerbyNetClient/LobLimits
> Database Class Loader started - derby.database.classpath=''
> Tue Jul 05 17:50:01 PDT 2011 Thread[DRDAConnThread_11,5,main] (DATABASE = wombat), (DRDAID = .-580681567053183
> 269{2}), Execution failed because of a Distributed Protocol Error:  DRDA_Proto_SYNTAXRM; CODPNT arg  = 200d; E
> rror Code Value = 1d. Plaintext connection attempt from an SSL enabled client?
> Tue Jul 05 17:50:01 PDT 2011 : Execution failed because of a Distributed Protocol Error:  DRDA_Proto_SYNTAXRM;
>  CODPNT arg  = 200d; Error Code Value = 1d. Plaintext connection attempt from an SSL enabled client?
> org.apache.derby.impl.drda.DRDAProtocolException: Execution failed because of a Distributed Protocol Error:  D
> RDA_Proto_SYNTAXRM; CODPNT arg  = 200d; Error Code Value = 1d. Plaintext connection attempt from an SSL enable
> d client?
>         at org.apache.derby.impl.drda.DRDAConnThread.throwSyntaxrm(Unknown Source)
>         at org.apache.derby.impl.drda.DRDAConnThread.invalidCodePoint(Unknown Source)
>         at org.apache.derby.impl.drda.DRDAConnThread.parseEXCSQLSTTobjects(Unknown Source)
>         at org.apache.derby.impl.drda.DRDAConnThread.parseEXCSQLSTT(Unknown Source)
>         at org.apache.derby.impl.drda.DRDAConnThread.processCommands(Unknown Source)
>         at org.apache.derby.impl.drda.DRDAConnThread.run(Unknown Source)
> Tue Jul 05 17:50:01 PDT 2011 Thread[DRDAConnThread_11,5,main] (DATABASE = wombat), (DRDAID = .-580681567053183
> 269{2}), Execution failed because of a Distributed Protocol Error:  DRDA_Proto_SYNTAXRM; CODPNT arg  = 200d; E
> rror Code Value = 1d. Plaintext connection attempt from an SSL enabled client?
> Tue Jul 05 17:50:01 PDT 2011 : Execution failed because of a Distributed Protocol Error:  DRDA_Proto_SYNTAXRM;
>  CODPNT arg  = 200d; Error Code Value = 1d. Plaintext connection attempt from an SSL enabled client?
> org.apache.derby.impl.drda.DRDAProtocolException: Execution failed because of a Distributed Protocol Error:  D
> RDA_Proto_SYNTAXRM; CODPNT arg  = 200d; Error Code Value = 1d. Plaintext connection attempt from an SSL enable
> d client?
>         at org.apache.derby.impl.drda.DRDAConnThread.throwSyntaxrm(Unknown Source)
>         at org.apache.derby.impl.drda.DRDAConnThread.invalidCodePoint(Unknown Source)
>         at org.apache.derby.impl.drda.DRDAConnThread.parseEXCSQLSTTobjects(Unknown Source)
>         at org.apache.derby.impl.drda.DRDAConnThread.parseEXCSQLSTT(Unknown Source)
>         at org.apache.derby.impl.drda.DRDAConnThread.processCommands(Unknown Source)
>         at org.apache.derby.impl.drda.DRDAConnThread.run(Unknown Source)
> ----------------------------------------------------------------
> Tue Jul 05 17:50:07 PDT 2011: Shutting down Derby engine
> ----------------------------------------------------------------
> Tue Jul 05 17:50:07 PDT 2011:
> To run the test, you have to remove largeData from DerbyNetClient.exclude and run
> java -Dframework=DerbyNetClient org.apache.derbyTesting.functionTests.harness.RunTest  org.apache.derbyTesting.functionTests.tests.lageData.LobLimits.
> It took about 3.5 hours to occur.
> I will work on a smaller reproduction.
>                                                                                             5,9           36%

--
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