You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@geronimo.apache.org by Emerson Cargnin <ec...@bol.com.br> on 2003/10/26 22:37:13 UTC
Start command doesn't reach execute method
While trying to debug geronimo, when the debugger reachs the following code :
ThreadGroup group = new ThreadGroup("Geronimo");
Thread mainThread = new Thread(group, main, "Main-Thread");
mainThread.start();
mainThread.join(); // stops here
return Command.SUCCESS;
It never gets to the return command as it stay paused in Thread.join() command.
Is this expected?
Emerson Cargnin
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.530 / Virus Database: 325 - Release Date: 22/10/2003
Re: Start command doesn't reach execute method
Posted by Jason Dillon <ja...@coredevelopers.net>.
Yup ;-) The return does not mean too much, except that a return value
is required from the Command interface. At some point, when the
interactive interpreter bits are in-place, the join can be dropped to
allow a user to execute more commands on the running instance.
--jason
On Sunday, October 26, 2003, at 04:56 PM, Aaron Mulder wrote:
> On Sun, 26 Oct 2003, Emerson Cargnin wrote:
>
>> While trying to debug geronimo, when the debugger reachs the
>> following code :
>>
>> ThreadGroup group = new ThreadGroup("Geronimo");
>> Thread mainThread = new Thread(group, main, "Main-Thread");
>> mainThread.start();
>> mainThread.join(); // stops here
>> return Command.SUCCESS;
>>
>> It never gets to the return command as it stay paused in
>> Thread.join() command.
>>
>>
>>
>> Is this expected?
>
> I assume so -- Thread.join() doesn't return into the thread you
> call it on finishes. So it looks like the main thread sets up and
> starts
> a Geronimo thread, and then waits for it to finish (which would
> presumably happen when the server shuts down).
>
> Aaron
>
Re: Start command doesn't reach execute method
Posted by Aaron Mulder <am...@alumni.princeton.edu>.
On Sun, 26 Oct 2003, Emerson Cargnin wrote:
> While trying to debug geronimo, when the debugger reachs the following code :
>
> ThreadGroup group = new ThreadGroup("Geronimo");
> Thread mainThread = new Thread(group, main, "Main-Thread");
> mainThread.start();
> mainThread.join(); // stops here
> return Command.SUCCESS;
>
> It never gets to the return command as it stay paused in Thread.join() command.
>
>
>
> Is this expected?
I assume so -- Thread.join() doesn't return into the thread you
call it on finishes. So it looks like the main thread sets up and starts
a Geronimo thread, and then waits for it to finish (which would
presumably happen when the server shuts down).
Aaron