Could you try connecting to the offending process and getting a stack dump.
VisualVM should do the trick. That should tell us which thread is the
problem.

On Friday, October 28, 2011, Laird Nelson <[email protected]> wrote:
> I've added another test case to show what I mean and have attached the
whole thing as a Maven project again.
>
> Here's the relevant test:
>
> @Test
>   public void testSpawnAndShutdown() throws Exception {
>     final File temp = new File(System.getProperty("java.io.tmpdir"));
>
>     final File javaHome = new File(System.getProperty("java.home"));
>     final File bin = new File(javaHome, "bin");
>     final File java = new File(bin, "java");
>
>     final ProtectionDomain pd = Server.class.getProtectionDomain();
>     assertNotNull(pd);
>     final CodeSource cs = pd.getCodeSource();
>     assertNotNull(cs);
>     final URL location = cs.getLocation();
>     assertNotNull(location);
>     final File h2JarFile = new File(location.toURI());
>
>     final String[] args = new String[] { java.getAbsolutePath(), "-cp",
h2JarFile.getAbsolutePath(), Server.class.getName(), "-tcp", "-baseDir",
temp.getAbsolutePath(), "-trace" };
>     final ProcessBuilder pb = new ProcessBuilder(args);
>     final Process p = pb.start();
>     assertNotNull(p);
>
>     org.h2.server.TcpServer.shutdown("tcp://localhost:9092", null, false,
false);
>
>     System.out.println("Shutdown complete...but not really!");
>
>     assertEquals(0, p.exitValue()); // XXX kaboom
>
>   }
>
> On my MacBook Pro, the last assertEquals() fails reliably--shutdown
completes, as you can see, but the process does not in fact exit.  You can
see this for yourself by doing a ps -ef | grep h2.
>
> Like I said, I'm not sure if this is a bug or if it's just me not using
ProcessBuilder correctly.
>
> Best,
> Laird
>
> --
> You received this message because you are subscribed to the Google Groups
"H2 Database" group.
> To view this discussion on the web visit
https://groups.google.com/d/msg/h2-database/-/YO2aKN5RwE0J.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
[email protected].
> For more options, visit this group at
http://groups.google.com/group/h2-database?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups "H2 
Database" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/h2-database?hl=en.

Reply via email to