Drop unused/mis-scoped deps in sandbox plugins#21729
Draft
bowenlan-amzn wants to merge 1 commit into
Draft
Conversation
Per /Users/bowenlan/notes/Projects/mustang/build/audit-results:
analytics-backend-datafusion:
- Drop log4j-core compileOnly (PluginBuildPlugin provides it).
- Rescope arrow-memory-unsafe compileOnly → testRuntimeOnly: no main-code
use; unit tests need an AllocationManager via ServiceLoader under the flat
test classpath. Sibling plugins that declare compileOnly project(':plugins:arrow-base')
directly get arrow-memory-netty via OpenSearch's resolveableCompileOnly
wiring; datafusion goes through analytics-engine as middleman and misses
that edge.
parquet-data-format:
- Drop arrow-memory-unsafe testRuntimeOnly: arrow-base's api ships
arrow-memory-netty which satisfies ServiceLoader under test.
analytics-backend-lucene:
- Drop testRuntimeOnly guava + failureaccess: analytics-framework's
runtimeOnly guava leaks via api project dep onto this plugin's
runtimeClasspath, which testRuntimeClasspath extends.
- Drop testCompileOnly immutables value-annotations: no test usage,
stale comment.
Verified: precommit + test (all 3) + bundlePlugin for all 3. Plugin zips
byte-identical in content.
Signed-off-by: bowenlan-amzn <bowenlan23@gmail.com>
Contributor
PR Code Analyzer ❗AI-powered 'Code-Diff-Analyzer' found issues on commit 47441a0.
The table above displays the top 10 most important findings. Pull Requests Author(s): Please update your Pull Request according to the report above. Repository Maintainer(s): You can Thanks. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Dependency audit of sandbox plugins — remove unused declarations and fix mis-scoped ones.
log4j-core compileOnly(PluginBuildPlugin already provides it). Rescopearrow-memory-unsafefromcompileOnlytotestRuntimeOnly(needed by ServiceLoader under flat test classpath, not used in main code). Add WHY comment onjackson-datatype-jdk8(substrait-core<clinit>loadsJdk8Module).testRuntimeOnly guava + failureaccess(already ontestRuntimeClasspathviatestImplementation analytics-engine→api analytics-framework→runtimeOnly guava). DroptestCompileOnly immutables value-annotations(zero test usage, stale comment).Test plan
./gradlew :sandbox:plugins:analytics-backend-datafusion:precommit— PASS./gradlew :sandbox:plugins:analytics-backend-datafusion:test— PASS (all 200+ tests)./gradlew :sandbox:plugins:analytics-backend-lucene:precommit— PASS./gradlew :sandbox:plugins:analytics-backend-lucene:test— PASSdependencyInsightconfirms arrow-memory-unsafe and guava reachtestRuntimeClasspathvia correct paths