Skip to content

Apply the springfox-swagger2 upgrade from NoGuava again - #1286

Merged
timtebeek merged 1 commit into
mainfrom
tim/noguava-springfox-ungated
Oct 8, 2026
Merged

timtebeek merged 1 commit into
mainfrom
tim/noguava-springfox-ungated

Conversation

@timtebeek

Copy link
Copy Markdown
Member

The springfox-swagger2 upgrade added in f7b9ab3 lived in NoGuavaJava11's recipe list. Since #651 gated that recipe on HasJavaVersion: [11,), it can no longer edit pom.xml or build.gradle: HasJavaVersion judges every file, and build files never carry a JavaVersion marker, so they never pass the precondition. This moves the upgrade into the parent NoGuava recipe list, which only has Singleton; springfox 2.10 runs on Java 8, so it needs no Java version gate.

NoGuavaJava11 keeps HasJavaVersion rather than switching to HasMinimumJavaVersion: its code recipes need the per-file language level, and HasMinimumJavaVersion only marks files at the repository's lowest version, so Java 17 modules next to Java 11 ones would lose the Guava to JDK rewrites.

NoGuavaTest#upgradeSpringfoxThatStillUsesGuavaOptional covers the pom.xml upgrade and fails without this change.

…Java11

HasJavaVersion never marks pom.xml or build.gradle, which carry no
JavaVersion marker, so since NoGuavaJava11 gained its HasJavaVersion
precondition the springfox upgrade could no longer edit build files.
@timtebeek
timtebeek merged commit 4544a58 into main Oct 8, 2026
1 check passed
@timtebeek
timtebeek deleted the tim/noguava-springfox-ungated branch October 8, 2026 09:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant