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 "Bryan Pendleton (JIRA)" <de...@db.apache.org> on 2006/08/22 16:56:14 UTC

[jira] Commented: (DERBY-1743) derbynet/testSecMec.java fails with NullPointerException (intermittent failure)

    [ http://issues.apache.org/jira/browse/DERBY-1743?page=comments#action_12429733 ] 
            
Bryan Pendleton commented on DERBY-1743:
----------------------------------------

This is almost certainly from line 298 of DRDAProtocolException.java, which reads:

  this.printStackTrace(s.logWriter);

s.logWriter is a reference to the parent server's log writer, which has probably
been cleared at this point because we're shutting down.

This type of bug seems very related to the ball of yarn I was pulling on in
DERBY-1326, having to do with the complexities of shutting down the Network Server
in a controlled fashion.

In this particular case, you might be able to get by with something like:

PrintStream strm = s.logWriter;
if (strm == null) strm = System.err;
this.printStackTrace(strm);


> derbynet/testSecMec.java fails with NullPointerException (intermittent failure)
> -------------------------------------------------------------------------------
>
>                 Key: DERBY-1743
>                 URL: http://issues.apache.org/jira/browse/DERBY-1743
>             Project: Derby
>          Issue Type: Bug
>          Components: Regression Test Failure
>    Affects Versions: 10.3.0.0
>         Environment: Solaris 10 x86, Sun JVM 1.5.0_04
>            Reporter: Knut Anders Hatlen
>
> http://www.multinet.no/~solberg/public/Apache/TinderBox_Derby/testlog/SunOS-5.10_i86pc-i386/433374-derbyall_diff.txt
> ********* Diff file derbyall/derbynetclientmats/DerbyNetClient/derbynetmats/derbynetmats/testSecMec.diff
> *** Start: testSecMec jdk1.5.0_04 DerbyNetClient derbynetmats:derbynetmats 2006-08-22 01:45:28 ***
> 61a62,63
> > java.sql.SQLException: No current connection.
> > Exception in thread "DRDAConnThread_15" java.lang.NullPointerException
> Test Failed.
> *** End:   testSecMec jdk1.5.0_04 DerbyNetClient derbynetmats:derbynetmats 2006-08-22 01:46:05 ***
> Detailed log:
> Test USRSSBPWD_with_BUILTIN - derby.drda.securityMechanism=null
> Turning ON Derby BUILTIN authentication
> USRSSBPWD (T0): jdbc:derby://localhost:20000/wombat;user=neelima;password=lee;shutdown=true;securityMechanism=8 - EXCEPTION DERBY SQL error: SQLCODE: -1, SQLSTATE: 08006, SQLERRMC: Database 'wombat' shutdown.
> java.sql.SQLException: No current connection.
> 	at org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(Unknown Source)
> 	at org.apache.derby.impl.jdbc.Util.newEmbedSQLException(Unknown Source)
> 	at org.apache.derby.impl.jdbc.Util.newEmbedSQLException(Unknown Source)
> 	at org.apache.derby.impl.jdbc.Util.noCurrentConnection(Unknown Source)
> 	at org.apache.derby.impl.jdbc.EmbedConnection.checkIfClosed(Unknown Source)
> 	at org.apache.derby.impl.jdbc.EmbedConnection.setupContextStack(Unknown Source)
> 	at org.apache.derby.impl.jdbc.EmbedConnection.rollback(Unknown Source)
> 	at org.apache.derby.impl.drda.Database.close(Unknown Source)
> 	at org.apache.derby.impl.drda.Session.close(Unknown Source)
> 	at org.apache.derby.impl.drda.DRDAConnThread.closeSession(Unknown Source)
> 	at org.apache.derby.impl.drda.DRDAConnThread.run(Unknown Source)
> Exception in thread "DRDAConnThread_15" java.lang.NullPointerException
> 	at java.lang.Throwable.printStackTrace(Throwable.java:509)
> 	at org.apache.derby.impl.drda.DRDAProtocolException.<init>(Unknown Source)
> 	at org.apache.derby.impl.drda.DRDAProtocolException.newAgentError(Unknown Source)
> 	at org.apache.derby.impl.drda.DRDAConnThread.sendUnexpectedException(Unknown Source)
> 	at org.apache.derby.impl.drda.DRDAConnThread.closeSession(Unknown Source)
> 	at org.apache.derby.impl.drda.DRDAConnThread.run(Unknown Source)

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira