-
Notifications
You must be signed in to change notification settings - Fork 102
Merge query_rule
and query_ruleset
namespaces into query_rules
#2656
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
Conversation
Following you can find the validation results for the APIs you have changed.
You can validate these APIs yourself by using the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for this! I believe having a single namespace is much better! I'm only wondering about the endpoint names defined in the JSON spec, as they are used in client calls. With this PR, taking get
as an example, here's how users will call those APIs:
Client call | API call |
---|---|
client.query_rules.query_ruleset_get(...) |
GET /query_rules/{ruleset_id} |
client.query_rules.query_rule_get(...) |
GET /query_rules/{ruleset_id}/_rule/{rule_id} |
The two issues I'm seeing are:
- Other APIs put the verb first, eg.
indices.put_mapping
orinference.put_model
- There's a repetition around
query_rule
What are your thoughts around using those names instead?
client.query_rules.get_ruleset(...)
client.query_rules.get_rule(...)
query_rule
and query_ruleset
namespaces into query_rules
😅 Yeah, those are cleaner, I'll update both PRs today. |
Following you can find the validation results for the APIs you have changed.
You can validate these APIs yourself by using the |
Following you can find the validation results for the APIs you have changed.
You can validate these APIs yourself by using the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! LGTM. I had to run git merge
locally as GitHub reported conflicts. (The actual git merge
did not have any conflicts.) And I ran make contrib
to fix the OpenAPI specs.
Moves the
query_rule
andquery_ruleset
namespaces into a single top levelquery_rules
namespace.Followup to #2639