On Wed, 21 Aug 2002, Galbreath, Mark wrote: > Hello? HTTP is request-response, remember? He can't preemptively > respond before receiving a request.
McFly? If a request comes in within the "going to shutdown soon" period, then they can output the message. Not perfect, but it may help them get closer to the desired solution. Additionally, if they're working in an Apache/Tomcat environment, and "shutting down for maintenance" only involves bringing Tomcat down, then when that happens they can set something up with Apache that gives an "App is down" message. Further, if "shutting down for maintenance" only refers to taking the application out of service, and they can still leave Tomcat up, they can do even better. Of course, this all must be architected into the application, it doesn't come for free. And they have to decide exactly what the benefit of doing this is, and what the "cost" will be. *Broadcasting* a message may not be feasible, but outputting a "going to shutdown soon" message on requests that come in before the app is going to shutdown and outputting an "App is down" message while the app is down may very well be feasible. > -----Original Message----- > From: C�dric Viaud [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, August 21, 2002 9:01 AM > To: [EMAIL PROTECTED] > Subject: Re: How to broadcast a message > > > This is to notice users BEFORE the server shutdown. > > That was the question i understood. But maybe i am wrong. > > Regards, > > C�dric > > ----- Original Message ----- > From: "Galbreath, Mark" <[EMAIL PROTECTED]> > To: <[EMAIL PROTECTED]> > Sent: Wednesday, August 21, 2002 2:58 PM > Subject: Re: How to broadcast a message > > > > Uh, how's he gonna do that while Tomcat is down? > > > > -----Original Message----- > > From: C�dric Viaud [mailto:[EMAIL PROTECTED]] > > Sent: Wednesday, August 21, 2002 5:31 AM > > To: [EMAIL PROTECTED] > > Subject: Re: How to broadcast a message > > > > > > Or maybe, but it is an early idea (my brain is yet sleeping), you could > use > > a servletFilter if you use Servlet 2.3. > > > > So your front filter will redirect users to an HTML page whith your > message > > before processing requests. The filter could do it or not depending on > value > > in the application context. > > > > The servletFilter way avoid to modify all your JSPs. You just have to > modify > > your web.xml to indicate servlet filtering for all yours Servlet/JSP. > > > > Hope this help, > > > > regards, > > > > C�dric > > > > ----- Original Message ----- > > From: "Richard Yee" <[EMAIL PROTECTED]> > > To: <[EMAIL PROTECTED]> > > Sent: Wednesday, August 21, 2002 6:05 AM > > Subject: Re: How to broadcast a message > > > > > > > You could have all of your JSP's check for the presence of an > application > > > variable. If the variable is found, a JavaScript popup window can be > made > > > to appear the next time the server sends a response and the appropriate > > > message can be displayed. Note that the message will only appear once a > > > client makes a request to the server. If a client doesn't send a request > > to > > > the server between the time that you decide to send the message and the > > > time you shut the server down, they won't get a notification. There are > > > other things you could possibly do such as run applets on the client's > > > browser and have the server send messages to the applets, but I > personally > > > don't think it is worth the trouble and added overhead. > > > > > > Regards, > > > > > > Richard > > > > > > At 10:41 AM 8/21/2002 +0800, you wrote: > > > >Hi all, > > > > > > > >I have an application running on Tomcat. If I want to shutdown for > > > >maintenance. How do I broadcast a message to all the on-line user ? > > > >Kindly provide any pointer if possible. > > > > > > > >Thanks. > > > > > > > >Regards, > > > >KL > > > > > > > > > > Milt Epstein Research Programmer Systems and Technology Services (STS) Campus Information Technologies and Educational Services (CITES) University of Illinois at Urbana-Champaign (UIUC) [EMAIL PROTECTED] ___________________________________________________________________________ To unsubscribe, send email to [EMAIL PROTECTED] and include in the body of the message "signoff SERVLET-INTEREST". Archives: http://archives.java.sun.com/archives/servlet-interest.html Resources: http://java.sun.com/products/servlet/external-resources.html LISTSERV Help: http://www.lsoft.com/manuals/user/user.html
