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

[WIP] Controller side changes for AntreaNetworkPolicy #797

Closed
wants to merge 3 commits into from

Conversation

Dyanngg
Copy link
Contributor

@Dyanngg Dyanngg commented Jun 4, 2020

No description provided.

@antrea-bot
Copy link
Collaborator

Thanks for your PR.
Unit tests and code linters are run automatically every time the PR is updated.
E2e, conformance and network policy tests can only be triggered by a member of the vmware-tanzu organization. Regular contributors to the project should join the org.

The following commands are available:

  • /test-e2e: to trigger e2e tests.
  • /skip-e2e: to skip e2e tests.
  • /test-conformance: to trigger conformance tests.
  • /skip-conformance: to skip conformance tests.
  • /test-networkpolicy: to trigger networkpolicy tests.
  • /skip-networkpolicy: to skip networkpolicy tests.
  • /test-windows-conformance: to trigger windows conformance tests.
  • /skip-windows-conformance: to skip windows conformance tests.
  • /test-all: to trigger all tests.
  • /skip-all: to skip all tests.

These commands can only be run by members of the vmware-tanzu organization.

@Dyanngg Dyanngg changed the title Controller side changes for AntreaNetworkPolicy [WIP] Controller side changes for AntreaNetworkPolicy Jun 4, 2020
@Dyanngg Dyanngg force-pushed the anp-ctrl branch 3 times, most recently from 2cda1e7 to cbedaf1 Compare June 4, 2020 22:50
Copy link
Contributor

@suwang48404 suwang48404 left a comment

Choose a reason for hiding this comment

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

On a high level, changes looks pretty reasonable to me.

cmd/antrea-controller/controller.go Outdated Show resolved Hide resolved
@@ -114,3 +114,115 @@ func (s GroupMemberPodSet) IsSuperset(o GroupMemberPodSet) bool {
func (s GroupMemberPodSet) Equal(o GroupMemberPodSet) bool {
return len(s) == len(o) && s.IsSuperset(o)
}

Copy link
Contributor

Choose a reason for hiding this comment

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

not sure if the following is required as it is already declared under v1beta1/sets.go

Copy link
Contributor Author

Choose a reason for hiding this comment

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

If you look at GroupMemberPodSet it is also defined in both networking/sets.go and v1beta1/sets.go. They might be able to be merged via imports but I am not sure of the scope

pkg/controller/networkpolicy/networkpolicy_controller.go Outdated Show resolved Hide resolved
pkg/controller/networkpolicy/networkpolicy_controller.go Outdated Show resolved Hide resolved
pkg/controller/networkpolicy/networkpolicy_controller.go Outdated Show resolved Hide resolved
pkg/controller/networkpolicy/networkpolicy_controller.go Outdated Show resolved Hide resolved
Copy link
Contributor Author

@Dyanngg Dyanngg left a comment

Choose a reason for hiding this comment

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

Upon testing on local env I found out the functions for addExternalEntity etc. (similar to addPod, updatePod, deletePod) is not yet defined in networkpolicy_controller. Will update the patch to include that.

pkg/controller/networkpolicy/networkpolicy_controller.go Outdated Show resolved Hide resolved
pkg/controller/networkpolicy/networkpolicy_controller.go Outdated Show resolved Hide resolved
pkg/controller/networkpolicy/networkpolicy_controller.go Outdated Show resolved Hide resolved
@antrea-bot
Copy link
Collaborator

Thanks for your PR.
Unit tests and code linters are run automatically every time the PR is updated.
E2e, conformance and network policy tests can only be triggered by a member of the vmware-tanzu organization. Regular contributors to the project should join the org.

The following commands are available:

  • /test-e2e: to trigger e2e tests.
  • /skip-e2e: to skip e2e tests.
  • /test-conformance: to trigger conformance tests.
  • /skip-conformance: to skip conformance tests.
  • /test-whole-conformance: to trigger all conformance tests on linux.
  • /skip-whole-conformance: to skip all conformance tests on linux.
  • /test-networkpolicy: to trigger networkpolicy tests.
  • /skip-networkpolicy: to skip networkpolicy tests.
  • /test-windows-conformance: to trigger windows conformance tests.
  • /skip-windows-conformance: to skip windows conformance tests.
  • /test-all: to trigger all tests (except whole conformance).
  • /skip-all: to skip all tests (except whole conformance).

These commands can only be run by members of the vmware-tanzu organization.

@Dyanngg Dyanngg force-pushed the anp-ctrl branch 9 times, most recently from fb8699e to 0bd605c Compare June 25, 2020 19:39
abhiraut and others added 2 commits July 6, 2020 14:49
Uses interface Endpoints to presents Pod and ExternalEntity in ToAddresses and
FromAddresses.
@antrea-bot
Copy link
Collaborator

Can one of the admins verify this patch?

@Dyanngg
Copy link
Contributor Author

Dyanngg commented Sep 25, 2020

superseded by #1084

@Dyanngg Dyanngg closed this Sep 25, 2020
@Dyanngg Dyanngg deleted the anp-ctrl branch September 25, 2020 17:35
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.

5 participants