amazon-network-policy-controller-k8s icon indicating copy to clipboard operation
amazon-network-policy-controller-k8s copied to clipboard

update PE to support a new ns scoped pods field and status conditions

Open haouc opened this issue 1 year ago • 0 comments

What type of PR is this?

feature Which issue does this PR fix: This PR adds a new Spec field to support NS scoped pods and Conditions into Status to support PE objects' states tracking.

What does this PR do / Why do we need it: We need them to support NA features and expose critical state changes of PE objects to customers.

If an issue # is not available please add steps to reproduce and the controller logs:

Testing done on this change:

new Spec field

"allPodsInNamespace": true,

conditions

Status:
  Conditions:
    Last Transition Time:  2024-01-26T00:48:19Z                      <--- condition is set/updated when the PE is binpacked
    Message:               binpacked network policy endpoint slices on Ingress - false, Egress - false, PodSelector - true with RV 9290751
    Reason:                PEBinPacked
    Status:                True
    Type:                  PackedPolicyEndpoint
    Last Transition Time:  2024-01-26T00:33:44Z                      <--- condition is set when the PE is created
    Message:               object is awaiting reconciliation
    Reason:                AwaitingReconciliation
    Status:                Unknown
    Type:                  Ready

Automation added to e2e:

Will this PR introduce any new dependencies?:

Will this break upgrades or downgrades. Has updating a running cluster been tested?: This shouldn't support downgraded PE CRD. Upgrading is supported and worked in test clusters.

Does this PR introduce any user-facing change?:

Yes. PE objects' states are exposed.


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

haouc avatar Jan 25 '24 02:01 haouc