db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dag.Wan...@Sun.COM (Dag H. Wanvik)
Subject Re: NSinSameVM can't find DRDAProtocolExceptionInfo class (solarisx86, JDK 1.4)
Date Sat, 20 May 2006 01:55:57 GMT


I looked at this again: This is my understanding so far.

I think this is a problem with the test and/or the server code.
Apperently there is a race condition between the connection being
closed and the shutdown of the server.  This test starts its own
server and then opens and closes a connection to it, in this case via
the derby client driver.  Skeleton code:

  conn = DriverManager.getConnection(<derby client>)
         <inserting a small sleep here makes problem go away>

By inserting a small sleep between the close and the shutdown, the
test works in my environment. I would guess the problem appears
because the server gets to (start) shut down *before* the close
message process is started/completed, and when the server DRDA
protocol code is in the process of handling the close, the server is
going down, hence the class not found exceptions.

I'll file a JIRA for the test.

The larger question is: Is there any way to avoid this in the server?
Users can hit this one, too, and it would be nice if the server were
more rubust. I think is possibly related to the problem discussed
under JIRA-1219 and DERBY-1326, although in those cases, the problems
occur further down the line: ghost sessions remain after shutdown
causing trouble on restart. 


David Van Couvering <David.Vancouvering@Sun.COM> writes:

> On Solaris x86 on JDK 1.4, I am getting the following diff in my
> derbynetclient tests:
> java.lang.NoClassDefFoundError:
> org/apache/derby/impl/drda/DRDAProtocolExceptionInfo
>         at
> org.apache.derby.impl.drda.DRDAProtocolException.<clinit>(DRDAProtocolException.java:108)
>         at
> org.apache.derby.impl.drda.DRDAConnThread.markCommunicationsFailure(DRDAConnThread.java:411)
>         at org.apache.derby.impl.drda.DDMReader.fill(DDMReader.java:1724)
>         at
> org.apache.derby.impl.drda.DDMReader.ensureALayerDataInBuffer(DDMReader.java:1473)
>         at
> org.apache.derby.impl.drda.DDMReader.readDssHeader(DDMReader.java:315)
>         at
> org.apache.derby.impl.drda.DRDAConnThread.processCommands(DRDAConnThread.java:628)
>         at
> org.apache.derby.impl.drda.DRDAConnThread.run(DRDAConnThread.java:238)
> I get the same error for DerbyNetNewServer
> I looked in my classes directory, the class is definitely there.
> I checked the regression tests, and this message is not there.
> Does anyone have any ideas what this might be about?  I'm not sure how
> much time I am willing to spend tracking this down, but it is a little
> disconcerting...
> Thanks,
> David

Dag H. Wanvik
Sun Microsystems, Database Technology Group (DBTG)
Haakon VII gt. 7b, N-7485 Trondheim, Norway
Tel: x43496/+47 73842196, Fax:  +47 73842101

View raw message