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
Return an empty list when NetworkPolicyStats is disabled #2386
Return an empty list when NetworkPolicyStats is disabled #2386
Conversation
Signed-off-by: Peter Eltgroth <peltgroth@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
Don't worry about updating the "Unreleased" section. I need to update the CONTRIBUTING guidelines apparently :)
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.
You may need to update pkg/apiserver/registry/stats/antreaclusternetworkpolicystats/rest.go and pkg/apiserver/registry/stats/antreanetworkpolicystats/rest.go as well, otherwise the other two APIs will still return the error if Flux discovers them.
I'll take a look today. |
…est' Signed-off-by: Peter Eltgroth <peltgroth@vmware.com>
|
@PeterEltgroth thanks for the PR. It still missed "pkg/apiserver/registry/stats/antreaclusternetworkpolicystats/rest.go". They have to be 3 stats APIs because:
|
…est' Signed-off-by: Peter Eltgroth <peltgroth@vmware.com>
Codecov Report
@@ Coverage Diff @@
## main #2386 +/- ##
===========================================
+ Coverage 42.03% 59.80% +17.77%
===========================================
Files 146 284 +138
Lines 18136 22178 +4042
===========================================
+ Hits 7623 13264 +5641
+ Misses 9827 7488 -2339
- Partials 686 1426 +740
Flags with carried forward coverage won't be shown. Click here to find out more.
|
|
/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, thanks @PeterEltgroth
|
/skip-conformance |
Fixes #2214. When
NetworkPolicyStatsis disabled an empty list is now returned rather thanBadRequest.In testing this change allowed a Sonobuoy test suite which used Flux to sync, rather than fail to sync.
Contrinuting step 5 says to update "Unreleased"; however, I did not find a section titled that in any of the changelog documents.
Signed-off-by: Peter Eltgroth peltgroth@vmware.com