Quoting Knut Anders Hatlen <[EMAIL PROTECTED]>:
The patch is not applied to the 10.1 branch because of some minor
problems (NullPointerException can be printed to console when you shut
down Derby, but your application will continue to work). If you want
to try the fix, you can either download a snapshot of the development
version (http://www.multinet.no/~solberg/public/Apache/Derby/builds/)
or download the 10.1 sources and apply the patch yourself.
I see, I thought it had been applied in 10.1.1.1. Well that would explain why
the problem persisted. I will consider making my own build. I am also
investigating Eric's suggestion to move the derby libraries to the Tomcat
common folder.
When I do shutdown Derby the following 2 threads remain:
Thread [derby.antiGC] (Running)
Thread [derby.rawStoreDaemon] (Running)
The only time I have seen that the rawStoreDaemon has continued to run
after a shutdown, is when an error has occurred during the booting of
a database (e.g., invalid encryption password or wrong log device when
performing recovery). I have however seen rawStoreDaemons not being
garbage collected after they have been stopped.
How did you shut down Derby? Did you use
DriverManager.getConnection("jdbc:derby:;shutdown=true")? If you want
to shut down Derby entirely, there should be no database name in the
URL.
I do not receive any errors when starting the database using
NetworkServerControl.start method. I also shutdown the database using
NetworkServerControl.shutdown method. I do receive a socket error when
shutting
down, which seems to be used to indicate the successful shutdown of the
server.
The server is started and shutdown within the same JVM instance as my
application. This is not ideal but I am forced to do so if I want to have any
control over an environment in which I have extremely limited control.