trafficserver-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Miles Libbey <>
Subject Re: Mapping rule based on cookie
Date Wed, 13 Jul 2016 16:00:51 GMT
Think one way to do this would be:
- use the header_rewrite plugin to check the cookie value and set the
destination/origin Host. Not sure about the whole IP thing... perhaps
make up a domain and set /etc/hosts to 100.100...? Or just set the
Host to 100.100..?
- use the cachekey plugin to put the cookie value in the cachekey.

something like:
map \ @pparam=--include-cookies=cookienamehere @pparam=header_rewrite.config

with header_rewrite.config containing:
cond %{COOKIE:cookienamehere} ="key=2"
   set-destination HOST

On Wed, Jul 13, 2016 at 3:16 AM, Reindl Harald <> wrote:
> Am 13.07.2016 um 11:37 schrieb Alex Sviridov:
>> I need a reverse proxy which makes server mapping according to some
>> value in cookie.
>> For example, if there is a variable "key" and it is equal to 2 (key=2)
>> then request must be redirected
>> to server
>> Can apache traffic server do that?
> not that i know but i am pretty sure you should start to describe your
> probklem and waht you try to achieve instead ask for a specific solution
> in case of load-balancing the servers should use a shared session storage so
> that it don't matter on which backend machine a request ends

View raw message