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

Logical disjunction (aka "OR" operator) in conditions #424

Closed
4 tasks done
guicassolato opened this issue Sep 20, 2023 · 0 comments · Fixed by #427
Closed
4 tasks done

Logical disjunction (aka "OR" operator) in conditions #424

guicassolato opened this issue Sep 20, 2023 · 0 comments · Fixed by #427

Comments

@guicassolato
Copy link
Collaborator

guicassolato commented Sep 20, 2023

RFE: Add support for Logical disjunction (aka "OR" operator) in when conditions.

Possible steps for implementation

  • Add 2 fields to the JSONPattern (v1beta1) and PatternExpressionOrRef (v1beta2) types:
    All []JSONPattern / []PatternExpressionOrRef `json:"all,omitempty"`
    Any []JSONPattern / []PatternExpressionOrRef `json:"any,omitempty"`
    
  • Modify all internal Conditions field of the evaluators to a new type that withholds the new logical operation all and any
  • Modify the *AuthPipeline. evaluateConditions function to support the new operations – recursion will be needed
  • (Optional) Define a new pkg/conditions package for everything related to the implementation of conditions (types, interfaces and functions)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Status: To test
Development

Successfully merging a pull request may close this issue.

1 participant