Skip to content

API: new composite API for inline matcher#43227

Merged
wbpcode merged 2 commits intoenvoyproxy:mainfrom
wbpcode:dev-composite-api
Feb 11, 2026
Merged

API: new composite API for inline matcher#43227
wbpcode merged 2 commits intoenvoyproxy:mainfrom
wbpcode:dev-composite-api

Conversation

@wbpcode
Copy link
Copy Markdown
Member

@wbpcode wbpcode commented Jan 30, 2026

Commit Message: composite: new API for inline matcher
Additional Description:

Add matcher API to the composite filter directly to avoid dependency to ExtensionWithMatcher. This would make the the filter a little easier to use.

Risk Level:
Testing:
Docs Changes:
Release Notes:
Platform Specific Features:
[Optional Runtime guard:]
[Optional Fixes #Issue]
[Optional Fixes commit #PR or SHA]
[Optional Deprecated:]
[Optional API Considerations:]

Signed-off-by: wbpcode/wangbaiping <wbphub@gmail.com>
@repokitteh-read-only
Copy link
Copy Markdown

CC @envoyproxy/api-shepherds: Your approval is needed for changes made to (api/envoy/|docs/root/api-docs/).
envoyproxy/api-shepherds assignee is @markdroth
CC @envoyproxy/api-watchers: FYI only for changes made to (api/envoy/|docs/root/api-docs/).

🐱

Caused by: #43227 was opened by wbpcode.

see: more, trace.

@wbpcode
Copy link
Copy Markdown
Member Author

wbpcode commented Jan 30, 2026

Regardless of discussion at #42912, @markdroth I think this is something we could easily get agreement. Although I need some time to re-consider the implementation. We still need to keep backward compatibility to the previous version. We need some hack to validate the new style and old style will not be used at same time. 🤔 But we can land the API first.

BTW, although Envoy need to keep backward compatibility, but gRPC may could have a fresh start if the feature haven't been released in the gRPC?

@markdroth
Copy link
Copy Markdown
Contributor

/lgtm api

Regardless of discussion at #42912, @markdroth I think this is something we could easily get agreement.

Absolutely! This looks great!

Although I need some time to re-consider the implementation. We still need to keep backward compatibility to the previous version. We need some hack to validate the new style and old style will not be used at same time. 🤔

What I was thinking is this:

  • If using Composite message inside ExtensionWithMatcher (the old API), the new matcher field will be ignored (or we could even decide to reject the config if the field is set).
  • If using Composite message as the top-level filter config (the new API), the matcher field will be required.

Either API would result in the same filter being configured.

BTW, although Envoy need to keep backward compatibility, but gRPC may could have a fresh start if the feature haven't been released in the gRPC?

Sadly, it's probably too late for that. I've already started implementing the composite filter in gRPC C++, since we need it fairly quickly for an important feature, and we're going to need to deploy it in an environment where the control plane supports both gRPC and Envoy. I don't think there's enough time to get the new API implemented in Envoy and get all of our Envoy instances upgraded before we need to deploy this. :(

On the plus side, once we agree on this new API, it will be trivial for gRPC to add support for it.

@wbpcode
Copy link
Copy Markdown
Member Author

wbpcode commented Jan 31, 2026

What I was thinking is this:
If using Composite message inside ExtensionWithMatcher (the old API), the new matcher field will be ignored (or we could even decide to reject the config if the field is set).
If using Composite message as the top-level filter config (the new API), the matcher field will be required.

Yeah, exactly. This is what I am thinking. Although in the Envoy, there is no way for filter implementation to know whether it's configured in the ExtensionWithMatcher or top level filter chain. Still need some hack.

Anyway, I will try to resolve this problem and add implementation at next 2-3 weeks.

@wbpcode
Copy link
Copy Markdown
Member Author

wbpcode commented Feb 1, 2026

cc @agrawroh for an approval for this API only change. Then I can prepare the implementation. This is independent topic about how to improve composite self. (For now, TBH, it's over-complicated even as an expert-tool. Orz).

agrawroh
agrawroh previously approved these changes Feb 1, 2026
Copy link
Copy Markdown
Member

@agrawroh agrawroh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, Thanks!

Signed-off-by: code <wbphub@gmail.com>
@wbpcode
Copy link
Copy Markdown
Member Author

wbpcode commented Feb 11, 2026

because Mark have approved this API before, let's merge it directly.

@wbpcode wbpcode merged commit 19ad0bd into envoyproxy:main Feb 11, 2026
25 of 26 checks passed
@wbpcode wbpcode deleted the dev-composite-api branch February 11, 2026 06:31
shane-yuan pushed a commit to shane-yuan/envoy that referenced this pull request Feb 11, 2026
nickshokri pushed a commit to nickshokri/envoy that referenced this pull request Mar 17, 2026
Signed-off-by: nick <nickshokri@google.com>
nickshokri pushed a commit to nickshokri/envoy that referenced this pull request Mar 17, 2026
Signed-off-by: nick <nickshokri@google.com>
fishcakez pushed a commit to fishcakez/envoy that referenced this pull request Mar 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants