-
Notifications
You must be signed in to change notification settings - Fork 4.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add details and example of sublinear route matching using Generic Matching API #37158
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
adding pics Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
update diagrams and code links Signed-off-by: Kirtimaan <[email protected]>
fix the link to trie lookup table template class Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
update content Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
currently this is failing a lot of CI - most importantly the docs build
if you can fix that i can do a more thorough review
ping me offline if you want help figuring out what needs to be changed
re the configs - one of the reasons we use a complete bootstrap config and literalinclude
is that the configs are then validated (in a couple of ways)
prefix: "" | ||
route: | ||
cluster: cluster_3 | ||
clusters: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
these clusters will need to be specified - the config is not valid otherwise
Sublinear Route Matching | ||
~~~~~~~~~~~~~~~~~~~~~~~~ | ||
|
||
An incoming request to Envoy needs to be matched to a cluster based on defined `routes <https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/route/v3/route_components.proto#envoy-v3-api-msg-config-route-v3-virtualhost>`_. Typically, a well understood, linear route search matching with O(n) search cost (see `Virtual Host <https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/route/v3/route_components.proto#envoy-v3-api-msg-config-route-v3-virtualhost>`_ → `Routes <https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/route/v3/route_components.proto#envoy-v3-api-msg-config-route-v3-route>`_) is employed which can become a scalability issue with higher latencies as the number of routes go up to o(1k+). To overcome these scalability challenges the Generic Matcher API ( `Virtual Host → matcher{} <https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/route/v3/route_components.proto#envoy-v3-api-msg-config-route-v3-virtualhost>`_) → `matcher_tree <https://www.envoyproxy.io/docs/envoy/latest/xds/type/matcher/v3/matcher.proto#envoy-v3-api-msg-xds-type-matcher-v3-matcher-matchertree>`_ can offer a robust and flexible framework for route matching with two distinct sublinear matching implementations: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
An incoming request to Envoy needs to be matched to a cluster based on defined `routes <https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/route/v3/route_components.proto#envoy-v3-api-msg-config-route-v3-virtualhost>`_. Typically, a well understood, linear route search matching with O(n) search cost (see `Virtual Host <https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/route/v3/route_components.proto#envoy-v3-api-msg-config-route-v3-virtualhost>`_ → `Routes <https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/route/v3/route_components.proto#envoy-v3-api-msg-config-route-v3-route>`_) is employed which can become a scalability issue with higher latencies as the number of routes go up to o(1k+). To overcome these scalability challenges the Generic Matcher API ( `Virtual Host → matcher{} <https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/route/v3/route_components.proto#envoy-v3-api-msg-config-route-v3-virtualhost>`_) → `matcher_tree <https://www.envoyproxy.io/docs/envoy/latest/xds/type/matcher/v3/matcher.proto#envoy-v3-api-msg-xds-type-matcher-v3-matcher-matchertree>`_ can offer a robust and flexible framework for route matching with two distinct sublinear matching implementations: | |
An incoming request to Envoy needs to be matched to a cluster based on defined :ref:`routes <envoy_v3_api_msg_config.route.v3.VirtualHost>`_. Typically, a well understood, linear route search matching with O(n) search cost (see :ref:`Virtual Host <envoy_v3_api_msg_config.route.v3.VirtualHost>`_ → :ref:`Routes <envoy_v3_api_msg_config.route.v3.Route>`_) is employed which can become a scalability issue with higher latencies as the number of routes go up to o(1k+). To overcome these scalability challenges the Generic Matcher API ( `Virtual Host → matcher{} <https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/route/v3/route_components.proto#envoy-v3-api-msg-config-route-v3-virtualhost>`_) → `matcher_tree <https://www.envoyproxy.io/docs/envoy/latest/xds/type/matcher/v3/matcher.proto#envoy-v3-api-msg-xds-type-matcher-v3-matcher-matchertree>`_ can offer a robust and flexible framework for route matching with two distinct sublinear matching implementations: |
internal links need to use :ref:
- ive updated a couple, but im not 100% that ive pointed the links to the correct place
you can find the ref target by clicking "View page source" on the rendered docs pages
not sure exactly the issue that is preventing the docs from building - but its related to these links
Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
Signed-off-by: Kirtimaan <[email protected]>
Commit Message:
Additional Description: Add details on sublinear route matching with examples using Generic Matching API
Risk Level: Low
Testing:
Docs Changes: Add more details for routing using Generic Matching API
Release Notes:
Platform Specific Features:
[Optional Runtime guard:]
[Optional Fixes #Issue]
[Optional Fixes commit #PR or SHA]
[Optional Deprecated:]
[Optional API Considerations:]