Christopher Schultz wrote:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Dan,

Dan Armbrust wrote:
A simple cron job that points to a URL using lynx, and greps the
output for what it should see will do the trick...

I would use wget instead of Lynx, but that's just me.

Don't forget that the OP said that his JSPs appear to run correctly even
after the OOME.

If what you're concerned about is an OOME, you can have a JSP that queries the runtime memory usage and outputs something easily parsable to alert you to a (pending) problem. IE:

Runtime rt = Runtime.getRuntime();
double used = rt.totalMemory()-rt.freeMemory();
double free = rt.freeMemory();
double available =  rt.maxMemory()-rt.totalMemory();
double usedpercent = (used/rt.maxMemory()) * 100;
double freepercent = (free/rt.maxMemory()) * 100;
double availablepercent = (available/rt.maxMemory()) * 100;

If your normal state is used % is < 50%, you could send out a warning when it goes to 70% or restart if it goes to 90%.

--
Jeff Hoffmann
Head Plate Spinner
PropertyKey.com

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to