underdev_apache_performance_monitoring

This is part of The Pile, a partial archive of some open source mailing lists and newsgroups.



Subject: Re: Apache::Perfmon 0.011
From: Lupe Christoph <lupe@lupe-christoph.de>
Date: Tue, 22 Aug 2000 08:37:22 +0200

On Monday, 2000-08-21 at 21:06:54 -0400, Greg Stark wrote:

> Lupe Christoph <lupe@lupe-christoph.de> writes:

> > Hmm. Apache::Benchmark sounds more like a benchmark driver to me.
> > Apache::Instrumentation or so? Apache::Probe?

> Profile or even just Prof.

I thought about it a little more. What is does is find the
(cpu|real)time taken to process a request. So what about
Apache::RequestTimer or maybe Apache::Perf::RequestTimer, creating
a new namespace for all performance-related modules?

> I looked at this and really like the idea. Unfortunately I need to recompile
> my Apache to use it.

Yeah, it inserts handlers in phases few modules touch. I should
mention that in my README.

> What I think it needs is, a way to gather the statistics in a hash based on
> the request. That way I can make a web page that pokes around in the hash
> table and reports the average and maximum time taken by page.

I'd rather not collect the statistics inside the module. Not only can
that inflate the process, it's also much better done seperately
because this way you can write your own statistics processor without
touching the gatherer.

I'll include a first shot at such a program in the next release.
After the naming discussion has settled down.

> I'm not clear how or if that can be done in a separate module like this that
> doesn't know how the requests are dispatched. Either a regexp needs to be
> provided that returns the key to use for the hash, or else something similar
> needs to be integrated into packages like CGI and Apache::ASP. (Which was the
> approach I was planning on taking myself.) I like this approach better though,
> so it would be neat to see it polished.

This times the entire request. I'll split the CPU times out in times
for the Apache process and that for it and all it's children in the
nect release to accomodate CGI. Can't do anything about FastCGI
and such things that run independent of the Apache process.

Is anybody running Apache+mod_perl under Win32 who could see if
times() and Time::HiRes give you timings of any significance
on that platform?

As for statistics, I'm thinking about splitting out the host
first, second the method (GET, POST, etc), then the URI, with the
request string removed, maybe the request strings under the URI
at a later time.

Print the top <n> requests by user CPU, system CPU, realtime.
Do that in plain text and HTML, with graphs later.

===





the rest of The Pile (a partial mailing list archive)

doom@kzsu.stanford.edu