Skip to content

Remove endpoint support - #2254

Merged
fedepaol merged 2 commits into
metallb:mainfrom
fedepaol:removeendpointsupport
Jan 26, 2024
Merged

fedepaol merged 2 commits into
metallb:mainfrom
fedepaol:removeendpointsupport

Conversation

@fedepaol

Copy link
Copy Markdown
Member

Endpoint slices is supported since k8s 1.21, it's sane to remove the endpoint support and all the duplicated code, and rely on ep slices only.

@fedepaol
fedepaol force-pushed the removeendpointsupport branch 3 times, most recently from 9e37816 to 079d759 Compare January 23, 2024 21:25
expectedLBRet: controllers.SyncStateSuccess,
},
{
desc: "Multiple advertisement config, one only for my node",

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: this and the next one do not have an epslice one with the same name, just making sure we're good with zapping them

Comment thread internal/k8s/controllers/endpoints.go Outdated
return res, err
}
res = epslices.EpsOrSlices{EpVal: &endpoints, Type: epslices.Eps}
func endPointsForService(ctx context.Context, cl client.Reader, serviceName types.NamespacedName) ([]discovery.EndpointSlice, error) {

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: rename to epSlicesForService ?

Comment thread website/content/release-notes/_index.md Outdated
Being deprecated for a while we finally stop handling the legacy API and remove it,
IPs can now be allocated to LoadBalancer Services only via IPAddressPool resources. ([PR 2252](https://github.com/metallb/metallb/pull/2252))
- Drop the support for endpoints and rely on endpoint slices only ([Issue 2253](https://github.com/metallb/metallb/issues/2253), [PR 2254](https://github.com/metallb/metallb/pull/2254))
**NOTE:** this will make metallb not compatible with clusters older than 1.21

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: metallb -> MetalLB

@fedepaol
fedepaol force-pushed the removeendpointsupport branch from 079d759 to 3f87770 Compare January 25, 2024 09:48

@oribon oribon left a comment

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.

lgtm

Endpoint slices is supported since k8s 1.21, it's sane to remove the
endpoint support and all the duplicated code, and rely on ep slices
only.

This would simplify the codebase making it more maintainable.

Signed-off-by: Federico Paolinelli <fpaoline@redhat.com>
When we destroy the cluster with kind delete cluster, the network2
network remains dangling and a sequent inv dev-env command will fail to
create it. Here we don't create if it exists already.

Signed-off-by: Federico Paolinelli <fpaoline@redhat.com>
@fedepaol
fedepaol force-pushed the removeendpointsupport branch from 3f87770 to e8741e0 Compare January 26, 2024 09:27
@fedepaol
fedepaol enabled auto-merge January 26, 2024 10:29
@fedepaol
fedepaol added this pull request to the merge queue Jan 26, 2024
Merged via the queue into metallb:main with commit d3ee1b3 Jan 26, 2024
@fedepaol fedepaol mentioned this pull request Feb 12, 2024
2 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.

2 participants