Forum Discussion

hebinhb's avatar
hebinhb
Frequent Visitor
2 years ago

How to understand the meaning when combining keywords "not" and "required"?

When I check one of 3GPP yaml spec:TS29510_Nnrf_NFManagement.yaml Swagger Editor (jdegre.github.io), I read the combination of the not and required keywords below to imply that, for example, a NotificationData object the Profile property is not required to have an allowedPlmns, i.e. it is optional. However allowedPlmns is already optional in the definition of Profile so should be interpreted as not being allowed to be there instead.

 

 

 

 

    NotificationData:
      description: Data sent in notifications from NRF to subscribed NF Instances
      type: object
      required:
        - event
        - nfInstanceUri
 ...
      properties:
        event:
          $ref: '#/components/schemas/NotificationEventType'
        nfInstanceUri:
          $ref: 'TS29571_CommonData.yaml#/components/schemas/Uri'
        nfProfile:
          allOf:
            - $ref: '#/components/schemas/NFProfile'
            - not:
                required: [ interPlmnFqdn ]
            - not:
                required: [ allowedPlmns ]
            - not:
                required: [ allowedSnpns ]
            - not:
                required: [ allowedNfTypes ]
            - not:
                required: [ allowedNfDomains ]
            - not:
                required: [ allowedNssais ]

 

 

 

So my question those "not required" parameters here should be interpreted as

  1. 1 they are not allowed to appear in the notification. It's WRONG if they exist;
  2. 2 Or, they are not required, it could be acceptable if they exist.

Which interpretion is correct?

  1.  
No RepliesBe the first to reply