Uploaded image for project: 'OpenShift Core Networking'
  1. OpenShift Core Networking
  2. CORENET-6304

MultiNetworkPolicy doesn't have the same validations as NetworkPolicy

XMLWordPrintable

    • Icon: Story Story
    • Resolution: Unresolved
    • Icon: Undefined Undefined
    • None
    • None
    • Plumbing
    • None
    • Quality / Stability / Reliability
    • False
    • Hide

      None

      Show
      None
    • False
    • None
    • None
    • None
    • None

      Description of problem:

      MNP CRD is a copy of the NetworkPolicy, but since NetworkPolicy is a core API, it has extra validations in the api-server, like https://github.com/kubernetes/kubernetes/blob/master/pkg/apis/networking/validation/validation.go.
      Recent testing of the `endPort` field emphasized some of the validation differences. But this problem is more generic and should probably be fixed for the whole API rather than one field.
      This could be fixed in the API by using CEL validations, but that would be a breaking change and would require a new API version.
      Another option is to put the validation burden on the implementations, but considering MNP doesn't have a status field, there is no place to report an error (status field could be added though).
          
      Somewhat related discussion upstream https://github.com/k8snetworkplumbingwg/multi-networkpolicy/issues/26 

      Version-Release number of selected component (if applicable):

          

      How reproducible:

          

      Steps to Reproduce:

          1.
          2.
          3.
          

      Actual results:

          

      Expected results:

          

      Additional info:

          

              sdn-team-bot sdn-team bot
              npinaeva@redhat.com Nadia Pinaeva (Inactive)
              None
              None
              Weibin Liang Weibin Liang
              None
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated: