Re: [PATCH] Add a new log format variable %p that spits out the sanitized request path

2015-04-28 Thread Andrew Hayworth
Hello - On Tue, Apr 28, 2015 at 3:01 AM, Willy Tarreau w...@1wt.eu wrote: Hi again Andrew, I've spent some time on it. Good work. I'm seeing a bug in %HV, it doesn't always work. I like your idea to convert missing versions to HTTP/1.0, but I think that in order to be even more accurate, we

Re: [PATCH] Add a new log format variable %p that spits out the sanitized request path

2015-04-28 Thread Willy Tarreau
Hi again Andrew, I've spent some time on it. Good work. I'm seeing a bug in %HV, it doesn't always work. I like your idea to convert missing versions to HTTP/1.0, but I think that in order to be even more accurate, we should report HTTP/0.9 to translate what was actually seen in the logs, what do

Re: [PATCH] Add a new log format variable %p that spits out the sanitized request path

2015-04-28 Thread Willy Tarreau
Hi Andrew, On Tue, Apr 28, 2015 at 10:54:58AM -0500, Andrew Hayworth wrote: (...) I changed %HR - %HU, and mentioned '(path)' in the docs. I found it was not changed in the parser nor the doc but I fixed it, don't worry. Now concerning the bug, it's not very important but it does exist :

Re: [PATCH] Add a new log format variable %p that spits out the sanitized request path

2015-04-28 Thread Andrew Hayworth
Thanks! On Tue, Apr 28, 2015 at 2:07 PM, Willy Tarreau w...@1wt.eu wrote: Hi Andrew, On Tue, Apr 28, 2015 at 10:54:58AM -0500, Andrew Hayworth wrote: (...) I changed %HR - %HU, and mentioned '(path)' in the docs. I found it was not changed in the parser nor the doc but I fixed it, don't

Re: [PATCH] Add a new log format variable %p that spits out the sanitized request path

2015-04-27 Thread Andrew Hayworth
Hi Willy - Sorry about the delay. I had to work on some other projects, and just got back to this. As usual, thank you for the feedback on the commit. On Wed, Apr 15, 2015 at 4:12 AM, Willy Tarreau w...@1wt.eu wrote: - it did not apply to mainline, I had to apply it by hand, so I suspect

Re: [PATCH] Add a new log format variable %p that spits out the sanitized request path

2015-04-27 Thread Willy Tarreau
Hi Andrew, On Mon, Apr 27, 2015 at 04:49:36PM -0500, Andrew Hayworth wrote: Hi Willy - Sorry about the delay. I had to work on some other projects, and just got back to this. Oh don't worry, I know this situation too well! (...) On Wed, Apr 15, 2015 at 4:12 AM, Willy Tarreau w...@1wt.eu

Re: [PATCH] Add a new log format variable %p that spits out the sanitized request path

2015-04-15 Thread Willy Tarreau
Hi Andrew, On Tue, Apr 14, 2015 at 02:33:25PM -0500, Andrew Hayworth wrote: I've attached another patch that implements 4 separate log variables to log individual parts of the request line, as you suggested. Great, thanks. I'm having a few comments about the patch : - it did not apply to

Re: [PATCH] Add a new log format variable %p that spits out the sanitized request path

2015-04-11 Thread Willy Tarreau
Hi Andrew, On Thu, Apr 09, 2015 at 08:55:20AM -0500, Andrew Hayworth wrote: Hi Willy - Apologies if this comes through multiple times; I'm having some mail difficulties. I received it only once FYI. When I attempt to use %[path] in a log-format directive, I get the following errors:

Re: [PATCH] Add a new log format variable %p that spits out the sanitized request path

2015-04-09 Thread Andrew Hayworth
Hi Willy - Apologies if this comes through multiple times; I'm having some mail difficulties. On Tue, Apr 7, 2015 at 7:11 PM, Willy Tarreau w...@1wt.eu wrote: Just a question, did you find any benefit in doing it with a new tag compared to %[path] ? It may just be a matter of convenience, I'm

[PATCH] Add a new log format variable %p that spits out the sanitized request path

2015-04-07 Thread Andrew Hayworth
It's often undesirable to log query params - and in some cases, it can create legal compliance problems. This commit adds a new log format variable that logs the HTTP verb and the path requested sans query string (and additionally ommitting the protocol). For example, the following HTTP request

Re: [PATCH] Add a new log format variable %p that spits out the sanitized request path

2015-04-07 Thread Willy Tarreau
Hi Andrew, On Tue, Apr 07, 2015 at 04:52:38PM -0500, Andrew Hayworth wrote: It's often undesirable to log query params - and in some cases, it can create legal compliance problems. This commit adds a new log format variable that logs the HTTP verb and the path requested sans query string (and