Skip to content

thrift: adding xDS RDS support for thrift proxy.#19982

Merged
htuch merged 49 commits intoenvoyproxy:mainfrom
tkovacs-2:add_thrift_rds
Mar 15, 2022
Merged

thrift: adding xDS RDS support for thrift proxy.#19982
htuch merged 49 commits intoenvoyproxy:mainfrom
tkovacs-2:add_thrift_rds

Conversation

@tkovacs-2
Copy link
Copy Markdown
Contributor

@tkovacs-2 tkovacs-2 commented Feb 16, 2022

Commit Message:
Adding xDS routing discovery support for thrift proxy.

Additional Description:

  • The routing discovery is supported only through ADS. No separate service endpoints added
    for thrift routing config type url.

This PR is split from #17631

Risk Level:
Low

Testing:

  • Unittest
  • Manual test with static routing from bootstrap config, static routing and dynamic routing from GRPC based xDS server.

Docs Changes:
Comment added to the new API field.

Release Notes:

Platform Specific Features:

Tamas Kovacs added 30 commits August 9, 2021 12:13
The implementation is mostly copy form source/common/router/ minus the unnecessary parts.
Unfortunatly no common base classes to share code.

Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Conflicts:
	source/common/config/type_to_endpoint.cc

Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Conflicts:
	api/envoy/extensions/filters/network/thrift_proxy/v4alpha/BUILD
	api/envoy/extensions/filters/network/thrift_proxy/v4alpha/route.proto
	api/envoy/extensions/filters/network/thrift_proxy/v4alpha/thrift_proxy.proto
	generated_api_shadow/envoy/annotations/resource.proto
	generated_api_shadow/envoy/extensions/filters/network/thrift_proxy/v3/route.proto
	generated_api_shadow/envoy/extensions/filters/network/thrift_proxy/v3/thrift_proxy.proto
	generated_api_shadow/envoy/extensions/filters/network/thrift_proxy/v4alpha/BUILD
	generated_api_shadow/envoy/extensions/filters/network/thrift_proxy/v4alpha/route.proto
	generated_api_shadow/envoy/extensions/filters/network/thrift_proxy/v4alpha/thrift_proxy.proto
	source/extensions/filters/network/thrift_proxy/config.cc
	test/extensions/filters/network/thrift_proxy/router_ratelimit_test.cc

Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Adding template base classes for rds handling
Use base classes instead previsous copy-pasted solution in thrift.
Rework existing rds implementation for http to use the new base classes.

Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Even if the config was invalid it was stored.
This confused delta updates.

Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Remove reference to Rds::ConfigFactory form Rds::RdsRouteConfigProviderImpl
and RdsRouteConfigProviderImpl.
Move init_manager.add() call into Rds::RouteConfigProviderManagerImpl::insertDynamicProvider,
in this way no need to take care of it in each provider manager.

Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
@tkovacs-2
Copy link
Copy Markdown
Contributor Author

Are there integration tests planned?

There is unit test to check if the proper TRDS endpoints are referred towards server, also for thrift config with rds on filter level.
The integration of these two parts done by common code which already has higher level test, so I did not plan to add new.

Tamas Kovacs added 2 commits March 1, 2022 14:57
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Comment thread source/extensions/filters/network/thrift_proxy/config.cc Outdated
@tkovacs-2
Copy link
Copy Markdown
Contributor Author

/retest

@repokitteh-read-only
Copy link
Copy Markdown

Retrying Azure Pipelines:
Retried failed jobs in: envoy-presubmit

🐱

Caused by: a #19982 (comment) was created by @tkovacs-2.

see: more, trace.

@tkovacs-2 tkovacs-2 requested review from adisuissa and zuercher March 9, 2022 10:00
@tkovacs-2
Copy link
Copy Markdown
Contributor Author

/retest

@repokitteh-read-only
Copy link
Copy Markdown

Retrying Azure Pipelines:
Retried failed jobs in: envoy-presubmit

🐱

Caused by: a #19982 (comment) was created by @tkovacs-2.

see: more, trace.

Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
adisuissa
adisuissa previously approved these changes Mar 11, 2022
Copy link
Copy Markdown
Contributor

@adisuissa adisuissa left a comment

Choose a reason for hiding this comment

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

/lgtm api
LGTM code changes.
/assign @htuch

Copy link
Copy Markdown
Member

@htuch htuch left a comment

Choose a reason for hiding this comment

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

Some tiny API nits. I think we should have a full integration test, since while individual parts and their integration may be tested, it would be helpful to see this demoed e2e in case we miss anything and to prevent any regression. Otherwise LGTM and ready to merge.

Comment thread api/envoy/extensions/filters/network/thrift_proxy/v3/thrift_proxy.proto Outdated
@htuch
Copy link
Copy Markdown
Member

htuch commented Mar 11, 2022

/wait

@tkovacs-2
Copy link
Copy Markdown
Contributor Author

I think we should have a full integration test, since while individual parts and their integration may be tested,

Ok, I have just noticed there are integration tests for thrift I try to add one for trds.

Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>

Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
@tkovacs-2 tkovacs-2 requested review from adisuissa and htuch March 13, 2022 16:41
Copy link
Copy Markdown
Member

@htuch htuch 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!

@htuch htuch merged commit ec7ef59 into envoyproxy:main Mar 15, 2022
@wbpcode
Copy link
Copy Markdown
Member

wbpcode commented Mar 15, 2022

Great PR. Thanks for the rds templating. Then, we can try to add dubbo rds to Envoy just by adding little codes.

ravenblackx pushed a commit to ravenblackx/envoy that referenced this pull request Jun 8, 2022
Adding xDS routing discovery support for thrift proxy.

The routing discovery is supported only through ADS. No separate service endpoints added
for thrift routing config type url.

This PR is split from envoyproxy#17631

Risk Level: Low
Testing:
- Unittest
- Manual test with static routing from bootstrap config, static routing and dynamic routing from GRPC based xDS server.
Docs Changes: Comment added to the new API field.

Signed-off-by: Tamas Kovacs <tamas.2.kovacs@nokia-sbell.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants