Skip to content

[v1.18] Backport: k8s: include namespace in EndpointSliceName#44021

Merged
tklauser merged 2 commits intocilium:v1.18from
EmilyShepherd:v1.18-namespace-endpointslices
Feb 25, 2026
Merged

[v1.18] Backport: k8s: include namespace in EndpointSliceName#44021
tklauser merged 2 commits intocilium:v1.18from
EmilyShepherd:v1.18-namespace-endpointslices

Conversation

@EmilyShepherd
Copy link
Copy Markdown
Contributor

@EmilyShepherd EmilyShepherd commented Jan 26, 2026

Backport of #43999:

5c146c3
74c1bde

I have provided an explicit backport PR because v1.18 does not include d003678, which removed the older EndpointSlicesV1Beta and Endpoints APIs. As v1.18 still includes these APIs, simply copy-pasting the patchset from #43999 would cause the tests that covered those APIs to fail.

cc @joamaki & @borkmann as you reviewed the original PR.

Once this PR is merged, a GitHub action will update the labels of these PRs:

43999

@EmilyShepherd EmilyShepherd requested a review from a team as a code owner January 26, 2026 20:54
@maintainer-s-little-helper maintainer-s-little-helper bot added backport/1.18 This PR represents a backport for Cilium 1.18.x of a PR that was merged to main. kind/backports This PR provides functionality previously merged into master. labels Jan 26, 2026
@github-actions github-actions bot added the kind/community-contribution This was a contribution made by a community member. label Jan 26, 2026
@EmilyShepherd
Copy link
Copy Markdown
Contributor Author

These CI tests are strugglin'.

@EmilyShepherd EmilyShepherd force-pushed the v1.18-namespace-endpointslices branch 2 times, most recently from eaf9f0f to 86175c2 Compare January 27, 2026 01:33
@joamaki
Copy link
Copy Markdown
Contributor

joamaki commented Feb 3, 2026

/test

@ldelossa
Copy link
Copy Markdown
Contributor

ldelossa commented Feb 5, 2026

@EmilyShepherd

Looks like we some legitimate failures here: https://github.com/cilium/cilium/actions/runs/21623311418/job/62317229107

Can you take a look and see if you suspect they are attributed to this pull request?

@EmilyShepherd
Copy link
Copy Markdown
Contributor Author

@EmilyShepherd

Looks like we some legitimate failures here: https://github.com/cilium/cilium/actions/runs/21623311418/job/62317229107

Can you take a look and see if you suspect they are attributed to this pull request?

I don't think these failures are related. This PR is about the cilium load balancer. The test failures are to do with permissions on envoy ingress resources and some random dns failures.

The field changed in this PR isn't consumed by anything other than pkg/loadbalancer/reflectors/k8s.go.

@pchaigno pchaigno enabled auto-merge February 11, 2026 13:25
@pchaigno
Copy link
Copy Markdown
Member

@EmilyShepherd The Conformance Cluster Mesh failures persist so could you try to rebase on latest v1.18 and we'll see if that fixes it? I don't see how it could be related to your changes.

@giorio94
Copy link
Copy Markdown
Member

The Conformance Cluster Mesh failures persist so could you try to rebase on latest v1.18 and we'll see if that fixes it

Yeah, a rebase is required to fix it.

[ upstream commit 74c1bde ]

This commit adds a test that when we have two EndpointSlices in
different namespaces with the same name, that these do not cause any
collisions or problems.

Specifically, we test the scenario where two EndpointSlices are setup,
then one is modified by removing an address. This should be correctly
picked up and the backend removed from the BPF maps.

This test is a regression test for cilium#43999.

Signed-off-by: Emily Shepherd <emily@redcoat.dev>
[ upstream commit 5c146c3 ]

We previously did not include the Namespace in EndpointSliceNames,
relying on the fact that EndpointSlices that use generateName- are
unlikely to have name collisions, even across namespaces. While this is
usually the case, there is no requirement for EndpointSlice managers to
use generateName, and there are examples of controllers that do not (for
example the master kubernetes service's EndpointSlice is always called
"kubernetes").

Including the namespace in EndpointSliceNames guarantees collisions
cannot occur.

See cilium#43999 for further discussion
of this bug.

Signed-off-by: Emily Shepherd <emily@redcoat.dev>
auto-merge was automatically disabled February 17, 2026 18:03

Head branch was pushed to by a user without write access

@EmilyShepherd EmilyShepherd force-pushed the v1.18-namespace-endpointslices branch from 86175c2 to ec5d2c0 Compare February 17, 2026 18:03
@EmilyShepherd
Copy link
Copy Markdown
Contributor Author

@pchaigno @giorio94 apologies for the delay. This is now rebased.

@pchaigno
Copy link
Copy Markdown
Member

/test

@pchaigno pchaigno enabled auto-merge February 17, 2026 18:05
auto-merge was automatically disabled February 22, 2026 14:37

Pull request was closed

@pchaigno
Copy link
Copy Markdown
Member

@EmilyShepherd I see this is now closed. What happened?

@EmilyShepherd
Copy link
Copy Markdown
Contributor Author

@pchaigno After re-basing a different test failed. As before I am not sure how those failures could have been related to these changes, however I attempted to investigate as far as I could. Unfortunately, however, as I am not a Member of the project I cannot trigger retests without persistently tagging members which feels like bad form to just do over and over for however long it will take to either get to the bottom of the issue with this PR, if there is one, or get the tests to pass, if they are just flaky - I am not sure which is the culprit. As a result, I do not see a way for this PR to productively be resolved.

@pchaigno
Copy link
Copy Markdown
Member

@EmilyShepherd If you've triaged the test failures and don't see any relation to your changes, I'd say it's up to the reviews/maintainers to retrigger until it passes. That's usually what I do on lots of PRs from external contributors.

@EmilyShepherd
Copy link
Copy Markdown
Contributor Author

@pchaigno Oks - If that is acceptable then, I'll reopen and leave it to the reviewers to trigger the tests.

cc @joamaki @borkmann

@EmilyShepherd EmilyShepherd reopened this Feb 23, 2026
@pchaigno pchaigno enabled auto-merge February 25, 2026 17:46
@pchaigno pchaigno added this pull request to the merge queue Feb 25, 2026
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Feb 25, 2026
@tklauser tklauser added this pull request to the merge queue Feb 25, 2026
Merged via the queue into cilium:v1.18 with commit 6d5a300 Feb 25, 2026
122 of 123 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport/1.18 This PR represents a backport for Cilium 1.18.x of a PR that was merged to main. kind/backports This PR provides functionality previously merged into master. kind/community-contribution This was a contribution made by a community member.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants