Skip to content

Add avoidBuggyIPs to the IPAddressPool CIDR - #1515

Merged
fedepaol merged 7 commits into
metallb:mainfrom
fedepaol:restoreavoidbuggyips
Jul 19, 2022
Merged

fedepaol merged 7 commits into
metallb:mainfrom
fedepaol:restoreavoidbuggyips

Conversation

@fedepaol

Copy link
Copy Markdown
Member

We originally thought that the avoidBuggyIPs flag was replaceable by picking the equivalent range of the cidr minus the extremes.
The issue is, the aggregation length validation won't work in that case because a 10.0.1.1-10.1.1.254 range doesn't correspond to a /24 cidr.
Because of that, we believe that bringing the flag back is safer than trying to understand if a range belongs to a cidr minus the buggy ips (and if the user's intention was to avoid them in first place).

Comment thread website/content/release-notes/_index.md Outdated
- Change the validating webhook configuration name to metallb-webhook-configuration instead of validating-webhook-configuration ([PR 1497](https://github.com/metallb/metallb/pull/1497))
- L2 mode not working with ipv4 only nodes ([Issue 1507](https://github.com/metallb/metallb/issues/1507) , [PR 1506](https://github.com/metallb/metallb/pull/1506))
- Add the AvoidBuggyIPs flag to the IPAddressPool CRD. Converting a CIDR to a range comes with limitation related
to setting the aggregation lenght and validating it. ([Issue 1495](https://github.com/metallb/metallb/issues/1495),

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: lenght -> length

@fedepaol
fedepaol force-pushed the restoreavoidbuggyips branch from 2cbda9d to 42d2479 Compare July 18, 2022 12:56
fedepaol added 7 commits July 18, 2022 17:03
This reverts commit e4d0d18.

We restore the avoidbuggyIP files because setting ranges is not
syntactically equivalent, if used in conjunction with aggregation
length.
A 10.0.1/24 range will become 10.0.1.1 - 10.0.1.254 which will fail a
check against the /24 aggregation length (while it should not).

Attempting to reverse the intention of the user is risky and prone to
corner cases, so it's better to restore the original configurability
option.
The original port from the operator inadvertently added the field to the
legacy addresspool too.
Here we are removing it to bring parity with the old api and to make the
field exist only in the new and stable API.

Signed-off-by: Federico Paolinelli <fpaoline@redhat.com>
Regenerate the manifests to be aligned with the change.

Signed-off-by: Federico Paolinelli <fpaoline@redhat.com>
Adding it to the charts after restoring it to the apis.

Signed-off-by: Federico Paolinelli <fpaoline@redhat.com>
Regenerating the apidocs after adding the avoidbuggyips flag

Signed-off-by: Federico Paolinelli <fpaoline@redhat.com>
Now that the avoidbuggyips flag is added to the ipaddresspool api, we
can convert it straight away and not convert cidrs to ranges.

Signed-off-by: Federico Paolinelli <fpaoline@redhat.com>
Adding the item to the release notes.

Signed-off-by: Federico Paolinelli <fpaoline@redhat.com>
@fedepaol
fedepaol force-pushed the restoreavoidbuggyips branch from 42d2479 to f267c40 Compare July 18, 2022 15:04

@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

@fedepaol
fedepaol merged commit 306a656 into metallb:main Jul 19, 2022
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