Skip to content
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

Add a per-rule example for NetworkpolicyStats docs #3356

Merged

Conversation

ceclinux
Copy link
Contributor

It seems the per-rule example for feature NetworkpolicyStats is missing.

Signed-off-by: ceclinux src655@gmail.com


# List per-rule statistics for Antrea ClusterNetworkPolicy cluster-access-dns.
# Both Antrea NetworkPolicy and Antrea ClusterNetworkPolicy support per-rule statistics view.
kubectl get antreaclusternetworkpolicystats cluster-access-dns -o json
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
kubectl get antreaclusternetworkpolicystats cluster-access-dns -o json
> kubectl get antreaclusternetworkpolicystats cluster-access-dns -o json

for consistency

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

updated

@@ -159,6 +159,42 @@ cluster-access-dns 10 120 12210 2020-09-07T13:22:42Z
NAMESPACE NAME SESSIONS PACKETS BYTES CREATED AT
default access-http 3 36 5199 2020-09-07T13:19:38Z
foo bar 1 12 1221 2020-09-07T13:22:42Z

# List per-rule statistics for Antrea ClusterNetworkPolicy cluster-access-dns.
# Both Antrea NetworkPolicy and Antrea ClusterNetworkPolicy support per-rule statistics view.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# Both Antrea NetworkPolicy and Antrea ClusterNetworkPolicy support per-rule statistics view.
# Both Antrea NetworkPolicy and Antrea ClusterNetworkPolicy support per-rule statistics.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

updated

@antoninbas antoninbas added the kind/documentation Categorizes issue or PR as related to a documentation. label Feb 24, 2022
Signed-off-by: ceclinux <src655@gmail.com>
@ceclinux ceclinux force-pushed the add_networkpolicystats_perrule_docs branch from 1a70637 to 65185ed Compare February 25, 2022 02:08
@codecov-commenter
Copy link

codecov-commenter commented Feb 25, 2022

Codecov Report

Merging #3356 (65185ed) into main (0ffcfc9) will decrease coverage by 22.30%.
The diff coverage is n/a.

Impacted file tree graph

@@             Coverage Diff             @@
##             main    #3356       +/-   ##
===========================================
- Coverage   62.13%   39.82%   -22.31%     
===========================================
  Files         266      305       +39     
  Lines       26519    38460    +11941     
===========================================
- Hits        16477    15317     -1160     
- Misses       8222    21601    +13379     
+ Partials     1820     1542      -278     
Flag Coverage Δ
integration-tests 36.24% <ø> (?)
kind-e2e-tests ?
unit-tests 41.94% <ø> (+0.35%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
pkg/ovs/openflow/default.go 0.00% <0.00%> (-100.00%) ⬇️
pkg/util/runtime/runtime.go 0.00% <0.00%> (-100.00%) ⬇️
pkg/agent/nodeportlocal/k8s/annotations.go 0.00% <0.00%> (-93.55%) ⬇️
pkg/ovs/openflow/logs.go 9.52% <0.00%> (-90.48%) ⬇️
pkg/apis/controlplane/register.go 0.00% <0.00%> (-90.00%) ⬇️
pkg/agent/controller/networkpolicy/reject.go 0.00% <0.00%> (-87.91%) ⬇️
pkg/agent/client.go 0.00% <0.00%> (-77.42%) ⬇️
pkg/ovs/ovsconfig/ovs_client_linux.go 0.00% <0.00%> (-76.93%) ⬇️
pkg/flowaggregator/certificate.go 0.00% <0.00%> (-76.58%) ⬇️
...agent/controller/traceflow/traceflow_controller.go 0.00% <0.00%> (-73.41%) ⬇️
... and 292 more

Copy link
Contributor

@antoninbas antoninbas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@antoninbas
Copy link
Contributor

/skip-all

@antoninbas antoninbas merged commit 0e4bf90 into antrea-io:main Feb 25, 2022
bangqipropel pushed a commit to bangqipropel/antrea that referenced this pull request Mar 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/documentation Categorizes issue or PR as related to a documentation.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants