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

[OAS] Remove elastic-api-version from stateful spec #197968

Conversation

jloleysens
Copy link
Contributor

Summary

Remove mention of elastic-api-version from the stateful spec bundle (for now just a simple sed command).

Additionally:

  • Simplified the set of commands: make api-docs now does everything including applying overlays to get the final bundles
  • Removed the *.new.* workflows, happy to bring them back but they seemed a bit redundant and we can always look at the contents of makefile to recreate them on demand

These also fix the current .buildkite/scripts/steps/openapi_bundling/final_merge.sh running in CI that assumed everything was being done to create the "final" merge.

@jloleysens jloleysens added Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc release_note:skip Skip the PR/issue when compiling release notes v9.0.0 Feature:OAS Work or issues related to Core-provided mechanisms for generating OAS v8.16.0 backport:version Backport to applied version labels v8.17.0 labels Oct 28, 2024
@jloleysens jloleysens requested a review from lcawl October 28, 2024 11:01
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-core (Team:Core)

@npx @redocly/cli bundle output/kibana.tmp4.yaml --ext yaml -o output/kibana.new.yaml
@npx @redocly/cli bundle output/kibana.serverless.tmp4.yaml --ext yaml -o output/kibana.serverless.yaml
@npx @redocly/cli bundle output/kibana.tmp4.yaml --ext yaml -o output/kibana.yaml
@sed -i '' -e 's/; Elastic-Api-Version=[0-9]\{4\}-[0-9]\{2\}-[0-9]\{2\}//g' output/kibana.yaml
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@lukeelmers this is where we remove the Elastic-Api-Version from the stateful bundles. For now I think this should be OK as, in future, we might choose to introduce them there more formally.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks! does it need to be there in serverless too... it feels like we could remove it in both places, right? (since it looks like this is the one that's in the content-type which afaik nobody needs to actually include)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

my concern for stateful is that it will be confusing as we have not formally/publicly explained how the dual date/stack versioning works there.

my concern for serverless is that it is just redundant and also a bit confusing since content-type does not dictate api version (unless I missed something)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

my concern for serverless is that it is just redundant and also a bit confusing since content-type does not dictate api version (unless I missed something)

My understanding is it is intended to be used for grouping our serverless versions. Until that strategy changes from docs side I don't think we should remove it for now.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Relates to elastic/docs-content#142 As soon as we start having multiple valid in-support elastic-api-version values in stateful or serverless, we'll need to be able to differentiate their impact on the requests and responses.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

... we have not formally/publicly explained how the dual date/stack versioning works there.

Whenever we're ready to document that, it can be added to the API docs in a topic similar to https://www.elastic.co/docs/api/doc/kibana/topic/topic-kibana-spaces, which we add via

@jloleysens jloleysens requested a review from a team as a code owner October 28, 2024 15:34
@jloleysens
Copy link
Contributor Author

@elasticmachine merge upstream

@elasticmachine
Copy link
Contributor

elasticmachine commented Nov 5, 2024

💔 Build Failed

Failed CI Steps

Test Failures

  • [job] [logs] FTR Configs #35 / Cloud Security Posture Security Alerts Page - Graph visualization should render graph visualization
  • [job] [logs] FTR Configs #35 / Cloud Security Posture Security Alerts Page - Graph visualization should render graph visualization
  • [job] [logs] Jest Tests #1 / TableListView default columns should not display relative time for items updated more than 7 days ago
  • [job] [logs] Jest Tests #1 / TableListView default columns should not display relative time for items updated more than 7 days ago

Metrics [docs]

✅ unchanged

History

@lcawl
Copy link
Contributor

lcawl commented Nov 5, 2024

I think this also has some overlap with the info in elastic/docs-content#141

@jloleysens jloleysens marked this pull request as draft November 6, 2024 14:22
@elasticmachine
Copy link
Contributor

🤖 Jobs for this PR can be triggered through checkboxes. 🚧

ℹ️ To trigger the CI, please tick the checkbox below 👇

  • Click to trigger kibana-pull-request for this PR!
  • Click to trigger kibana-deploy-project-from-pr for this PR!

@jloleysens jloleysens closed this Dec 4, 2024
@jloleysens
Copy link
Contributor Author

Superseded by #202923

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:version Backport to applied version labels Feature:OAS Work or issues related to Core-provided mechanisms for generating OAS release_note:skip Skip the PR/issue when compiling release notes Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc v8.16.0 v8.17.0 v9.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants