Re: mod_log_config

2002-08-27 Thread Dirk-Willem van Gulik
. Dw. On Sat, 24 Aug 2002, Ian Holsman wrote: > I want to change mod_log_config so that the open/writing of the logfile > can be overwritten by another module via optional functions. > > I think this would be handy for things log mod_log_spread and for people > who have to write a

Pluggable mod_log_config

2005-10-02 Thread Ondrej Sury
Hi, I am working on mod_log_spread for apache 2.0. Old mod_log_spread for apache 1.3 was based on some older version of mod_log_config and so it is my new version based on (recent) mod_log_config from apache 2.0.54. Right now any module which wants to implement custom logging has to reimplement

Bug in mod_log_config

2011-03-03 Thread Torsten Förtsch
Hi, mod_log_config contains these lines static const char *set_buffered_logs_on(cmd_parms *parms, void *dummy, int flag) { buffered_logs = flag; if (buffered_logs) { ap_log_set_writer_init(ap_buffered_log_writer_init); ap_log_set_writer(ap_buffered_log_writer

PATCH: mod_log_config, CookieLog

2011-09-18 Thread Rich Bowen
The CookieLog directive has been documented as deprecated since mod_log_config was introduced, back in the 1.2 days. Any objection to axing it? Index: docs/manual/mod/mod_log_config.xml === --- docs/manual/mod/mod_log_config.xml

Mod_log_config weird behavior

2004-02-03 Thread Chand
Hey guys, I'd like to tell about some problems i've had lately within mod_log_config. My company wants to use a certain cookie our product issues throughout a buying process to track our wanna-be-clients during their surfing to improve our buying process. I've successfully

Re: Pluggable mod_log_config

2005-10-03 Thread Brian Akins
mod_log_config is "pluggable." You can "replace" the normal logging functions quite easily. Just do something like: static apr_status_t my_logger_writer(request_rec *r, void *handle,

Re: Pluggable mod_log_config

2005-10-03 Thread Ondrej Sury
On Mon, 2005-10-03 at 07:58 -0400, Brian Akins wrote: > > mod_log_config is "pluggable." You can "replace" the normal logging > functions quite easily. The word here is _replace_. If you "replace" ap_log_writer and ap_log_writer_init you need t

Re: Pluggable mod_log_config

2005-10-03 Thread Brian Akins
Ondrej Sury wrote: Even now when you want to make some log files buffered and some not you are out of luck and this could also be solved by making plugging more "general". Ok I see what you mean and I agree. Maybe something stupid like a SetLogHandler similar to SetHandler? or as an argume

Re: Pluggable mod_log_config

2005-10-03 Thread Ondrej Sury
On Mon, 2005-10-03 at 09:19 -0400, Brian Akins wrote: > Ondrej Sury wrote: > > > Even now when you want to make some log files buffered and some not you > > are out of luck and this could also be solved by making plugging more > > "general". > > > Ok I see what you mean and I agree. Maybe somet

Re: Pluggable mod_log_config

2005-10-03 Thread Brian Akins
Akins, Brian wrote: Hmmm... Maybe custom loggers could be providers that have an init and a writer function. Maybe have customLog be something like this: CustomLog mysql://something common env=images CustomLog file:///logs/my.log combined CustomLog spread://somegroup refere CustomLog buffer:

Re: Pluggable mod_log_config

2005-10-03 Thread Brian Akins
Ondrej Sury wrote: You also need to store which writer to use in each config_log_state. This is already done. Also, init is called for each CustomLog config entry. -- Brian Akins Lead Systems Engineer CNN Internet Technologies

Re: Pluggable mod_log_config

2005-10-03 Thread Ondrej Sury
On Mon, 2005-10-03 at 09:35 -0400, Brian Akins wrote: > Ondrej Sury wrote: > > > You also need to store which writer to use in each config_log_state. > > This is already done. Nope, (void *)cls->log_writer is pointer to log file descriptor. > Also, init is called for each CustomLog config entry

Re: Pluggable mod_log_config

2005-10-03 Thread Brian Akins
writer_init retures whatever you function returns. In mod_log_config, it's an apr_file_t *. Currently, however, log_writer_init is global. It should be per cls, or per server. Also, init is called for each CustomLog config entry. Yep, but only ap_log_writer_init is called. You need t

Re: Pluggable mod_log_config

2005-10-03 Thread Ondrej Sury
a socket. See, open_config_log > > cls->log_writer = log_writer_init(p, s, cls->fname); > > log_writer_init retures whatever you function returns. In > mod_log_config, it's an apr_file_t *. Sorry for not being accurate. My point was that cls->log_writer hold logger *data

mod_log_config cookie buglet

2007-08-21 Thread Geoffrey Young
hi all :) a co-worker and I were just adding some functionality to an internal httpd module when we noticed that mod_log_config misbehaves when logging cookie values... in short, we have a cookie FOO and were adding a cookie CLIENT_FOO. in the log format we used %{FOO}C\t%{CLIENT_FOO}C but

mod_log_config changes break httpd?

2002-08-27 Thread Jeff Trawick
Apache won't initialize... look at the name passed when opening/creating the file: open("logs/access_log", O_WRONLY|O_APPEND|O_CREAT, 0666) = -1 ENOENT (No such file or directory) gettimeofday({1030448472, 125843}, NULL) = 0 write(2, "[Tue Aug 27 11:41:12 2002] [erro"..., 115) = 115 _exit(1) -

Re: Bug in mod_log_config

2011-03-03 Thread Torsten Förtsch
On Thursday, March 03, 2011 13:44:57 Torsten Förtsch wrote: > I have found that in 2.2.17. But I have verified it is also present in > trunk. Now filed as https://issues.apache.org/bugzilla/show_bug.cgi?id=50861 Torsten Förtsch -- Need professional modperl support? Hire me! (http://foertsch.nam

Re: Bug in mod_log_config

2011-03-03 Thread Jim Jagielski
Thx for the report and the patch... I will verify and apply to trunk w/ a backport req for 2.2. On Mar 3, 2011, at 8:45 AM, Torsten Förtsch wrote: > On Thursday, March 03, 2011 13:44:57 Torsten Förtsch wrote: >> I have found that in 2.2.17. But I have verified it is also present in >> trunk. > >

Re: Bug in mod_log_config

2011-03-10 Thread Torsten Förtsch
On Thursday, March 03, 2011 14:55:40 Jim Jagielski wrote: > Thx for the report and the patch... I will verify and apply > to trunk w/ a backport req for 2.2. any progress on that? > On Mar 3, 2011, at 8:45 AM, Torsten Förtsch wrote: > > On Thursday, March 03, 2011 13:44:57 Torsten Förtsch wrote:

Re: Bug in mod_log_config

2011-03-15 Thread Torsten Förtsch
On Thursday, March 03, 2011 14:55:40 Jim Jagielski wrote: > Thx for the report and the patch... I will verify and apply > to trunk w/ a backport req for 2.2. Just a polite reminder. > On Mar 3, 2011, at 8:45 AM, Torsten Förtsch wrote: > > On Thursday, March 03, 2011 13:44:57 Torsten Förtsch wrote

Re: Bug in mod_log_config

2011-03-17 Thread Jim Jagielski
On Mar 15, 2011, at 5:45 AM, Torsten Förtsch wrote: > On Thursday, March 03, 2011 14:55:40 Jim Jagielski wrote: >> Thx for the report and the patch... I will verify and apply >> to trunk w/ a backport req for 2.2. > > Just a polite reminder. > >> On Mar 3, 2011, at 8:45 AM, Torsten Förtsch wrot

Re: Bug in mod_log_config

2011-03-17 Thread Torsten Förtsch
On Thursday, March 17, 2011 16:05:12 Jim Jagielski wrote: > Added in r1082518. Thanks. Torsten Förtsch -- Need professional modperl support? Hire me! (http://foertsch.name) Like fantasy? http://kabatinte.net

Re: PATCH: mod_log_config, CookieLog

2011-09-19 Thread Graham Leggett
On 19 Sep 2011, at 1:28 AM, Rich Bowen wrote: The CookieLog directive has been documented as deprecated since mod_log_config was introduced, back in the 1.2 days. Any objection to axing it? Axe it, +1. Regards, Graham -- smime.p7s Description: S/MIME cryptographic signature

Re: PATCH: mod_log_config, CookieLog

2011-09-19 Thread Jim Jagielski
bye bye :) On Sep 18, 2011, at 7:28 PM, Rich Bowen wrote: > The CookieLog directive has been documented as deprecated since > mod_log_config was introduced, back in the 1.2 days. Any objection to axing > it? > > > > > Index: docs/manua

[PATCH] Re: Pluggable mod_log_config

2005-10-03 Thread Brian Akins
Akins, Brian wrote: CustomLog mysql://something common env=images CustomLog file:///logs/my.log combined CustomLog spread://somegroup refere CustomLog buffer:///logs/other.log common This patch implements the above. Within mod_log_config two providers are provided: file and buffer. If no

[PROPOSAL]: Bytes received v. mod_log_config

2002-08-18 Thread Bojan Smojver
I'm playing around with a patch for mod_log_config that would enable logging of the number bytes received per request. That kind of information would then be very useful for determining input traffic per virtual host, URL or whatever else, using regular web analysis tools, e.g. webalizer.

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-03 Thread Colm MacCarthaigh
On Mon, Oct 03, 2005 at 11:40:27AM -0400, Brian Akins wrote: > >CustomLog mysql://something common env=images > >CustomLog file:///logs/my.log combined > >CustomLog spread://somegroup refere > >CustomLog buffer:///logs/other.log common > > This patch implements the

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-03 Thread Brian Akins
Colm MacCarthaigh wrote: Looks useful, but file://|/bin/foo would be very non-intuitive for piped loggers, balancing the backwards compatibility might need a bit more, I guess "pipe://" or "cmd://" schemes might make sense also. True. I just used uri's as they seemed to just "fit." I'm not

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-03 Thread Jim Jagielski
Brian Akins wrote: > > Colm MacCarthaigh wrote: > > > Looks useful, but file://|/bin/foo would be very non-intuitive for piped > > loggers, balancing the backwards compatibility might need a bit more, I > > guess "pipe://" or "cmd://" schemes might make sense also. > > > True. I just used uri

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-03 Thread Brian Akins
Jim Jagielski wrote: 'pipe' is clearer I think... sure. Of course I just discovered that pip logs don't work. I think it's the spaces in the command, ie "|bin/rotatelogs /var/logs/logfile 5M". Hmmm.. looking into it... -- Brian Akins Lead Systems Engineer CNN Internet Technologies

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-03 Thread Rüdiger Plüm
On 10/03/2005 08:49 PM, Colm MacCarthaigh wrote: > On Mon, Oct 03, 2005 at 11:40:27AM -0400, Brian Akins wrote: > [..cut..] > > Looks useful, but file://|/bin/foo would be very non-intuitive for piped I guess you still can use |/bin/foo because file is the default provider. > loggers, balanc

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-03 Thread Brian Akins
Rüdiger Plüm wrote: Makes also sense to me since it seems to me that piped logging does not really play well with other things like spread or mysql. On the other side, what about the buffered logging? Would it make sense to make it possible to turn this on and off with each provider? If yes, we

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-03 Thread Brian Akins
@ -30,7 +30,7 @@ * callback function prototype for external writer initialization. */ typedef void *ap_log_writer_init(apr_pool_t *p, server_rec *s, - const char *name); + const apr_uri_t *uri); /** * callback which gets called

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-03 Thread Ondrej Sury
; > This patch implements the above. Within mod_log_config two providers > are provided: file and buffer. If no "scheme" is given, file is assumed. > > I have tested and preliminarily it works for both file and buffer. I > had to rearrange some of the buffer code to get

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-03 Thread Brian Akins
Ondrej Sury wrote: Just quick thought, maybe we should add: ap_log_writer_close *close; to struct log_provider_t. It's not absolutely necessary, because you can use apr_pool_cleanup_register(...), but it will make writing addon modules much cleaner. That's debatable. I already use apr_pool

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-03 Thread Rüdiger Plüm
On 10/03/2005 09:11 PM, Brian Akins wrote: > Rüdiger Plüm wrote: > >> Makes also sense to me since it seems to me that piped logging does >> not really play >> well with other things like spread or mysql. On the other side, what >> about the >> buffered logging? Would it make sense to make it po

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-03 Thread Brian Akins
sense that mod_log_config does it. mod_log_config just keeps appending data to a buffer. in an sql logger, to "buffer" you would keep a list/array/ring of log lines and wrap them in a transaction. This cannot be "buffered" in mod_log_config Hm, the question i

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-03 Thread Joshua Kogut
On 10/3/05, Brian Akins <[EMAIL PROTECTED]> wrote: Rüdiger Plüm wrote:>> Or it likes to read many lines in one block as it can commit such things> as a batch rather than as single commits per line. Of course it is not required> to use DB transactions on mysql. But for Oracle this might improve perf

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-03 Thread Rüdiger Plüm
On 10/03/2005 09:53 PM, Brian Akins wrote: > Rüdiger Plüm wrote: > [..cut..] > > but that would not be buffering in the sense that mod_log_config does > it. mod_log_config just keeps appending data to a buffer. in an sql > logger, to "buffer" you would keep a

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-03 Thread Ondrej Sury
On Mon, 2005-10-03 at 15:40 -0400, Brian Akins wrote: > Ondrej Sury wrote: > > > Just quick thought, maybe we should add: > > > > ap_log_writer_close *close; > > > > to struct log_provider_t. It's not absolutely necessary, because you > > can use apr_pool_cleanup_register(...), but it will make

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-03 Thread Colm MacCarthaigh
On Mon, Oct 03, 2005 at 11:40:27AM -0400, Brian Akins wrote: > Akins, Brian wrote: > > >CustomLog mysql://something common env=images > >CustomLog file:///logs/my.log combined > >CustomLog spread://somegroup refere > >CustomLog buffer:///logs/other.log common I've been looking more at this, and I

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-04 Thread Brian Akins
Colm MacCarthaigh wrote: But in order to save overhead, this would require some intelligence, it would not make much sense for the pluggable logger to re-parse this string everytime, to figure out what it should be doing. And where does it get its database, username and host information from? D

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-04 Thread Jeffrey Burgoyne
I run a system with about 250 virtual hosts averaging around 100 hits per second with little problem. Rather than having a piped log for each virtual host though, we only use one piped log for every virtual host, and add in the host name into the log. Your logging program then has ot have the smart

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-04 Thread Brian Akins
Jeffrey Burgoyne wrote: I run a system with about 250 virtual hosts averaging around 100 hits per second with little problem. 100 hits per second is not that much relative to what we do. We may be more of an extreme case, though. Rather than having a piped log for each virtual host thoug

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-04 Thread Colm MacCarthaigh
es to provide the database, hostname, username and so on information. If such directives are required anyway, what effort are we saving? Why not just replace mod_log_config rather than plug into it. > >And after all of this, what if any, are the compelling reasons to > >implement this in

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-04 Thread Ondrej Sury
On Mon, 2005-10-03 at 23:28 +0100, Colm MacCarthaigh wrote: > And after all of this, what if any, are the compelling reasons to > implement this in httpd at all? Why can't all of this be moved into > piped loggers? Why can't they just parse the logs as they get them and > do whatever whoever wants

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-04 Thread Colm MacCarthaigh
On Tue, Oct 04, 2005 at 02:59:40PM +0200, Ondrej Sury wrote: > No, it cannot be implemented with two netcat commands (just tried it). Sure, it can, use my Multicast Netcat; http://people.heanet.ie/~colmmacc/mnc/ (version 1.3 is experimental and not working right now, avoid that, and I'm

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-04 Thread Ondrej Sury
CustomLog mysql://mysql0/bar foo Then ap_mysql_log_writer would do it's own processing of strs/strl combo. > And we still need additional per-provider directives to provide the > database, hostname, username and so on information. That's true. > If such directives are required an

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-04 Thread Ondrej Sury
On Tue, 2005-10-04 at 14:06 +0100, Colm MacCarthaigh wrote: > On Tue, Oct 04, 2005 at 02:59:40PM +0200, Ondrej Sury wrote: > > No, it cannot be implemented with two netcat commands (just tried it). > > Sure, it can, use my Multicast Netcat; Didn't know that anything like that exists. My comment

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-04 Thread Brian Akins
If such directives are required anyway, what effort are we saving? Why not just replace mod_log_config rather than plug into it. Because mod_log_config handles a bunch of stuff for us. May be a better solution would be to use the standard log_config way of replacing init and writ

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-04 Thread Colm MacCarthaigh
On Tue, Oct 04, 2005 at 09:15:32AM -0400, Brian Akins wrote: > Why not just replace mod_log_config rather than plug into it. > > Because mod_log_config handles a bunch of stuff for us. May be a > better solution would be to use the standard log_config way of > replacing init

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-04 Thread Garrett Rooney
On 10/4/05, Colm MacCarthaigh <[EMAIL PROTECTED]> wrote: > On Tue, Oct 04, 2005 at 02:59:40PM +0200, Ondrej Sury wrote: > > No, it cannot be implemented with two netcat commands (just tried it). > > Sure, it can, use my Multicast Netcat; > > http://people.heanet.ie/~colmmacc/mnc/ > > (versi

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-06 Thread Brian Akins
My problem with piped loggers is there is no fast way to make sure you have a "complete" line. This is especially hard when you buffer the logs. Think of a situation where the piped logger is supposed to write to a socket, for example. If the piped logger has the ability to "fail over" to a

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-06 Thread Colm MacCarthaigh
On Thu, Oct 06, 2005 at 02:06:24PM -0400, Brian Akins wrote: > My problem with piped loggers is there is no fast way to make sure you > have a "complete" line. This is especially hard when you buffer the logs. If httpd writes a complete line, to any kind of a file descriptor, anything beyond tha

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-06 Thread Brian Akins
message could be many log lines) That way it's easy to ensure you get complete log entries and detect when you don't. I could write a piped logger that did this, but I'd have to detect when the lines begin and end and mod_log_config already knows that. Yes, for 90+% of the time,

Re: [PATCH] Re: Pluggable mod_log_config

2005-10-07 Thread Brian Candler
On Thu, Oct 06, 2005 at 03:49:10PM -0400, Brian Akins wrote: > Colm MacCarthaigh wrote: > > >If httpd writes a complete line, to any kind of a file descriptor, > >anything beyond that is out of our control and becomes a question of the > >quality of the piped logger, filesystem or whatever else is

[PATCH] performance patch for mod_log_config

2001-09-09 Thread Brian Pane
The call to apr_explode_localtime() in mod_log_config is one of the more expensive operations in the httpd. This patch attempts to reduce the overhead by caching the result. --Brian Index: modules/loggers/mod_log_config.c === RCS

Re: [PROPOSAL]: Bytes received v. mod_log_config

2002-08-18 Thread Chris Taylor
Taylor - [EMAIL PROTECTED] - The guy with the PS2 WebServer - http://www.x-bb.org/chris.asc - - Original Message - From: "Bojan Smojver" <[EMAIL PROTECTED]> To: "Apache Dev List" <[EMAIL PROTECTED]> Sent: Sunday, August 18, 2002 11:25 PM Subject: [PROPOSAL]

Re: [PROPOSAL]: Bytes received v. mod_log_config

2002-08-18 Thread Bojan Smojver
Quoting Chris Taylor <[EMAIL PROTECTED]>: > Yes, definately. > > FWIW, I find it quite annoying that Webalizer's "amount served" is > often blindingly inaccurate based on Apache's logs. I think this is due to the fact that headers are not taken into account or something like that. And there is

Re: [PROPOSAL]: Bytes received v. mod_log_config

2002-08-18 Thread Justin Erenkrantz
On Mon, Aug 19, 2002 at 08:25:53AM +1000, Bojan Smojver wrote: > I'm playing around with a patch for mod_log_config that would enable > logging of the number bytes received per request. That kind of > information would then be very useful for determining input traffic per > vir

Re: [PROPOSAL]: Bytes received v. mod_log_config

2002-08-18 Thread Bojan Smojver
Quoting Justin Erenkrantz <[EMAIL PROTECTED]>: > On Mon, Aug 19, 2002 at 08:25:53AM +1000, Bojan Smojver wrote: > > I'm playing around with a patch for mod_log_config that would enable > > logging of the number bytes received per request. That kind of > > infor

Re: [PROPOSAL]: Bytes received v. mod_log_config

2002-08-18 Thread Justin Erenkrantz
t who) fixed up the filters so that a connection-level filter always has a reference to the 'current' request. So, even in a connection-level filter, filter_rec->r should be valid. You'd have to determine some place to store how much we read, but that could be done in a mod_log_config private structure. Hope this makes some sense. -- justin

mod_log_config log writer interface, buffered logging

2004-12-02 Thread Andy Armstrong
In Apache 2 mod_log_config exposes an interface (via optional functions ap_log_set_writer_init and ap_log_set_writer) that allows the log writer to be replaced. I've used that interface to implement mod_log_rotate which does time based log rotation in a similar way to rotatelogs. Th

mod_log_config log writer interface, buffered logging

2004-12-02 Thread Andy Armstrong
In Apache 2 mod_log_config exposes an interface (via optional functions ap_log_set_writer_init and ap_log_set_writer) that allows the log writer to be replaced. I've used that interface to implement mod_log_rotate which does time based log rotation in a similar way to rotatelogs. Th

mod_log_config: log thread id in hex

2005-08-27 Thread Jeff Trawick
%{tid}P gets you thread id in decimal now. %{hextid}P would show it in hex using relatively new apr_sprintf() format, added in 1.2.0. Index: modules/loggers/mod_log_config.c === --- modules/loggers/mod_log_config.c(revision 240100)

Re: [PATCH] performance patch for mod_log_config

2001-09-09 Thread Ryan Bloom
On Sunday 09 September 2001 19:46, Brian Pane wrote: Can we get this as a unified diff? Ryan > The call to apr_explode_localtime() in mod_log_config is one of the more > expensive operations in the httpd. This patch attempts to reduce the > overhead by caching t

Re: [PATCH] performance patch for mod_log_config

2001-09-09 Thread Brian Pane
Ryan Bloom wrote: >On Sunday 09 September 2001 19:46, Brian Pane wrote: > >Can we get this as a unified diff? > sure, here's the unified form: Index: modules/loggers/mod_log_config.c === RCS file: /home/cvspublic/httpd-2.0/modules/l

Re: [PATCH] performance patch for mod_log_config

2001-09-09 Thread Cliff Woolley
On Sun, 9 Sep 2001, Brian Pane wrote: > The call to apr_explode_localtime() in mod_log_config is one of the more > expensive operations in the httpd. This patch attempts to reduce the > overhead by caching the result. Looks quite reasonable... I wouldn't mind seeing this as a

Re: [PATCH] performance patch for mod_log_config

2001-09-09 Thread William A. Rowe, Jr.
l, for fun. Bill - Original Message - From: "Brian Pane" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Sunday, September 09, 2001 9:46 PM Subject: [PATCH] performance patch for mod_log_config > The call to apr_explode_localtime() in mod_log_config is one of

Re: [PATCH] performance patch for mod_log_config

2001-09-09 Thread Cliff Woolley
On Sun, 9 Sep 2001, William A. Rowe, Jr. wrote: > Is this the right place to be caching, or should this become a > straightforward optimization to apr's time.c functions? I'd think the > advantages are many for keeping 15 current seconds in apr, and would > pay off across the board. Within apr,

Re: [PATCH] performance patch for mod_log_config

2001-09-09 Thread Brian Pane
terface looks useful, I'll resubmit the patch in a form that adds these functions to APR and calls them from mod_log_config. --Brian

Re: [PATCH] performance patch for mod_log_config

2001-09-09 Thread Cliff Woolley
On Sun, 9 Sep 2001, Brian Pane wrote: > I think putting it in APR would work. The one limitation I can think of > is that adding the cache in apr_explode_localtime() itself wouldn't be a > win because we'd have to add the overhead of a gettimeofday() call to > check whether the supplied time was

Re: [PATCH] performance patch for mod_log_config

2001-09-10 Thread Alex Stewart
Brian Pane wrote: > William A. Rowe, Jr. wrote: > >> Is this the right place to be caching, or should this become a >> straightforward >> optimization to apr's time.c functions? I'd think the advantages are >> many for >> keeping 15 current seconds in apr, and would pay off across the >> boar

[PATCH 3] performance patch for mod_log_config

2001-09-10 Thread Brian Pane
Here's an updated version of the patch that fixes the race condition that Dean pointed out involving requests that last almost exactly 15 seconds. The comments in the code describe the "snapshot" technique that it uses to detect and correct the race condition. --Brian Index: modules/loggers/mod

[PATCH: Apache 2.0] mod_log_config: input/output bytes

2002-08-19 Thread Bojan Smojver
The same patch reworked for Apache 2.0. Justin, I had a look through filter examples but didn't feel confident to undertake writing one. Maybe in the next version of the patch... Bojan --- mod_log_config.c.original Tue Aug 20 15:12:32 2002 +++ mod_log_config.cTue Aug 20 15:39:09 2002 @@

[PATCH: Apache 1.3] mod_log_config: input/output bytes

2002-08-19 Thread Bojan Smojver
I have noticed a bug in my second version of the patch which would report incorrect number of bytes sent if the request is HEAD. It is fixed in this version. I have attached the documentation patch again, just to avoid confusion. Bojan PS. At this rate, my e-mail address will end up on Apache sp

[PATCH] mod_log_config: Allow logging using errorlog provider

2015-04-07 Thread Jan Kaluža
Hi, we have ap_errorlog_provider in the trunk for some time. I was thinking about extending it to mod_log_config, so CustomLog/TransferLog would work with any module providing error_log logging ability like mod_syslog or mod_journald. Attached patch does that by introducing CustomLog

[PATCH] A modular mod_log_config for Apache 2

2003-09-12 Thread Sönke Tesch
Hi, I wasn't too happy with the current mod_log_config design, which turned out to be a bit unflexible in the writer section, so I modified it in order to be able to happily log into a database. The disadvantages of the existing set_writer way of doing things are: a) The log writer doesn&

[PATCH] A modular mod_log_config for Apache 2

2003-09-12 Thread Sönke Tesch
Hi, I wasn't too happy with the current mod_log_config design, which turned out to be a bit unflexible in the writer section, so I modified it in order to be able to happily log into a database. The disadvantages of the existing set_writer way of doing things are: a) The log writer doesn&

mod_log_config %{Foobar}o doesn't work under 2.2

2006-06-05 Thread Laurent Perez
Hi The Format String "%{Foobar}o" (The contents of Foobar: header line(s) in the reply.) shown at http://httpd.apache.org/docs/2.2/mod/mod_log_config.html does not work for every reply header sent by the server. Instead, it give "-". For example, Content-type works, but Date or Server do not. Is

Re: mod_log_config: log thread id in hex

2005-08-30 Thread Joe Orton
On Sat, Aug 27, 2005 at 11:12:24AM -0400, Jeff Trawick wrote: > %{tid}P gets you thread id in decimal now. > %{hextid}P would show it in hex using relatively new apr_sprintf() > format, added in 1.2.0. Seems fine except that it introduces a softish dependency on apr >= 1.2.0 which is not enforced

Re: mod_log_config: log thread id in hex

2005-08-30 Thread Justin Erenkrantz
On Tue, Aug 30, 2005 at 11:28:37AM +0100, Joe Orton wrote: > On Sat, Aug 27, 2005 at 11:12:24AM -0400, Jeff Trawick wrote: > > %{tid}P gets you thread id in decimal now. > > %{hextid}P would show it in hex using relatively new apr_sprintf() > > format, added in 1.2.0. > > Seems fine except that it

[PATCH 3/3] mod_log_config: Add JSON logger

2023-03-24 Thread Thomas Meyer
--- modules/loggers/mod_log_config.c | 159 +-- 1 file changed, 153 insertions(+), 6 deletions(-) diff --git a/modules/loggers/mod_log_config.c b/modules/loggers/mod_log_config.c index d142c888ad..188131ebac 100644 --- a/modules/loggers/mod_log_config.c +++ b/modules/l

[PATCH]: Input/Output bytes for mod_log_config, Apache 1.3

2002-08-19 Thread Bojan Smojver
Here is the patch that calculates (in the same way mod_accounting, by Simone Tellini, does) the number of bytes received and bytes sent per request. The numbers are then logged using %I (input) and %O (output). Since the numbers are always greater then 0, there are no CLF versions of those functio

Re: [PATCH: Apache 2.0] mod_log_config: input/output bytes

2002-08-19 Thread Justin Erenkrantz
f(r->pool, "%ld", recv); > +} The problem here is that the length may not be specified via C-L, but rather Transfer-Encoding: chunked. This system falls down in that case. This is why I'd strongly recommend looking at trying to add r->bytes_read (or perhaps to a mod_log_c

Re: [PATCH: Apache 2.0] mod_log_config: input/output bytes

2002-08-20 Thread Bojan Smojver
ol, "%ld", recv); > > +} > > The problem here is that the length may not be specified via C-L, > but rather Transfer-Encoding: chunked. This system falls down > in that case. This is why I'd strongly recommend looking at > trying to add r->bytes_read (or perh

Re: [PATCH: Apache 2.0] mod_log_config: input/output bytes

2002-08-20 Thread Bojan Smojver
ead (or perhaps to a mod_log_config specific > structure) to core_input_filter. After reading a bit more from the function core_input_filter, here is what I can conclude: - to get to request from the filter, one would use f->r in that function - since there is no r->bytes_read in

Re: [PATCH: Apache 2.0] mod_log_config: input/output bytes

2002-08-20 Thread Justin Erenkrantz
On Tue, Aug 20, 2002 at 09:54:43PM +1000, Bojan Smojver wrote: > After reading a bit more from the function core_input_filter, here is > what I can conclude: > > - to get to request from the filter, one would use f->r in that function > - since there is no r->bytes_read in current request_rec we

Re: [PATCH: Apache 2.0] mod_log_config: input/output bytes

2002-08-20 Thread Bojan Smojver
instance bytes_pushed and bytes_pulled, which would record the above (i.e. the number of bytes actually read/written for the request, as per core_input_filter and core_output_filter). Those can then be used for logging purposes and statistics, together with the old bytes_sent. bytes_sent would then get the lo

Re: [PATCH: Apache 2.0] mod_log_config: input/output bytes

2002-08-20 Thread Bojan Smojver
Quoting Justin Erenkrantz <[EMAIL PROTECTED]>: > > So, r->bytes_sent would then be completely different that in the > current > > version of Apache 1.3/2.0, which simply reflects the length of the > body? > > Would others be inclined to accept such a change? > > Totally. The current behavior is

Re: [PATCH] mod_log_config: Allow logging using errorlog provider

2015-04-17 Thread Jan Kaluža
On 04/07/2015 11:47 AM, Jan Kaluža wrote: Hi, we have ap_errorlog_provider in the trunk for some time. I was thinking about extending it to mod_log_config, so CustomLog/TransferLog would work with any module providing error_log logging ability like mod_syslog or mod_journald. Attached patch

Bug 28832 - %b in mod_log_config - Documentation assistance requested

2004-12-26 Thread Rich Bowen
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 I'd like to close bug 28832 but it's a little unsatisfying to document a feature as broken and leave it at that. http://issues.apache.org/bugzilla/show_bug.cgi?id=28832 Summary. In mod_log_config, %b returns an incorrect value in some cases.

Re: [PATCH] A modular mod_log_config for Apache 2

2003-09-13 Thread André Malo
* Sönke Tesch wrote: > That said, I'm a bit unsure if the implementation is correct and bug-free, > although it seems to work on my own server - after all, I'm new to this. > I'd be happy about any helpful comments on design issues and other thoughts > and suggestions. Thanks! Sounds like an inte

Re: mod_log_config %{Foobar}o doesn't work under 2.2

2006-06-05 Thread William A. Rowe, Jr.
Laurent Perez wrote: For example, Content-type works, but Date or Server do not. Is "%{Server}o" the right syntax to log the "Server:" header, or is it broken ? An ethereal trace shows a value for the Server: header. Server and Date are added later and cannot be overridden, but it probably mak

[PATCH 2] Re: [PATCH] performance patch for mod_log_config

2001-09-09 Thread Brian Pane
Cliff Woolley wrote: >On Sun, 9 Sep 2001, Brian Pane wrote: > >>I think putting it in APR would work. The one limitation I can think of >>is that adding the cache in apr_explode_localtime() itself wouldn't be a >>win because we'd have to add the overhead of a gettimeofday() call to >>check wheth

Re: [PATCH]: Input/Output bytes for mod_log_config, Apache 1.3

2002-08-19 Thread Bojan Smojver
Just noticed that there is a little bit of silliness (as usual) in the original patch. Nothing serious, but this one should make a bit more sense... Bojan --- mod_log_config.c.original Tue Aug 20 12:51:20 2002 +++ mod_log_config.cTue Aug 20 13:33:50 2002 @@ -151,6 +151,8 @@ * %...m: th

[PATCH] mod_log_config %b should always log '-' rather than '0'

2004-06-30 Thread Bill Stoddard
The %b option is used to log the 'bytes_sent' in a reply. Unlike %B, %b should log a '-' rather than '0' if no body is sent on a reply. I recently ran across two cases where %b incorrectly logs '0': First case is when ap_set_byterange sets HTTP_RANGE_NOT_SATISFIABLE to the default_handler. Sec

Re: Bug 28832 - %b in mod_log_config - Documentation assistance requested

2004-12-26 Thread auto-reply from [EMAIL PROTECTED]
--- Se l'email che mi hai mandato è spam, interrompi subito il tuo atto criminoso. If the email that you have sent me is spam, you immediately interrupt your criminal action.

[PATCH] mod_log_config : 2.2 extended port logging backport from trunk

2008-04-16 Thread Vincent Deffontaines
Greetings, Trunk can log connection source port by using in Logformat : "%{remote}p". 2.2 currently does not support that (only logs the destination port of the connection). Included is a very simple (trivial) backport of that functionnality from trunk to 2.2. Tested, works for me. Vincent

Re: [PATCH 2] Re: [PATCH] performance patch for mod_log_config

2001-09-10 Thread dean gaudet
why is there a need for 15 entries? if it's a multiprocess server then there's only a need for 1 or 2 entries. if it's a multithreaded server then you need to lock the cache (which you're not doing :) isn't the real win in eliminating both the divisions required by the explode time functions an

  1   2   >