Commit Graph

218 Commits (32397d7bfbb093339d32c1620625cd56f1cfb4c5)

Author SHA1 Message Date
Andy Wilkinson 9c9fbf400e Upgrade to Spring Java Format 0.0.29
Closes gh-28205
3 years ago
Andy Wilkinson 8c3820f87e Fix up-to-date checking of syncAppSource tasks
Previously, the project version was used while filtering the apps
source during syncing but it was not considered as an input to
the task. This could result in the syncing being skipped even though
the project's version had changed.

This commit introduces a new custom task to make the configuration
more declarative and to allow the necessary input configuration to be
done in a single place.

Closes gh-28197
3 years ago
Andy Wilkinson 3824512357 Tighten up build's task interdependencies
Closes gh-28103
3 years ago
Andy Wilkinson 273600bcdd Retain distinction between compile and runtime deps of optional deps
Previously, the optional configuration was added to the compile and
runtime classpaths of each source set and the the javadoc classpath
as well. This had a few disadvantages, the most notable of which is
that it meant that the configuration was ifrst resolved and then
the outcome of the resolution was added to the compile and runtime
classpaths. As a result, none of the attributes on the compile and
runtime classpaths were considered to influence variant selection.

This commit reworks the optional dependencies plugin so that the
compile and runtime classpaths of each source set are now configured
to extend from the optional configuration. This allows each
classpath configuration's attributes to influence the dependencies
that are selected from the optional configuration during resolution.
For example, when resolving the compile classpath, compile
dependencies (Usage.JAVA_API) will be selected and when resolving the
runtime classpath, runtime dependencies (Usage.JAVA_RUNTIME) will be
selected.

The above-described change means that runtime dependencies of an
optional dependencies will no longer leak into the compile classpath.
As a result of this, our Gradle plugin's test infrastructure has
been updated so that it no longer references runtime dependencies of
the Kotlin Gradle plugin at compile time.

Closes gh-27965
3 years ago
Andy Wilkinson 9f402f0428 Use snapshot rather than libs-snapshot when generating effective bom
Closes gh-27785
3 years ago
Andy Wilkinson ffbd28b60a Polish "Polish access modifiers for test classes"
See gh-27736
3 years ago
izeye 8a425dedfd Polish access modifiers for test classes
See gh-27736
3 years ago
Andy Wilkinson 0b7994a679 Polish "Use 2012 for copyright beginning year"
See gh-27734
3 years ago
izeye 07da144826 Use 2012 for copyright beginning year
See gh-27734
3 years ago
Andy Wilkinson 32c184e31c Revert changes made to work around JDK-8156584
Closes gh-26848
3 years ago
Andy Wilkinson ea6cb74ccf Ignore Spring Boot when finding dependency upgrades
Closes gh-27447
3 years ago
Andy Wilkinson 316d2cce89 Don't offer upgrade for version that is already aligned
See gh-27044
3 years ago
Phillip Webb a76e5c043e Update copyright year of changed files 3 years ago
Andy Wilkinson 4d694ddaa8 Fix bom plugin management versions
See gh-27044
3 years ago
Andy Wilkinson 363de4cfa5 Add dependency lock and constraint version alignment to Bomr
Closes gh-27044
3 years ago
Andy Wilkinson ac8c6a6fb7 Tune config of source and target compatilility with toolchain
See gh-26932
3 years ago
Andy Wilkinson 6e43dd879b Allow Eclipse to properly detect source and target compatibility
Previously, our conventions configured the source and target
compatibility on the project's JavaCompile tasks. This causes the
settings to be missed when importing the projects into Eclipse [1].

This commit updates the conventions to set the source and target
compatibility on the project-wide JavaPluginExtension. This allows
the Eclipse import to correctly detect and honour the settings.

Closes gh-26932

[1] https://github.com/eclipse/buildship/issues/978
3 years ago
Andy Wilkinson a1c5fcca58 Move common Asciidoctor configuration into our conventions
Closes gh-26620
3 years ago
Phillip Webb 14f578ed80 Merge branch '2.3.x' into 2.4.x
Closes gh-26670
4 years ago
Phillip Webb 39e3746cf6 Force Eclipse to use JavaSE-1.8 runtime
Add `EclipseConventions` to force the JavaSE-1.8 runtime to be applied
to the imported projects.

Closes gh-26669
4 years ago
Andy Wilkinson ad5ba2e414 Compile Kotlin code will all warnings treated as errors
Closes gh-26083
4 years ago
dreis2211 6179b99710 Remove add-opens workaround in ToolchainPlugin
See gh-26465
4 years ago
Stephane Nicoll a5cb9540ca Start building against Spring LDAP 2.3.4 snapshots
See gh-26393
4 years ago
Andy Wilkinson 75bb50bd02 Merge branch '2.3.x' into 2.4.x
Closes gh-26353
4 years ago
Andy Wilkinson deca737b01 Configure source and target compatibility at the task level
Closes gh-26350
4 years ago
Andy Wilkinson 4abd6b1387 Merge branch '2.3.x' into 2.4.x
Closes gh-26302
4 years ago
Andy Wilkinson 3cc1ed28ca Order test tasks to run after Checkstyle and formatting checks
Closes gh-26284
4 years ago
Andy Wilkinson 4417e16963 Merge branch '2.3.x' into 2.4.x
See gh-26260
4 years ago
Andy Wilkinson 3a3eb1bc31 Fix workaround for JDK-8156584
See gh-26252
4 years ago
Andy Wilkinson 097a436314 Merge branch '2.3.x' into 2.4.x
See gh-26260
4 years ago
Andy Wilkinson ecd1e536cc Refine workaround for JDK-8156584
The previous workaround worked but prevented caching of every test
task as the value of system property pointing to the custom security
properties file varied from build to build.

This commit refines the workaround to copy the file into the build
directory of the test task's project and reference it using a URL
that's relative to the task's working directory. This ensures that
the value of the system property doesn't change from build to build.

Closes gh-26252
4 years ago
Andy Wilkinson 9cd15a1360 Merge branch '2.3.x' into 2.4.x
Closes gh-26276
4 years ago
Andy Wilkinson 79ecf596ec Set path sensitivity when configuring additional task inputs
Previously a number of file- or directory-based task inputs were
configured with specifying their path sensitivity. This meant
that the default absolute path sensitivity was used. For caches
that are cacheable this would result in a cache miss when the
inputs were identical other than being located at a different
absolute path as they are when running a CI build vs a local build.

This commit updates the configuration of additional task inputs
to use relative path sensitivity. A property name for each input has
also been configured. This makes them easier to identify in build
scans.

Closes gh-26270
4 years ago
Andy Wilkinson 79d27344e0 Merge branch '2.3.x' into 2.4.x
Closes gh-26260
4 years ago
Andy Wilkinson 912c82e50d Work around https://bugs.openjdk.java.net/browse/JDK-8156584
sun.security.x509.AlgorithmId.get(String) isn't thread-safe and can
lead to null be returned for an algorithm that should be present.

This commit aims to work around this problem by avoiding the call
to AlgorithmId.get(String). It does so by configuring the
PKCS12 key protection algorithm to one that starts with
pbewithhmacsha (case insensitive). This short-circuits the logic
in PKCS12KeyStore.mapPBEAlgorithmToOID(String) and avoids the call to
AlgorithmId.get(String). Thanks again to @dreis2211 for the
suggestion.

The work around is only used when building with Java 8 as the problem
was fixed in Java 9.

Closes gh-26252
4 years ago
Phillip Webb fb3796dae8 Merge branch '2.3.x' into 2.4.x
Closes gh-26121
4 years ago
Phillip Webb fcb2210a87 Include optional shade plugin in published pom
Update `MavenPublishingConventions` to add a new `mavenOptional` feature
that allows us to declare optional dependencies that are also published
in the generated POM.

This change allows us to include the maven-shade-plugin in the
spring-boot-maven-plugin POM which fixes an issue with Eclipse m2e.

Fixes gh-21992
4 years ago
Andy Wilkinson 92f9cfaf25 Merge branch '2.3.x' into 2.4.x
See gh-25987
4 years ago
Andy Wilkinson 709db5582b Ensure that classes and resources are in place before documenting
Closes gh-25948
4 years ago
Andy Wilkinson 7cffb89647 Merge branch '2.3.x' into 2.4.x
Closes gh-25987
4 years ago
Andy Wilkinson d7b43a3c68 Filter out non-public classes when documenting auto-config classes
Fixes gh-25948
4 years ago
Andy Wilkinson 8cd08c3926 Merge branch '2.3.x' into 2.4.x
Closes gh-25899
4 years ago
Andy Wilkinson 7c8caf9ef5 Configure Kotlin compilation to use 1.3 apiVersion and languageVersion
Closes gh-25793
4 years ago
Andy Wilkinson 1e4f130133 Merge branch '2.3.x' into 2.4.x
Closes gh-25895
4 years ago
Andy Wilkinson 76f74482d4 Make Asciidoctor tasks run when Java examples are updated
Closes gh-25892
4 years ago
Phillip Webb 11a94ee6f0 Merge branch '2.3.x' into 2.4.x 4 years ago
Phillip Webb 82127fdaa3 Update copyright year of changed files 4 years ago
Andy Wilkinson 13dda798c5 Merge branch '2.3.x' into 2.4.x 4 years ago
Andy Wilkinson 2359b37e69 Polish 4 years ago
Andy Wilkinson 4865c23a41 Merge branch '2.3.x' into 2.4.x
Closes gh-25695
4 years ago