diff --git a/.github/dependabot.yml b/.github/dependabot.yml index cb571983d463..ab14ec838238 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -25,25 +25,14 @@ updates: schedule: interval: "daily" open-pull-requests-limit: 20 - ignore: - # Locked test resources for pinot-spi/src/test/java/org/apache/pinot/spi/plugin/ClassLoaderTest.java. - # These artifacts are pinned in pinot-spi/pom.xml (maven-dependency-plugin artifactItems) because - # ClassLoaderTest asserts plugin realm isolation against known artifact contents. Dependabot's - # `versions` filter is matched against the *target* version of an update, so we use range filters - # (">= ") to block every bump to a newer version for these coordinates. - # - # Caveat: these rules apply repo-wide by coordinate. pinot-dropwizard / pinot-yammer / - # com.yammer.metrics:metrics-core are not referenced anywhere else, so locking them is safe. - # commons-io:commons-io is also consumed in the top-level pom.xml at a newer version, so it is - # intentionally NOT locked here; Dependabot may still open PRs that also modify the hardcoded - # 2.11.0 in pinot-spi/pom.xml — reviewers must revert that part manually (see the DO NOT BUMP - # comment next to the 2.11.0 entry in pinot-spi/pom.xml). - - dependency-name: "org.apache.pinot:pinot-dropwizard" - versions: [">= 0.10.1"] - - dependency-name: "org.apache.pinot:pinot-yammer" - versions: [">= 0.10.1"] - - dependency-name: "com.yammer.metrics:metrics-core" - versions: [">= 2.1.6"] + # No `ignore` rules needed for the ClassLoaderTest pinned test fixtures + # (pinot-dropwizard, pinot-yammer, commons-io, com.yammer.metrics:metrics-core). + # Those fixtures are resolved by pinot-spi/pom.xml via maven-dependency-plugin's + # `dependency:get` goal using single-string groupId:artifactId:version + # parameters — Dependabot's Maven updater scans structured groupId+artifactId+version + # triples inside , , and blocks, not single-string + # values in plugin configuration, so the pinned coordinates are invisible + # to Dependabot and no ignore rule is required. - package-ecosystem: "npm" directory: "/pinot-controller/src/main/resources" diff --git a/pinot-spi/pom.xml b/pinot-spi/pom.xml index fca66c6cc345..50cb2c700dd5 100644 --- a/pinot-spi/pom.xml +++ b/pinot-spi/pom.xml @@ -50,90 +50,141 @@ org.apache.maven.plugins maven-dependency-plugin - - - copy-pinot-plugins - + DO NOT replace these versions with ${project.version}, as the test depends on the presence + (and absence) of specific classes in those exact jars. DO NOT BUMP the hardcoded versions + below — they are deliberately frozen test fixtures. + + Why dependency:get with a single-string instead of blocks? + Dependabot's Maven updater scans , , and blocks for + structured groupId+artifactId+version triples; it does NOT parse single-string + ... values inside plugin configuration. Using here + gave Dependabot a coordinate to "upgrade" and produced repeated noise PRs (e.g. #18331). + For coordinates that are not consumed elsewhere in the repo, a `versions: [">= "]` + ignore rule in .github/dependabot.yml would suppress those PRs, but commons-io is also + consumed at a newer version in the top-level pom.xml, so a repo-wide ignore would block + legitimate upgrades. To keep the mechanism uniform across all the pinned fixtures (and + defensive against any future shared-coordinate situation), we route every fixture through + dependency:get + antrun copy/unzip from ${settings.localRepository}. + + dependency:get goes through Maven's normal resolution chain (local cache, configured + mirrors, authenticated repos, SHA-1 checksum validation), so offline/mirrored builds keep + working and artifact integrity is verified. + + The companion antrun execution `stage-classloadertest-fixtures` copies the resolved jars + from ${settings.localRepository} into target/test-classes/plugins/ with the literal + filenames ClassLoaderTest asserts on (see CodeSource.getLocation().getPath().endsWith(...) + checks in the test). + --> + + + fetch-classloadertest-fixture-pinot-dropwizard-shaded generate-test-resources - copy + get - - - org.apache.pinot - pinot-dropwizard - 0.10.0 - shaded - ${project.build.testOutputDirectory}/plugins/pinot-dropwizard - - - org.apache.pinot - pinot-yammer - 0.10.0 - shaded - ${project.build.testOutputDirectory}/plugins/pinot-yammer - - - org.apache.pinot - pinot-yammer - 0.10.0 - shaded - ${project.build.testOutputDirectory}/plugins/pinot-shaded-yammer - - - commons-io - commons-io - 2.11.0 - ${project.build.testOutputDirectory}/plugins/assemblybased-pinot-plugin - - - com.yammer.metrics - metrics-core - 2.1.5 - ${project.build.testOutputDirectory}/plugins/assemblybased-pinot-plugin - - + org.apache.pinot:pinot-dropwizard:0.10.0:jar:shaded + false - unpack-pinot-plugins - generate-test-resources - unpack + run - - - org.apache.pinot - pinot-yammer - 0.10.0 - ${project.build.testOutputDirectory}/plugins/assemblybased-pinot-plugin/classes - - + + + + + + + + + + + + + + + + +