efegokdemir opened a new pull request, #2192: URL: https://github.com/apache/maven-resolver/pull/2192
Closes #2156. The artifact and metadata resolvers currently evaluate remote repository filters before checking whether a repository policy enables access for the requested artifact or metadata. With prefix filtering enabled, this can trigger repository probes for requests that cannot use that repository. Skip artifact filtering when the relevant release or snapshot policy is disabled. For metadata, determine the enabled source repositories first and skip filtering when there are none. Descriptor-repository prefix auto-discovery remains out of scope. Regression tests cover disabled policies in artifact and metadata resolution. Both failed against the unmodified implementation and pass with this change. Validation: - `mvn -pl maven-resolver-impl -am -Dtest=DefaultArtifactResolverTest,DefaultMetadataResolverTest -Dsurefire.failIfNoSpecifiedTests=false test` — 40 tests passed. - `mvn -pl maven-resolver-impl -am test` — 585 tests passed, 5 skipped. - `mvn -pl maven-resolver-impl -am spotless:check` — passed. - `git diff --check` — passed. --- - [x] I hereby declare this contribution to be licensed under the [Apache License Version 2.0, January 2004](https://www.apache.org/licenses/LICENSE-2.0) - [ ] I hereby declare that I have filed an [Apache Individual Contributor License Agreement](https://www.apache.org/licenses/icla.pdf). -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
