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

ci: When models change, dump gql schema #1671

Merged
merged 23 commits into from
Mar 29, 2024
Merged

ci: When models change, dump gql schema #1671

merged 23 commits into from
Mar 29, 2024

Conversation

Yaminyam
Copy link
Member

@Yaminyam Yaminyam commented Oct 30, 2023

To easily identify when the graphql schema has changed, a dump is created when files in the models path are modified.

@github-actions github-actions bot added the size:M 30~100 LoC label Oct 30, 2023
@Yaminyam Yaminyam added the skip:changelog Make the action workflow to skip towncrier check label Oct 30, 2023
@github-actions github-actions bot added the comp:manager Related to Manager component label Oct 30, 2023
Copy link
Member

@achimnol achimnol left a comment

Choose a reason for hiding this comment

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

  • Let's generalize the workflow filename and the top-level name key to update-api-schema.
  • Let's rename the job to graphql.

This will give a concise yet extensible check name "update-api-schema / graphql" where we could add "update-api-schema / rest" in the future.

  • Let's also migrate the OpenAPI XML generator (./py -m ai.backend.manager.openapi) to mgr openapi show command.

@github-actions github-actions bot added size:L 100~500 LoC and removed size:M 30~100 LoC labels Oct 30, 2023
@achimnol
Copy link
Member

achimnol commented Nov 2, 2023

As of #1686, we should use mgr api dump-gql-schema instead of mgr gql show.
We also don't need to populate dummy manager.toml.

@github-actions github-actions bot added size:M 30~100 LoC and removed size:L 100~500 LoC labels Nov 7, 2023
.github/workflows/update-api-schema.yml Outdated Show resolved Hide resolved
.github/workflows/update-api-schema.yml Outdated Show resolved Hide resolved
@github-actions github-actions bot added size:L 100~500 LoC and removed size:M 30~100 LoC labels Nov 27, 2023
@Yaminyam
Copy link
Member Author

Yaminyam commented Dec 4, 2023

  • Let's also migrate the OpenAPI XML generator (./py -m ai.backend.manager.openapi) to mgr openapi show command.

As with graphql, it was decided to replace this with mgr api dump-openapi.

@github-actions github-actions bot added comp:webserver Related to Web Server component size:XL 500~ LoC and removed size:L 100~500 LoC labels Dec 22, 2023
@achimnol
Copy link
Member

achimnol commented Dec 27, 2023

Please resolve the merge conflict. I think the conflict is due to the formatting rule change in #1771, so you may git checkout --ours, check if there are any missing attributes added in the main branch, and reformat it again using pants fix and pants fmt. See #1771's description about the update guide.

@Yaminyam Yaminyam marked this pull request as draft December 27, 2023 13:52
@Yaminyam Yaminyam marked this pull request as ready for review January 8, 2024 07:32
@kyujin-cho kyujin-cho added this pull request to the merge queue Mar 29, 2024
Merged via the queue into main with commit 50fe965 Mar 29, 2024
26 checks passed
@kyujin-cho kyujin-cho deleted the ci/graphql-updated branch March 29, 2024 04:11
@Yaminyam Yaminyam linked an issue Mar 29, 2024 that may be closed by this pull request
2 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
comp:manager Related to Manager component comp:webserver Related to Web Server component size:XL 500~ LoC skip:changelog Make the action workflow to skip towncrier check
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Enhance GraphQL documentation
3 participants