Exclude logback-classic from generate-configprops plugin dependency - #687
Closed
ryanjbaxter wants to merge 1 commit into
Closed
ryanjbaxter wants to merge 1 commit into
ryanjbaxter wants to merge 1 commit into
Conversation
spring-cloud-build-docs is consumed via the jar-with-dependencies classifier, which already bundles a matched logback-classic/ logback-core pair. exec-maven-plugin's includePluginDependencies classpath merge also separately resolves the dependency's own unversioned logback-classic, landing an old, incompatible logback-classic/logback-core split across the uber jar and the separately-resolved thin jar. Depending on classpath ordering this can intermittently fail generate-configprops with: java.lang.NoSuchMethodError: 'java.lang.ClassLoader ch.qos.logback.core.util.Loader.systemClassloaderIfNull(java.lang.ClassLoader)' Excluding logback-classic (and transitively logback-core) forces the classpath to rely solely on the bundled, self-consistent pair. Same fix as #686 on 5.0.x, applied here preemptively since main has the identical fragile setup.
ryanjbaxter
force-pushed
the
fix/generate-configprops-logback-conflict-main
branch
from
September 17, 2026 20:25
e337b3e to
feb588c
Compare
Contributor
Author
|
Closing — this will be merged forward from 5.0.x (#686) instead. |
ryanjbaxter
deleted the
fix/generate-configprops-logback-conflict-main
branch
September 17, 2026 20:27
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
Preemptive
maincounterpart to #686.spring-cloud-config's5.0.xbranch hit an intermittent/reproducible CI failure in thegenerate-configpropsexec-maven-pluginexecution (https://github.com/spring-cloud/spring-cloud-config/actions/runs/35267039454/job/105356701618):spring-cloud-build-docsis consumed by this execution via thejar-with-dependenciesclassifier — a shaded uber jar that already bundles its own, self-consistentlogback-classic/logback-corepair. However,exec-maven-plugin'sincludePluginDependenciesclasspath merge also separately resolves the dependency's own unversionedlogback-classic(landing on an old, incompatible version), adding a second, conflicting copy of these classes to the classpath. Which copy wins for which class depends on classpath ordering, which isn't guaranteed stable across builds — hence the intermittent failures on5.0.x.mainhas the exact samegenerate-configpropsexecution structure, so it's exposed to the same risk even though it hasn't reproduced there yet.Fix
Exclude
ch.qos.logback:logback-classic(which transitively pullslogback-core) from thespring-cloud-build-docsplugin dependency declaration in thegenerate-configpropsexecution, so the classpath relies solely on the matched pair already bundled in the uber jar. Same change as #686.Test plan