dev@glassfish.java.net

Re: starting two copies of V3 (same ports...)

From: Lloyd L Chambers <Lloyd.Chambers_at_Sun.COM>
Date: Tue, 24 Jun 2008 11:03:58 -0700

Peter,

My understanding is that the V3 system is so module-based that failure
of a particular module doesn't necessarily mean that startup was
"unsuccessful". In V2, the code "knew" that failure of certain
containers was fatal (some of the time at least, there are clear bugs
in that area even in V2).

AFAIK in V3 we currently lack semantics of what "successful startup"
actually means:
- there is no "failure is fatal" flag (AFAIK) for a module, and it's
not clear that we should have such a flag;
- success could be multi-state: failed, started with errors, started
cleanly, etc.

Perhaps there should be some kind of pluggable listener service that
could make the decision as to whether a failure should be considered
fatal.

Lloyd

On Jun 24, 2008, at 10:43 AM, Peter Williams wrote:

> If I have two default installations of V3 TP2, I can start both of
> them via "asadmin start-domain". As expected, the first instance is
> fine. The second one has 3 bind exceptions in the log (shown below)
> but according to asadmin, start-domain was successful. The second
> process appears to be running (but is not the recipient of http
> calls on port 8080 - the first server instance gets those).
>
> Bug or Feature?
>
> Tail of log for second instance...
>
> ...
> INFO: Successfully launched in 201 msec.
> [#|2008-06-24T10:37:56.552-0700|INFO|GlassFish10.0|global|
> _ThreadID=11;_ThreadName=Thread-4;|Listening on port 8080|#]
>
> [#|2008-06-24T10:37:56.556-0700|INFO|GlassFish10.0|global|
> _ThreadID=11;_ThreadName=Thread-4;|Listening on port 8181|#]
>
> [#|2008-06-24T10:37:56.562-0700|INFO|GlassFish10.0|global|
> _ThreadID=11;_ThreadName=Thread-4;|Listening on port 4848|#]
>
> [#|2008-06-24T10:37:56.614-0700|INFO|GlassFish10.0|global|
> _ThreadID=11;_ThreadName=Thread-4;|Admin Console Adapter: context
> root: /admin|#]
>
> [#|2008-06-24T10:37:56.649-0700|INFO|GlassFish10.0|
> javax.enterprise.system.core|_ThreadID=11;_ThreadName=Thread-4;|
> Glassfish v3 started in 675 ms|#]
>
> [#|2008-06-24T10:37:56.811-0700|SEVERE|GlassFish10.0|
> javax.enterprise.system.container.web|
> _ThreadID=12;_ThreadName=Thread-4;|doSelect exception
> java.net.BindException: Address already in use:
> 8080=com.sun.grizzly.http.SelectorThreadHandler_at_e0cc23
> at
> com.sun.grizzly.TCPSelectorHandler.preSelect(TCPSelectorHandler.java:
> 331)
> at com.sun.grizzly.Controller.doSelect(Controller.java:332)
> at
> com.sun.grizzly.SelectorHandlerRunner.run(SelectorHandlerRunner.java:
> 67)
> at java.lang.Thread.run(Thread.java:619)
> |#]
>
> [#|2008-06-24T10:37:56.812-0700|SEVERE|GlassFish10.0|
> javax.enterprise.system.container.web|
> _ThreadID=14;_ThreadName=Thread-4;|doSelect exception
> java.net.BindException: Address already in use:
> 8181=com.sun.grizzly.http.SelectorThreadHandler_at_18941f7
> at
> com.sun.grizzly.TCPSelectorHandler.preSelect(TCPSelectorHandler.java:
> 331)
> at com.sun.grizzly.Controller.doSelect(Controller.java:332)
> at
> com.sun.grizzly.SelectorHandlerRunner.run(SelectorHandlerRunner.java:
> 67)
> at java.lang.Thread.run(Thread.java:619)
> |#]
>
> [#|2008-06-24T10:37:56.812-0700|SEVERE|GlassFish10.0|
> javax.enterprise.system.container.web|
> _ThreadID=13;_ThreadName=Thread-4;|doSelect exception
> java.net.BindException: Address already in use:
> 4848=com.sun.grizzly.http.SelectorThreadHandler_at_b4e29b
> at
> com.sun.grizzly.TCPSelectorHandler.preSelect(TCPSelectorHandler.java:
> 331)
> at com.sun.grizzly.Controller.doSelect(Controller.java:332)
> at
> com.sun.grizzly.SelectorHandlerRunner.run(SelectorHandlerRunner.java:
> 67)
> at java.lang.Thread.run(Thread.java:619)
> |#]
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: dev-help_at_glassfish.dev.java.net
>

---
Lloyd L Chambers
lloyd.chambers_at_sun.com
Sun Microsystems, Inc