Hi again Tim,

On Mon, May 28, 2018 at 10:57:59AM +0200, Willy Tarreau wrote:
> > I added a counter and verified that it works using the stats socket. I 
> > copied
> > it from elsewhere in proto_http. Please check whether I did correctly (not
> > overcounting and such things). Also check whether all of the
> > stats_fill_*_stats functions should actually be modified.
> 
> Thanks for the info, I'll take a look.

OK this was fine. I noticed that you also emitted the value for the servers
but that this one was not filled in the code, and that there was almost
nothing to do to get it, for the response case, which is useful because if
you see that one server has many more errors than the other ones, you know
it emits some different contents (eg: looping cookies).  I just had to add
the following lines for this :

          if (objt_server(s->target))
                   
HA_ATOMIC_ADD(&objt_server(s->target)->counters.failed_rewrites, 1);

Also I found that the #%u with the request ID was missing for the request
log, it was only for the response, so I fixed it. It works well and seems
pretty useful. I'll check how to fit it into the stats page. It'll probably
be OK in the tooltip which already contains the distribution by status code.

Thus I've just merged it now. Thanks!
willy

Reply via email to