Skip to content

[release-1.8] cherrypick for v1.8.5 - #10126

Merged
zirain merged 10 commits into
envoyproxy:release/v1.8from
zirain:cp-1.8.5
Sep 28, 2026
Merged

zirain merged 10 commits into
envoyproxy:release/v1.8from
zirain:cp-1.8.5

Conversation

vijaypal89 and others added 10 commits September 28, 2026 11:39
…roxy#9898)

rateLimitDeployment.pod.priorityClassName was accepted in EnvoyGateway
config but never copied onto the managed Deployment pod spec, so the
rate limit pod ignored the configured PriorityClass. Set it the same
way the proxy Deployment already does.

Fixes envoyproxy#9897

Signed-off-by: Vijay Pal <[email protected]>
(cherry picked from commit e9f9a5f)
…esource churn (envoyproxy#10019)

* fix: marshal xDS typed_config deterministically to avoid equivalent-resource churn

ToAnyWithValidation wrapped every filter typed_config via anypb.New, which uses
the default non-deterministic marshaler. Proto map fields (an access log's
json_format, JWT providers, filter metadata) then serialize in a random key
order on each translation, so semantically unchanged resources are emitted with
different bytes and republished on every reconcile.

Marshal deterministically via anypb.MarshalFrom so map keys serialize in a stable
order. Add a regression test, since the golden xDS tests compare protojson output
(which re-sorts map keys) and cannot catch this.

Signed-off-by: nguyenptk <[email protected]>

* docs: add release note for deterministic xDS marshaling fix

Signed-off-by: nguyenptk <[email protected]>

---------

Signed-off-by: nguyenptk <[email protected]>
(cherry picked from commit d2736c2)
* fix: apply maxDynamicDescriptors at route level

Envoy Gateway sets max_dynamic_descriptors to 10000 only on the HCM-level
local_ratelimit filter, which carries no descriptors. The real configuration
lives in each route's typed_per_filter_config, and Envoy resolves that
per-route config as a whole without inheriting anything from the HCM filter,
so every route-level limiter fell back to Envoy's default of 20.

A Distinct rule (per client IP, per header value, per query parameter)
therefore tracked only the 20 most recently seen values: the 21st evicted
the oldest bucket, and an evicted client came back with a full bucket. That
made per-client limits on a public listener a coarse layer rather than a
bound.

Set the same limit on the route-level config, where the wildcard
descriptors actually live, and share the constant between both sites.

Signed-off-by: Andreea Popescu <[email protected]>

* test(ratelimit): cover and document dynamic bucket retention

Signed-off-by: Andreea Popescu <[email protected]>

* chore: number the local rate limit release note

Signed-off-by: Andreea Popescu <[email protected]>

* test(ratelimit): pin the limiter headers on 429

CompareRoundTrip compares response headers only for 200 and 204, so the
retention subtest's final 429 was attributed by status alone. Assert
x-ratelimit-limit and x-ratelimit-remaining on the captured response to
tie the rejection to the original user's exhausted bucket.

Also reword the constant's comment: the capacity applies per wildcard
descriptor in each route configuration, and entries are allocated on
demand.

Signed-off-by: Andreea Popescu <[email protected]>

---------

Signed-off-by: Andreea Popescu <[email protected]>
Co-authored-by: zirain <[email protected]>
(cherry picked from commit 667f73b)
…y#10050)

The cipher validation added in v1.8.0 compares each entry of the cipher
list against the set of supported cipher names as a whole string. That
rejects BoringSSL equal-preference groups such as
"[ECDHE-ECDSA-AES128-GCM-SHA256|ECDHE-ECDSA-CHACHA20-POLY1305]", which
Envoy accepts and which let the client's own preference break the tie
between equally preferred ciphers. This includes the default cipher list
documented on the ciphers field itself, so copying the documented
defaults into a ClientTrafficPolicy left it not accepted.

Unwrap group entries and validate each member, rejecting malformed
groups (unclosed, empty, nested) and a separator used outside a group.

Fixes envoyproxy#9679

Signed-off-by: Huabing (Robin) Zhao <[email protected]>
Signed-off-by: Huabing (Robin) Zhao <[email protected]>
Co-authored-by: zirain <[email protected]>
(cherry picked from commit 3ec9a01)
…when gateways are merged (envoyproxy#10013)

validateConflictedMergedListeners keys on the listener protocol verbatim, so an
HTTPS listener and a TLS listener on the same port with the same hostname land in
different buckets and are both accepted. They cannot both be served: listeners
sharing a port are told apart by SNI, and here the SNI is the same. Envoy ends up
with two filter chains carrying an identical server_names match and rejects the
listener, along with every update to it that follows.

Key on the protocol class instead, which puts HTTPS and TLS together, so the
second listener is marked Conflicted with HostnameConflict. This is what
validateConflictedHostnameListeners already does within a single Gateway;
merged Gateways were the only path that skipped the check.

Also route the conflict through setConflictedConditions rather than setting the
condition directly. Every other conflict path already uses it, and it is what
sets Accepted=False and Programmed=False on a ListenerSet listener -- without it
a conflicted ListenerSet entry reports no Accepted condition at all and a generic
ListenersNotValid reason for Programmed.

Signed-off-by: Huabing (Robin) Zhao <[email protected]>
Signed-off-by: Huabing (Robin) Zhao <[email protected]>
(cherry picked from commit c577775)
fix: count UDP proxy sessions in shutdown drain (envoyproxy#10109)

The shutdown manager only summed listener downstream_cx_active, which
never includes UDP proxy sessions, so a UDP-only proxy exited as soon as
the minimum drain period passed. Also count udp.*.downstream_sess_active.

Signed-off-by: Huabing (Robin) Zhao <[email protected]>
Signed-off-by: Huabing (Robin) Zhao <[email protected]>
(cherry picked from commit e428e3c)
* [envoy-gateway] Batch JSONPath matches in one apply [ci changed_files]

Signed-off-by: Cooper Gamble <[email protected]>
(cherry picked from commit 9ac70e4)
* Revert "fix(tcp): add SNI-based filter chain matching for TLS passthrough empty routes (envoyproxy#8521)"

This reverts commit c11f0c2.

emitting identical EmptyCluster filter chains -- by collapsing the placeholder
chains into a single shared one, rather than by giving them distinct matchers.
Collapsing only helps against another placeholder: it does nothing when the
colliding chain belongs to a different listener, which is why envoyproxy#9341 and envoyproxy#9516
still reproduce. Its own commit message describes adding SNI matching, but the
merged change carries none.

Restore the per-listener empty route. The commits that follow add the SNI match
the placeholder chains actually need, which keeps them unique on their own.

Signed-off-by: Huabing (Robin) Zhao <[email protected]>
Signed-off-by: Huabing (Robin) Zhao <[email protected]>

* fix(translator): match SNI on every TCP filter chain

Filter chains on a shared xDS listener must each have a distinct match or
Envoy rejects the listener and stops accepting updates to it. Placeholder
chains for route-less listeners had no match at all, so one sharing a port
with a wildcard HTTPS listener produced two `{}` matchers and a NACK.

Carry the Gateway listener hostname on the TCP IR listener, for TLS protocol
listeners only since TCP ignores hostnames, and resolve the SNI once in
addXdsTCPFilterChain, falling back to that hostname whenever the route carries
none of its own. Every TCP filter chain is then matched the same way and the
placeholder needs no special case.

Reinstate the envoyproxy#7866 regression test dropped by the revert, with each listener
given a distinct hostname -- listeners sharing a port with identical hostnames
are rejected with HostnameConflict before translation, so this is what the
Gateway API layer actually emits. It now asserts three chains with three
distinct serverNames rather than one shared chain.

Co-authored-by: Florian Wiegand <[email protected]>
Signed-off-by: Florian Wiegand <[email protected]>
Signed-off-by: Huabing (Robin) Zhao <[email protected]>
Signed-off-by: Huabing (Robin) Zhao <[email protected]>

* clean up

Signed-off-by: Huabing (Robin) Zhao <[email protected]>

* fix(translator): name the placeholder filter chain after its listener

The placeholder chain for a route-less TCP listener was named after the
EmptyCluster it points at, which reads as a cluster in a config dump and
goes stale if the placeholder ever targets something else. Name it after
the listener that owns it instead, with a /no-routes suffix saying why
the chain exists.

Signed-off-by: Huabing (Robin) Zhao <[email protected]>
Signed-off-by: Huabing (Robin) Zhao <[email protected]>

* test: include SNI hostname in merged gateway fixture

Signed-off-by: Huabing (Robin) Zhao <[email protected]>

---------

Signed-off-by: Huabing (Robin) Zhao <[email protected]>
Signed-off-by: Huabing (Robin) Zhao <[email protected]>
Signed-off-by: Florian Wiegand <[email protected]>
Co-authored-by: Florian Wiegand <[email protected]>
(cherry picked from commit 9175177)
Signed-off-by: zirain <[email protected]>

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
@zirain
zirain requested a review from a team as a code owner September 28, 2026 03:46
@codecov

codecov Bot commented Sep 28, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 93.50649% with 5 lines in your changes missing coverage. Please review.
✅ Project coverage is 75.17%. Comparing base (9f5ad3e) to head (7bac2c5).

Files with missing lines Patch % Lines
internal/utils/jsonpatch/patch.go 75.00% 1 Missing and 1 partial ⚠️
internal/xds/translator/translator.go 84.61% 1 Missing and 1 partial ⚠️
internal/utils/proto/proto.go 66.66% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@               Coverage Diff                @@
##           release/v1.8   #10126      +/-   ##
================================================
+ Coverage         75.14%   75.17%   +0.02%     
================================================
  Files               253      253              
  Lines             41310    41328      +18     
================================================
+ Hits              31042    31067      +25     
+ Misses             8147     8144       -3     
+ Partials           2121     2117       -4     

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@zirain
zirain merged commit db5bf96 into envoyproxy:release/v1.8 Sep 28, 2026
95 of 105 checks passed
@zirain
zirain deleted the cp-1.8.5 branch September 28, 2026 07:15
@zirain zirain mentioned this pull request Sep 28, 2026
15 tasks done
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.

8 participants