Skip to content

GEODE-10465: Fix RAT failures by adding missing **/bin/** exclusion#7939

Merged
sboorlagadda merged 1 commit into
developfrom
feature/GEODE-10479-rat-exclusion-bin
Oct 3, 2025
Merged

GEODE-10465: Fix RAT failures by adding missing **/bin/** exclusion#7939
sboorlagadda merged 1 commit into
developfrom
feature/GEODE-10479-rat-exclusion-bin

Conversation

@sboorlagadda

Copy link
Copy Markdown
Member

This commit addresses RAT (Release Audit Tool) failures that occur when IDE-generated bin/ directories are present in the workspace. The issue was caused by a missing exclusion pattern that should have been included during the build system refactoring in May 2022.

Root Cause Analysis:

  • In April 2017, /bin/ exclusion was added to RAT configuration (commit 4a09e88)
  • Later removed due to legitimate bin/ folders in source tree (commit 39c72b2)
  • During May 2022 build system refactoring (commit 509c0c6), the RAT configuration was moved from gradle/rat.gradle to build-tools/scripts/src/main/groovy/geode-rat.gradle
  • The /bin/ exclusion pattern was inadvertently omitted from the new configuration

Problem:

  • IDEs (Eclipse, IntelliJ) generate bin/ directories containing compiled classes, test resources, and other build artifacts
  • These files lack Apache license headers and cause RAT failures
  • The .gitignore already excludes bin/ folders, indicating they are build artifacts

Solution:

  • Add '/bin/' exclusion pattern to RAT configuration
  • This prevents RAT from scanning IDE-generated build artifacts
  • Consistent with existing exclusions for other build directories (/build/)
  • Aligns with .gitignore patterns that already exclude bin/ folders

Testing:

  • Verified RAT passes with and without bin/ directories present
  • Confirmed exclusion works for files without license headers in bin/ folders
  • No impact on legitimate source files that require license headers

This fix prevents future RAT failures for developers using IDEs that generate bin/ directories during normal development workflow.

For all changes, please confirm:

  • Is there a JIRA ticket associated with this PR? Is it referenced in the commit message?
  • Has your PR been rebased against the latest commit within the target branch (typically develop)?
  • Is your initial contribution a single, squashed commit?
  • Does gradlew build run cleanly?
  • Have you written or updated unit tests to verify your changes?
  • If adding new dependencies to the code, are these dependencies licensed in a way that is compatible for inclusion under ASF 2.0?

…attern

This commit addresses RAT (Release Audit Tool) failures that occur when IDE-generated
bin/ directories are present in the workspace. The issue was caused by a missing
exclusion pattern that should have been included during the build system refactoring
in May 2022.

Root Cause Analysis:
- In April 2017, **/bin/** exclusion was added to RAT configuration (commit 4a09e88)
- Later removed due to legitimate bin/ folders in source tree (commit 39c72b2)
- During May 2022 build system refactoring (commit 509c0c6), the RAT configuration
  was moved from gradle/rat.gradle to build-tools/scripts/src/main/groovy/geode-rat.gradle
- The **/bin/** exclusion pattern was inadvertently omitted from the new configuration

Problem:
- IDEs (Eclipse, IntelliJ) generate bin/ directories containing compiled classes,
  test resources, and other build artifacts
- These files lack Apache license headers and cause RAT failures
- The .gitignore already excludes bin/ folders, indicating they are build artifacts

Solution:
- Add '**/bin/**' exclusion pattern to RAT configuration
- This prevents RAT from scanning IDE-generated build artifacts
- Consistent with existing exclusions for other build directories (**/build/**)
- Aligns with .gitignore patterns that already exclude bin/ folders

Testing:
- Verified RAT passes with and without bin/ directories present
- Confirmed exclusion works for files without license headers in bin/ folders
- No impact on legitimate source files that require license headers

This fix prevents future RAT failures for developers using IDEs that generate
bin/ directories during normal development workflow.

@JinwooHwang JinwooHwang left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks for taking care of this issue, @sboorlagadda . LGTM.

@raboof

raboof commented Oct 2, 2025

Copy link
Copy Markdown
Member
  • The .gitignore already excludes bin/ folders, indicating they are build artifacts

Hmm, ideally RAT should already ignore all files that are in .gitignore , I wonder why that doesn't seem to be working for Geode. I suppose it may be because the gradle-rat plugin is still at an earlier rat version (eskatos/creadur-rat-gradle#28)

@sboorlagadda

Copy link
Copy Markdown
Member Author
  • The .gitignore already excludes bin/ folders, indicating they are build artifacts

Hmm, ideally RAT should already ignore all files that are in .gitignore , I wonder why that doesn't seem to be working for Geode. I suppose it may be because the gradle-rat plugin is still at an earlier rat version (eskatos/creadur-rat-gradle#28)

Awesome! Thanks for the heads up. I will wait for 0.17 release and upgrade it. But for now we can go ahead and include this exclusion as it is annoying to deal with in local development

@sboorlagadda

Copy link
Copy Markdown
Member Author

Created https://issues.apache.org/jira/browse/GEODE-10501 to track the migration to 0.17

@sboorlagadda sboorlagadda merged commit 7ec0626 into develop Oct 3, 2025
15 checks passed
@sboorlagadda sboorlagadda deleted the feature/GEODE-10479-rat-exclusion-bin branch October 3, 2025 00:49
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.

3 participants