httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Creg Zolast <>
Subject [users@httpd] Timers and counters in Apache module
Date Fri, 27 Sep 2013 09:54:34 GMT
I am currently developing a module in Apache 2.4.4

I need a counter that is going to count all requests in the system and
based on a small processing, some of them are to be tagged and counted
separately. I would like to do this the right way, in memory and not using
shared file on the hard disk.

At this point I can have a thread-safe counter per worker but I want to
save it periodically into a DB. I was looking for some kind of timer-based
event or something, or something like idle-event hook or anything
(whatchdog would be my last idea) to be able to save periodically these
counters into a DB.

Another way I found is working with shared memory like this example does:
but I have a doubt that the shared memory is actually a file on disk and
for each counter incrementation the hard disk is accessed.

Please help me getting on the right track. Thank you.


View raw message