dev@grizzly.java.net

R: Re: start&stop grizzly

From: <rama.rama_at_tiscali.it>
Date: Thu, 29 Jan 2009 17:06:43 +0100 (CET)

Done.

btw, when i issue a "STOP" what's happent to connected client?


if someone is downloading a 100mb porn movie from there, i don't wont
to kill the download :D

(ok ok i want to be politically correct,
replace porn with "educational content")

:)

----Messaggio
originale----
Da: Oleksiy.Stashok_at_Sun.COM
Data: 29/01/2009 16.52
A:
<dev_at_grizzly.dev.java.net>
Ogg: Re: start&amp;stop grizzly

Hi Rama,


can you pls. fill issue? I'll fix this ASAP.

WBR,
Alexey.

On Jan 29,
2009, at 12:07 , rama.rama_at_tiscali.it wrote:

> Hello :)
>
> I want to
know if is possible to start/stop grizzly
> webserver.
>
> what i have
try to do, quite obviusly is
>
> start();
> <wait
> for sometimes>
>
stop();
> <wait again>
> start();
>
> what's happen is
> 1st
> start()
--> Grizzly goes online :D you can use it, browse the page and
> so on

> 1st stop() --> grizzly shutdown, the pages are offline, and you
>
can't connect to the port
> 2nd start() --> buumm :)
>
> ipc.http.
newHttp.
> WebServer$2:108 java.lang.IllegalThreadStateException
> java.
lang.Thread.
> start(Thread.java:595)
> com.sun.grizzly.http.
SelectorThread.listen
> (SelectorThread.java:1156)
> com.sun.grizzly.
http.embed.GrizzlyWebServer.
> start(GrizzlyWebServer.java:535)
> com.
eg.euler.ipc.http.newHttp.
> WebServer$2.call(WebServer.java:105)
>
java.util.concurrent.
> FutureTask$Sync.innerRun(FutureTask.java:303)
>
java.util.concurrent.
> FutureTask.run(FutureTask.java:138)
> java.util.
concurrent.
> ScheduledThreadPoolExecutor$ScheduledFutureTask.
access$301
> (ScheduledThreadPoolExecutor.java:98)
> java.util.
concurrent.
> ScheduledThreadPoolExecutor$ScheduledFutureTask.run
>
(ScheduledThreadPoolExecutor.java:207)
> java.util.concurrent.
>
ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
> java.

> util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.
java:
> 908)
> java.lang.Thread.run(Thread.java:619)
>
>
> This
webserver is
> configured to have 2 adapter, plus some other stuff ie:

>
> this.
> getStatistics().startGatheringStatistics();
>
this.
> getSelectorThread().setCompression("on");
> this.
>
getSelectorThread().setDisplayConfiguration(true);
> this.
>
addGrizzlyAdapter(new EulerResAdapter()); //resadapter extends
>
GrizzlyAdapter
> this.addAsyncFilter(new EulerAsyncAdapter());
>
//eulerasync extends AsyncFilter
>
>
> what i suppose that this piece
of
> code do (start/stop)
> was, stop the ws (maybe if there is pending

> connection, keep serving it, as a sort of graceful restart of
apache
> or
> lighttpd)
> start the ws (after the stop is issued, and
completed, i
> should be able to restart it)
>
> best regards
>
> Rama

>
>
> Attiva Tiscali Tutto Incluso: telefoni e navighi senza limiti A
SOLI
> €10 AL MESE FINO ALL’ESTATE. Attiva entro il 29/01/09! http:
//abbonati.tiscali.it/promo/tuttoincluso/
>
>
---------------------------------------------------------------------
>
To unsubscribe, e-mail: dev-unsubscribe_at_grizzly.dev.java.net
> For
additional commands, e-mail: dev-help_at_grizzly.dev.java.net
>



---------------------------------------------------------------------

To unsubscribe, e-mail: dev-unsubscribe_at_grizzly.dev.java.net
For
additional commands, e-mail: dev-help_at_grizzly.dev.java.net






Attiva Tiscali Tutto Incluso: telefoni e navighi senza limiti A SOLI €10 AL MESE FINO ALL’ESTATE. Attiva entro il 29/01/09! http://abbonati.tiscali.it/promo/tuttoincluso/