-
Notifications
You must be signed in to change notification settings - Fork 2k
Description
Is your feature request related to a problem? Please describe.
Hi! my team is looking to enable traffic splitting for our NGINX gateway using Virtualserver/VSR. One thing that we are currently interested in is configuring a custom key for the split_client hash to enable weighted routing based on our a custom string/key.
One such as a case is when we have a inc header "http_call_id", for which we would like to route calls to the same upstream, but still split our calls (uniquely identified by call_id) between several upstreams for A/B testing, Blue/green, and Canary testing.
Describe the solution you'd like
One solution could be to allow this field to be configured under each route - for example something like below:
path: /tea
splitsKey: "$http_call_id"
splits:
- weight: 80
action:
pass: coffee-v1
- weight: 20
action:
pass: coffee-v2
Describe alternatives you've considered
Alternatives such as http-snippets works - but its impractical when you want to avoid enabling snippets in general since we have a lot of partner teams using our gateway, and snippets tend to break the overall IC configuration generation.
Additional context
I would be happy to make a contribution myself, but I don't want to waste time implementing something if you guys think its a waste.