Summary
Upgrade the Maven resolver stack used by the plugin integration test harness (agent-module/plugins-test-module/plugins-test).
maven-resolver 1.6.3 -> 1.9.27
maven-core (maven-resolver-provider, maven-model-builder, ...) 3.8.8 -> 3.9.16, which is the Maven release built against resolver 1.9.27
Changes
- Replace the
DefaultServiceLocator wiring (MavenRepositorySystemUtils.newServiceLocator(), deprecated in resolver 1.9 and removed in 2.0) with RepositorySystemSupplier from maven-resolver-supplier. The supportRemote=false mode is kept by overriding getTransporterFactories to drop the HTTP transporter.
- Copy the JVM system properties into the
RepositorySystemSession. MavenRepositorySystemUtils.newSession() in provider 3.8 did this, 3.9 does not. Without java.version the model builder fails the <jdk> profile activation of every POM it reads (pinpoint parent POM, dropwizard metrics parent POM, ...). Because the descriptor policy ignores invalid descriptors, the failure is silent and every dependency resolves to the root artifact only, so the plugin test class loader ends up with pinpoint-plugins-test.jar alone and fails with NoClassDefFoundError: com/navercorp/pinpoint/profiler/context/module/DefaultApplicationContext. Restoring the copy also restores the ConfigurationProperties.CONNECT_TIMEOUT / REQUEST_TIMEOUT session config that the suite injects through system properties.
- Remove the unused
maven-resolver-transport-wagon and maven-resolver-transport-classpath dependencies. Only the file and http transporters are wired.
- Add a regression test that checks transitive dependencies are actually resolved.
Summary
Upgrade the Maven resolver stack used by the plugin integration test harness (
agent-module/plugins-test-module/plugins-test).maven-resolver1.6.3 -> 1.9.27maven-core(maven-resolver-provider, maven-model-builder, ...) 3.8.8 -> 3.9.16, which is the Maven release built against resolver 1.9.27Changes
DefaultServiceLocatorwiring (MavenRepositorySystemUtils.newServiceLocator(), deprecated in resolver 1.9 and removed in 2.0) withRepositorySystemSupplierfrommaven-resolver-supplier. ThesupportRemote=falsemode is kept by overridinggetTransporterFactoriesto drop the HTTP transporter.RepositorySystemSession.MavenRepositorySystemUtils.newSession()in provider 3.8 did this, 3.9 does not. Withoutjava.versionthe model builder fails the<jdk>profile activation of every POM it reads (pinpoint parent POM, dropwizard metrics parent POM, ...). Because the descriptor policy ignores invalid descriptors, the failure is silent and every dependency resolves to the root artifact only, so the plugin test class loader ends up withpinpoint-plugins-test.jaralone and fails withNoClassDefFoundError: com/navercorp/pinpoint/profiler/context/module/DefaultApplicationContext. Restoring the copy also restores theConfigurationProperties.CONNECT_TIMEOUT/REQUEST_TIMEOUTsession config that the suite injects through system properties.maven-resolver-transport-wagonandmaven-resolver-transport-classpathdependencies. Only the file and http transporters are wired.