membrane / api-gateway

API gateway for REST, OpenAPI, GraphQL and SOAP written in Java.
https://membrane-api.io
Apache License 2.0
447 stars 138 forks source link

Canary Routing #1141

Open predic8 opened 1 week ago

predic8 commented 1 week ago

Idea:

# Gets 10% of traffik to /foo
<api port="2000">
     <match>
         <canary rate="0.1">
     </match>
      <path>/foo></path>
     ...
</api>
# Gets 90% of traffik to /foo
<api port="2000">
      <path>/foo></path>
     ...
</api>
t-burch commented 1 week ago

The term canary routing is made up by us I am guessing, it might not be the best term because canary deployments generally are for catching errors early. This might apply to the route as well, but common terminology by amazon and others is just weighted routing. So maybe we can add a "weight" attribute to the proxies or a weight option to the matcher