Skip to content

fix: create a cluster per destination setting for backends with filters#5269

Merged
arkodg merged 12 commits intoenvoyproxy:mainfrom
arkodg:clusters-with-filters
Feb 26, 2025
Merged

fix: create a cluster per destination setting for backends with filters#5269
arkodg merged 12 commits intoenvoyproxy:mainfrom
arkodg:clusters-with-filters

Conversation

@arkodg
Copy link
Copy Markdown
Contributor

@arkodg arkodg commented Feb 13, 2025

  • create a unique name by adding a new destination setting field
  • create a unique cluster per dest setting if the setting contains filters
  • reuse that for locality region name as well

Fixes: #5230

@arkodg arkodg requested a review from a team as a code owner February 13, 2025 03:02
@arkodg arkodg marked this pull request as draft February 13, 2025 03:04
@guydc
Copy link
Copy Markdown
Contributor

guydc commented Feb 14, 2025

CP to 1.3.1?

@arkodg arkodg force-pushed the clusters-with-filters branch 6 times, most recently from ae66f70 to b510499 Compare February 23, 2025 01:53
@arkodg arkodg marked this pull request as ready for review February 23, 2025 01:54
@arkodg arkodg requested a review from a team February 23, 2025 01:54
@arkodg arkodg mentioned this pull request Feb 25, 2025
Arko Dasgupta added 10 commits February 24, 2025 17:22
* create a unique name by adding a new destination setting field
* create a unique cluster per dest setting if the setting contains
  filters
* reuse that for locality region name as well

Signed-off-by: Arko Dasgupta <arko@tetrate.io>
Signed-off-by: Arko Dasgupta <arko@tetrate.io>
Signed-off-by: Arko Dasgupta <arko@tetrate.io>
Signed-off-by: Arko Dasgupta <arko@tetrate.io>
Signed-off-by: Arko Dasgupta <arko@tetrate.io>
Signed-off-by: Arko Dasgupta <arko@tetrate.io>
Signed-off-by: Arko Dasgupta <arko@tetrate.io>
Signed-off-by: Arko Dasgupta <arko@tetrate.io>
Signed-off-by: Arko Dasgupta <arko@tetrate.io>
Signed-off-by: Arko Dasgupta <arko@tetrate.io>
@arkodg arkodg force-pushed the clusters-with-filters branch from dbe351c to 981faa8 Compare February 25, 2025 01:50
@codecov
Copy link
Copy Markdown

codecov bot commented Feb 25, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 65.06%. Comparing base (a41e992) to head (6323b00).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #5269      +/-   ##
==========================================
+ Coverage   64.97%   65.06%   +0.09%     
==========================================
  Files         213      213              
  Lines       33505    33570      +65     
==========================================
+ Hits        21769    21843      +74     
+ Misses      10405    10398       -7     
+ Partials     1331     1329       -2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Signed-off-by: Arko Dasgupta <arko@tetrate.io>
@arkodg arkodg requested a review from a team February 25, 2025 19:57
guydc
guydc previously approved these changes Feb 25, 2025
Copy link
Copy Markdown
Contributor

@guydc guydc left a comment

Choose a reason for hiding this comment

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

LGTM

@arkodg arkodg requested a review from zirain February 25, 2025 22:55
zirain
zirain previously approved these changes Feb 26, 2025
Copy link
Copy Markdown
Member

@zirain zirain left a comment

Choose a reason for hiding this comment

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

LGTM, can you fix the conflict?

Signed-off-by: Arko Dasgupta <arkodg@users.noreply.github.com>
@arkodg arkodg dismissed stale reviews from zirain and guydc via 6323b00 February 26, 2025 03:13
@@ -18,6 +18,8 @@ new features: |
Added support for HorizontalPodAutoscaler to helm chart

bug fixes: |

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

nit: redundant empty line


// TODO: rename this, so that we can share backend with tracing?
destName := fmt.Sprintf("accesslog_als_%d_%d", i, j)
settingName := irDestinationSettingName(destName, -1)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

nit: non-blocking

Defining a const with a meaningful name would help understand the logic :-)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Agree, I left it as is, can improve in follow up

@arkodg arkodg merged commit 664fa04 into envoyproxy:main Feb 26, 2025
25 checks passed
@arkodg arkodg deleted the clusters-with-filters branch February 26, 2025 15:37
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.

HTTPRoute weighted backends with filters attached sends traffic to the wrong backend

5 participants