-
Notifications
You must be signed in to change notification settings - Fork 65
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
[PROPOSAL] Refactor query parameter definitions for maintainability #783
Comments
@kolchfa-aws: To clarify, you're saying keep the schema reference within individual namespaces the same, but remove the descriptions so it uses the |
Note that even though most are identical, There are subtle differences in what set of values is allowed in |
Yes, have one common description for all of the same parameters and generate the valid values for documentation based on the enum (I am assuming that the subtle differences are reflected in the spec). |
@kolchfa-aws and @nhtruong: I'll try this out locally this afternoon. @nhtruong, would this affect the |
@nhtruong I think we'd need to add logic for populating valid enum values so it spits them out in the following format:
|
Performed a small local test according to @kolchfa-aws example. It passes. I would be curious to see how this affects the output of the Furthermore, although it would be tempting to identify as many common parameters and replace as many as we can in a single PR, I would suggest a slower approach per namespace file. Doing so would help us account for the following:
|
Yeah that can be done. I'll take a crack at it later this week. |
What/Why
expand_wildcards
is shared by several APIs, including several CAT APIs. Some of the CAT APIs define their own descriptions for this parameter, while the description should be part of the common schema.expand_wildcards
), the description should not contain the valid parameter values. Rather, these can be generated from the schema.For reference, here's the common schema for
expand_wildcards
:This proposal is to make it as follows:
And remove descriptions from individual APIs like CAT indices:
What problems are you trying to solve?
Improve maintainability of the spec
The text was updated successfully, but these errors were encountered: