-
Notifications
You must be signed in to change notification settings - Fork 366
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Prepare for Antrea IPAM StatefulSet support #3141
Conversation
Codecov Report
@@ Coverage Diff @@
## main #3141 +/- ##
===========================================
- Coverage 60.59% 47.90% -12.69%
===========================================
Files 297 491 +194
Lines 25434 43453 +18019
===========================================
+ Hits 15411 20818 +5407
- Misses 8345 20476 +12131
- Partials 1678 2159 +481
Flags with carried forward coverage won't be shown. Click here to find out more.
|
/test-all |
d190235
to
e4b500c
Compare
I will be adding workers to the controller, since the delete operation is heavy. |
/test-all |
4b0c436
to
2b45d2b
Compare
e2e failed. Permission issue. Please add rbac into this PR.
|
Hi Anna, |
2b45d2b
to
8d57597
Compare
/test-all |
8d57597
to
901c1d7
Compare
/test-all |
Fixed permissions and rebased |
// This functionality is useful when StatefulSet does not have a dedicated IP Pool assigned. | ||
// It returns error if such range is not available. In this case IPs for the StatefulSet will | ||
// be allocated on the fly, and there is no guarantee for continuous IPs. | ||
func (a *IPPoolAllocator) AllocateStatefulSet(namespace, name string, size int) error { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Where is it called? If it's just a preparation for another feature, could you move it and all the callees it introduces to the PR that implements the feature? Otherwise it's hard to say whether the methods can really fit that feature without any caller and may introduce unnecessary changes.
This PR could focus on StatefulSet Pod IP cleanup which is scoped in 1.5?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is for future feature, and not used in code as of today, but used in tests. I'd prefer to include this in the PR for future use rather than copying this functionality in testing.
Hi Anna, Below case is using a dedicated IPPool for StatefulSet and the name is
|
4b44f60
to
a575be5
Compare
/test-all |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
flexible-ipam-e2e passed. Thanks.
a575be5
to
50565ba
Compare
/test-all |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
flexible-ipam-e2e passed
50565ba
to
8093a95
Compare
* Support continuous IP range allocation in IP allocator * Support pe-allocating continuous range of IPs from an IP Pool for StatefulSet. This functionality will be used by StatefulSets that do not have a dedicated IP Pool annotated. * Support releasing all IP address entries associated with a StatefulSet in IP Pool * Implement Antrea Controller responsible for clearing IP Pool allocations when StatefulSet is deleted Signed-off-by: Anna Khmelnitsky <akhmelnitsky@vmware.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM overall
8093a95
to
0884d2c
Compare
/test-flexible-ipam-e2e |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
flexible-ipam-e2e passed with #3146 , which means this PR should also pass this pipeline.
/skip-e2e |
* Support continuous IP range allocation in IP allocator * Support pre-allocating continuous range of IPs from an IP Pool for StatefulSet. This functionality will be used by StatefulSets that do not have a dedicated IP Pool annotated. * Support releasing all IP address entries associated with a StatefulSet in IP Pool * Implement Antrea Controller responsible for clearing IP Pool allocations when StatefulSet is deleted Signed-off-by: Anna Khmelnitsky <akhmelnitsky@vmware.com>
Pool for StatefulSet. This functionality will be used by
StatefulSets that do not have a dedicated IP Pool annotated.
Signed-off-by: Anna Khmelnitsky akhmelnitsky@vmware.com