-
Notifications
You must be signed in to change notification settings - Fork 364
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
Bump ClusterGroup to crd/v1alpha3 and deprecate single ipBlock #2008
Conversation
This pull request introduces 6 alerts when merging 6e2ce92 into 85456c9 - view on LGTM.com new alerts:
|
This pull request introduces 6 alerts when merging 41425b0 into 85456c9 - view on LGTM.com new alerts:
|
Codecov Report
@@ Coverage Diff @@
## main #2008 +/- ##
==========================================
- Coverage 61.57% 55.15% -6.43%
==========================================
Files 265 268 +3
Lines 19770 19949 +179
==========================================
- Hits 12174 11003 -1171
- Misses 6333 7782 +1449
+ Partials 1263 1164 -99
Flags with carried forward coverage won't be shown. Click here to find out more.
|
This pull request introduces 6 alerts when merging 322b9a2 into 3b294ea - view on LGTM.com new alerts:
|
This pull request introduces 6 alerts when merging 65b1957 into 5752f96 - view on LGTM.com new alerts:
|
This pull request introduces 6 alerts when merging dcea255 into 1890da1 - view on LGTM.com new alerts:
|
This pull request introduces 6 alerts when merging a11ce47 into 1890da1 - view on LGTM.com new alerts:
|
This pull request introduces 6 alerts when merging 1ca667c into 1890da1 - view on LGTM.com new alerts:
|
Codecov Report
@@ Coverage Diff @@
## main #2008 +/- ##
=======================================
Coverage 41.33% 41.33%
=======================================
Files 132 132
Lines 16539 16539
=======================================
Hits 6837 6837
Misses 9115 9115
Partials 587 587
Flags with carried forward coverage won't be shown. Click here to find out more. |
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.
Reviewed 37 files so far, will continue..
This pull request introduces 6 alerts when merging 69887bd into 9bb7179 - view on LGTM.com new alerts:
|
This pull request introduces 1 alert when merging deb023b into 422d92d - view on LGTM.com new alerts:
|
This pull request introduces 1 alert when merging ec478e6 into d6e1d7e - view on LGTM.com new alerts:
|
This pull request introduces 1 alert when merging b5eab04 into 03fe6ee - view on LGTM.com new alerts:
|
This pull request introduces 1 alert when merging 4b7086e into ce7c844 - view on LGTM.com new alerts:
|
This pull request introduces 1 alert when merging ed0bded into ce7c844 - view on LGTM.com new alerts:
|
/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.
LGTM, however conflicts need to be resolved
Rebased onto the main branch |
This pull request introduces 1 alert when merging 7364b7f into 771477a - view on LGTM.com new alerts:
|
pkg/controller/grouping/convert.go
Outdated
@@ -0,0 +1,69 @@ | |||
// Copyright 2021 Antrea Authors |
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.
Sorry, I just noticed this location of this file. I fell it might be a little confusing for developers that the package contains unrelated two topics: one is the calculation of the group members, one is the convertion of ClusterGroup API. What do you think about pkg/apiserver/handlers/webhook/ for this file?
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.
I moved it to pkg/controller/networkpolicy/convert.go
to follow what the validation and mutation webhook's pattern. I'll leave it out of pkg/apiserver/handlers/webhook/
so that this pkg can focus on the webhook infra and not the actual conversion/mutation/validation logic
This pull request introduces 1 alert when merging fa4d34d into 3134f7e - view on LGTM.com new alerts:
|
Add apiextensions-apiserver clientset and convert function for two versions of CRDs Add convert function for the two versions of CRDs Add controller logic to handle ipBlocks Fix issues in webhook registration Fix conversion logic Add E2E test and fix UT Address comment Signed-off-by: Yang Ding <[email protected]>
/test-all |
This pull request introduces 1 alert when merging ca34206 into 3134f7e - view on LGTM.com new alerts:
|
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
/test-networkpolicy |
1 similar comment
/test-networkpolicy |
This PR upgrades ClusterGroup CRD related resources to
crd/v1alpha3
to deprecateipBlock
incrd/v1alpha2
ClusterGroup.The CRD upgrade process follows https://kubernetes.io/docs/tasks/extend-kubernetes/custom-resources/custom-resource-definition-versioning/. Namely, there is a conversion webhook deployed to convert
crd/v1alpha2
ClusterGroup tocrd/v1alpha3
and vice versa.crd/v1alpha2
ClusterGroup will continue to be served until deprecated.On Antrea controller startup it will use the apiextension clienset to sync CA cert between Antrea apiserver and conversion webhook config of the ClusterGroup CRD. Conversion endpoint will be
/convert/clustergroup
.