On Fri, Feb 27, 2015 at 8:23 PM, Daniel Dubovik <[email protected]> wrote:
> Hello all!
>
> I am wanting to use HAProxy to detect if I receive a certain status code
> from a backend web server (say, a 503 error or some such) while processing a
> request.  If I do receive it, track the request, so subsequent requests to
> the domain will behave differently (specifically, go to a different backend
> that has a different load balancing method, or different servers that can
> handle their load.
>
> Is there a way I can do this in HAProxy?  Stick-tables don't let me track
> requests based on the response, only on the request information, so that
> doesn't seem like it would work, but seems like the only place that it would
> fit?
>
> Thanks!
> Dan
>


Hi Daniel,

Something not clear in your request is that do you want to route ALL
traffic after an error, or only the traffic from a single user?

You may use the 'stick store-response' when an error is returned by
the server and track it when traffic comes in with the in_table fetch.
This may require you to switch to HAProxy 1.6-dev.

Baptiste

Reply via email to