users@glassfish.java.net

Re: Any way to change a Listener port on the fly?

From: <glassfish_at_javadesktop.org>
Date: Mon, 17 Sep 2007 11:20:17 PDT

Now, Jeanfrancois, if I wanted the users to be greeted by nasty error pages, I would simply kick the network cable out of the computer during the upgrade and be done with it! :-)

However, it looks like there MIGHT be hope here for me.

If I can simply disable the 80 listener, then I can quickly get Apache up and running to take over port 80 and present something...friendlier.

Unfortunately, there's a bug in GF right now that seems to require me to restart it when my application changes.

Also, there doesn't seem to be a mechanism to actually CHANGE a listener via a command line, rather it seems I can only create and delete them.

And I don't know if I can delete a listener that has a virtual server deployed against it, and I don't know if I can delete a VS that has an app deployed against it. So, I don't think I can simply delete and then quickly re add a listener without actually removing the applications (I may be wrong -- I know you can't remove the default application for a VS, for example).

So, I guess the meaty question is whether it's possible through playing with the appropriate MBean directly to make these changes. I mean, if I get the MBean to a listener and simply set the port to something else, will it Do The Right Thing.

I might be able to do all this by hand (via the GUI), but it doesn't look like I can easily script this, at least not without potentially some custom Java code to work the MBean directly vs using asadmin to do the heavy lifting.
[Message sent by forum member 'whartung' (whartung)]

http://forums.java.net/jive/thread.jspa?messageID=235675