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

Support required NQ parameters #874

Open
donaldgray opened this issue Jun 27, 2024 · 0 comments
Open

Support required NQ parameters #874

donaldgray opened this issue Jun 27, 2024 · 0 comments
Labels
enhancement New feature or request orchestrator

Comments

@donaldgray
Copy link
Member

donaldgray commented Jun 27, 2024

#870 updated NQ parameter handling to align with how Deliverator handled them (ie all are optional but you must specify at least one).

The initial Protagonist implementation was to make every parameter be a required parameter. We should introduce a slightly new syntax that allows parameters to be marked as required. The syntax is to use the same p* format but add a trailing ! if it is required (e.g. p1!).

E.g.

  • s1=p1 would fail if no args were passed (despite it being p1 only as we need at least 1 arg)
  • s1=p1! would have same affect as above
  • s1=p1&s2=p2 would allow it to be called with /one or /one/two
  • s1=p1!&s2=p2 would be the same as above
  • s1=p1&s2=p2! would allow it to be called with /one/two only, /one would result in an error as the 2nd parameter is required.
  • s1=p1!&s2=p2!&s3=p3 accepts /one/two, or /one/two/three
  • s1=p1!&s2=p2&s3=p3! isn't valid - should this throw an exception on Create/Update?
@donaldgray donaldgray added enhancement New feature or request orchestrator labels Jun 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request orchestrator
Projects
None yet
Development

No branches or pull requests

1 participant