public icon indicating copy to clipboard operation
public copied to clipboard

Match-set-option across all conditions of policy-definition statement?

Open ianbarrere opened this issue 1 year ago • 0 comments

Hi,

I'm working on an implementation using OpenConfig routing-policy to define abstract policies for a variety of device platforms. I'm trying to figure out if there's a way to control any vs all type behavior for the cumulative conditions of a statement. I am aware of the "match-set-options" leaf for individual conditions, but this appears designed to control any vs all behavior within the set specified in that condition. Let's say I have a statement like this:

            - name: '100'
              conditions:
                match-prefix-set:
                  config:
                    prefix-set: PS_AS64512
                    match-set-options: ANY
                bgp-conditions:
                  match-community-set:
                    config:
                      community-set: CS_1
                      match-set-options: ALL
              actions:
                config:
                  policy-result: ACCEPT_ROUTE

As I understand it, the match-set-options specified refer to matching any prefix within the set PS_AS64512 and then all communities within the set CS_1, but what about the relationship between the two match-prefix-set and match-community-set conditions? Is it intended that multiple conditions in a single statement are evaluated as an all match, or is there any way to control that?

ianbarrere avatar Oct 25 '24 09:10 ianbarrere