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

RATIS-2210. Reduce duplication in CI workflow #1195

Merged
merged 4 commits into from
Dec 24, 2024

Conversation

adoroszlai
Copy link
Contributor

What changes were proposed in this pull request?

Reduce duplication in CI workflow.

  • Create a reusable workflow (check.yml) for a single, generic check.
  • Refactor existing checks in post-commit.yml (except coverage, which needs extra tokens) to call the reusable one. Minor changes as implementation detail:
    • Separate repro check from compile.
    • Create separate compile.sh for compile check.
  • Group simple checks (author, checkstyle, etc.) with matrix strategy as basic.
  • Split existing post-commit.yml into:
    • ci.yml, has most of the logic, is triggered by workflow call
    • post-commit.yml, triggered by push/pull_request, simply calls ci.yml
      This split is not strictly required, but I think the way GitHub UI displays workflow runs is better this way (runs: before / after for comparison).

https://issues.apache.org/jira/browse/RATIS-2210

How was this patch tested?

CI:
https://github.com/adoroszlai/ratis/actions/runs/12452887900

@adoroszlai adoroszlai added the CI label Dec 22, 2024
@adoroszlai adoroszlai self-assigned this Dec 22, 2024
Copy link
Contributor

@szetszwo szetszwo left a comment

Choose a reason for hiding this comment

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

+1 the change looks good.

@adoroszlai adoroszlai merged commit 6fd8ae1 into apache:master Dec 24, 2024
13 checks passed
@adoroszlai adoroszlai deleted the RATIS-2210 branch December 24, 2024 18:22
@adoroszlai
Copy link
Contributor Author

Thanks @szetszwo for the review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants