Skip to content

ci: add dedicated RAT license check workflow for all PRs#3664

Merged
mbutrovich merged 4 commits intoapache:mainfrom
andygrove:ci/rat-check-all-prs
Mar 11, 2026
Merged

ci: add dedicated RAT license check workflow for all PRs#3664
mbutrovich merged 4 commits intoapache:mainfrom
andygrove:ci/rat-check-all-prs

Conversation

@andygrove
Copy link
Member

Summary

  • Add a new lightweight CI workflow (pr_rat_check.yml) that runs the Apache RAT license header check on all PRs, including docs-only changes

Problem

The existing build workflows (pr_build_linux, spark_sql_test, etc.) use paths-ignore to skip docs-only changes (matching docs/**, **.md, etc.). This also skips the RAT license check, which allowed files without Apache license headers to be merged via docs-only PRs (e.g., #3651 introduced SVG files without headers, breaking CI for unrelated PRs like #3661).

Solution

A dedicated workflow that:

  • Has no path filters — runs on every PR and push to main
  • Only runs ./mvnw -B -N apache-rat:check (the -N flag skips child module builds)
  • Uses a minimal setup (just Java 11, no Rust/Spark needed)
  • Completes in seconds since it only checks license headers

Test plan

  • The workflow itself will be validated by CI on this PR

The existing build workflows (pr_build_linux, spark_sql_test, etc.)
use paths-ignore to skip docs-only changes, which also skips the RAT
license header check. This allowed files without Apache license headers
to be merged via docs-only PRs.

Add a lightweight dedicated workflow that runs RAT on all PRs with no
path filters. Uses -N (non-recursive) to skip child module builds since
RAT scans the full directory tree from the parent pom.
@mbutrovich
Copy link
Contributor

mbutrovich commented Mar 11, 2026

This might be a good opportunity to start using ubuntu-slim. For context, apache/iceberg-rust#2187

ubuntu-slim is a new cost-efficient runner to fit lightweight jobs. We can use this to save ASF infra usage (if possible).

By lightweight I mean jobs that run for less than a minute and are not easily affected by other concurrently running jobs on the same host.

This topic was raised in the Apache ORC project and later adopted by iceberg-cpp. We believe it could also benefit other projects under the Apache Iceberg umbrella.

Refs:

@mbutrovich
Copy link
Contributor

mbutrovich commented Mar 11, 2026

I opened an issue to track broader ubuntu-slim use. #3665

Copy link
Contributor

@mbutrovich mbutrovich left a comment

Choose a reason for hiding this comment

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

Thanks @andygrove!

@mbutrovich mbutrovich merged commit e188c66 into apache:main Mar 11, 2026
139 of 140 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants