Commit Graph

1603 Commits

Author SHA1 Message Date
Stephane Nicoll 559af275a4 Merge branch '2.3.x' into 2.4.x
Closes gh-26405
2021-05-07 09:14:35 +02:00
Sach Nguyen afa77b8253 Fix wrong reference to Cassandra in DockerImageNames#couchbase
See gh-26399
2021-05-07 09:12:43 +02:00
Andy Wilkinson fe696ee22a Merge branch '2.3.x' into 2.4.x
Closes gh-26396
2021-05-06 20:11:59 +01:00
Andy Wilkinson ef9e3bafff Test our Gradle plugin against 6.9-rc-2
Closes gh-26395
2021-05-06 20:10:54 +01:00
Andy Wilkinson f7fae8f0f2 Merge branch '2.3.x' into 2.4.x
Closes gh-26364
2021-05-05 09:52:53 +01:00
Andy Wilkinson b3275c5647 Align productionRuntimeClasspath with runtimeClasspath
Fixes gh-25798
2021-05-05 09:52:44 +01:00
Andy Wilkinson c0fe23181c Merge branch '2.3.x' into 2.4.x
Closes gh-26329
2021-04-30 16:55:10 +01:00
Andy Wilkinson 94ca2d1e78 Test the Gradle plugin against Gradle 6.9-rc-1
Closes gh-26267
2021-04-30 16:52:52 +01:00
Scott Frederick 17fa215cf5 Merge branch '2.3.x' into 2.4.x
Closes gh-26312
2021-04-29 15:33:33 -05:00
Scott Frederick c37b9b8a8e Use layout configuration in Maven build-image goal
This commit changes the Maven build-image goal to honor the `layout` and
`layoutFactory` parameters to ensure that the archive content sent to the
builder is the same as is used by the `repackage` goal to build the
archive file.

Fixes gh-26216
2021-04-29 15:03:08 -05:00
Andy Wilkinson 94519c33b1 Merge branch '2.3.x' into 2.4.x
Closes gh-26300
2021-04-29 11:36:15 +01:00
Andy Wilkinson ef5fbb0669 Configure bootBuildImage's targetJavaVersion using a provider
Previously, the targetJavaVersion property of bootBuildImage was set
using the project's target compatibility directly. This meant that
property's value would reflect the configured target compatibility at
the time of the task's creation and any subsequent changes to the
target compatibility would be missed.

This commit updates the registration of the bootBuildImage task to set
the value of the targetJavaVersion property using a provider. This
indirection means that the project's target compatibility isn't read
until the value of the targetJavaVersion is read, allowing any changes
to the target compatibility to be picked up even if they're made after
the bootBuildImage task has been created.

Fixes gh-26297
2021-04-29 11:36:03 +01:00
Stephane Nicoll 52994027f4 Fix checkstyle violation 2021-04-28 15:14:33 +02:00
Stephane Nicoll 05b09907e0 Merge branch '2.3.x' into 2.4.x
Closes gh-26275
2021-04-28 14:12:35 +02:00
Stephane Nicoll d610f3c2ff Polish "Fix ordering of metadata entries"
See gh-26230
2021-04-28 14:07:37 +02:00
Dmitry Pavlov 3e34b0a60a Fix ordering of metadata entries
This commit provides a consistent ordering for groups that share the
same configuration property prefix.

See gh-26230
2021-04-28 14:07:37 +02:00
Stephane Nicoll d98fe36b88 Merge branch '2.3.x' into 2.4.x 2021-04-28 13:57:45 +02:00
Stephane Nicoll 20da9826cc Disable incrementalBuildTypeRenamed test
This commit disables a test that does not test what it is supposed to
and improve the Metadata assertions to fail early if more than one
matching item by name and type is found in the metadata.

See gh-26271
2021-04-28 13:54:35 +02:00
Andy Wilkinson a1138efc5f Merge branch '2.3.x' into 2.4.x
Closes gh-26256
2021-04-27 15:18:23 +01:00
Andy Wilkinson a470c1af3a Align documentation with main default branch name
Closes gh-26255
2021-04-27 15:18:00 +01:00
Andy Wilkinson bc1a462143 Merge branch '2.3.x' into 2.4.x
Closes gh-26168
2021-04-20 11:19:10 +01:00
Andy Wilkinson 82198a99e0 Polish nohttp configuration
Closes gh-26166
2021-04-20 11:15:13 +01:00
Phillip Webb fb3796dae8 Merge branch '2.3.x' into 2.4.x
Closes gh-26121
2021-04-14 15:02:58 -07:00
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
2021-04-14 15:02:42 -07:00
Scott Frederick 6a7f1f1c56 Merge branch '2.3.x' into 2.4.x
Closes gh-25992
2021-04-09 14:11:47 -05:00
Scott Frederick e19443093d Document runtime JVM configuration when building an image
Fixes gh-21478
2021-04-09 14:06:24 -05:00
Scott Frederick 9108b81bb2 Merge branch '2.3.x' into 2.4.x
Closes gh-25937
2021-04-08 13:03:26 -05:00
Scott Frederick 0ad7f76263 Preserve file permissions in images built by Gradle
This commit copies the file mode along with other attributes when
copying files from the source archive to the build container while
building an image using the Gradle plugin. This preserves file
permissions on any resources included in the source archive.

Fixes gh-25915
2021-04-08 12:56:41 -05:00
Andy Wilkinson e9ce20dbf4 Revert "Merge branch '2.3.x' into 2.4.x"
This reverts commit 586ce00e06, reversing
changes made to 563b8a8cec.

See gh-25839
2021-04-07 10:19:20 +01:00
Andy Wilkinson b35d1ec6e8 Revert "Use test harness for image building integration tests"
This reverts commit da9d8d6055.

See gh-25838
2021-04-07 09:30:51 +01:00
Scott Frederick 586ce00e06 Merge branch '2.3.x' into 2.4.x
Closes gh-25839
2021-03-30 17:39:10 -05:00
Scott Frederick da9d8d6055 Use test harness for image building integration tests
This commit modifies the integration tests for the Maven and Gradle
image building goal and task to use a custom builder as a test harness
to verify that the plugins invoke the builder as expected.

Fixes gh-25838
2021-03-30 16:48:28 -05:00
Andy Wilkinson 563b8a8cec Merge branch '2.3.x' into 2.4.x
See gh-25836
2021-03-30 20:52:15 +01:00
Andy Wilkinson e94f8bba62 Ensure that upstream jars have been built
See gh-25835
2021-03-30 20:51:33 +01:00
Andy Wilkinson 38a4f135a9 Merge branch '2.3.x' into 2.4.x
Closes gh-25836
2021-03-30 20:42:29 +01:00
Andy Wilkinson ca9a619259 Defer processing of zipTree source until execution time
Closes gh-25835
2021-03-30 20:41:46 +01:00
Andy Wilkinson 7a846ad41f Merge branch '2.3.x' into 2.4.x
Closes gh-25832
2021-03-30 18:18:10 +01:00
Andy Wilkinson 5a086321c6 Polish "Document Failsafe configuration when not using starter parent"
See gh-25621
2021-03-30 18:16:21 +01:00
robert-smith-911 0d79fd3e01 Document Failsafe configuration when not using starter parent
See gh-25621
2021-03-30 18:02:12 +01:00
Phillip Webb a28a3ae090 Merge branch '2.3.x' into 2.4.x 2021-03-30 09:25:46 -07:00
Phillip Webb 9c8a97809d Consistent use of @deprecated since
Restore the patch version number for consistency with `@since`
tags.

See gh-25808
2021-03-30 09:20:30 -07:00
Phillip Webb a0f5169966 Polish 2021-03-29 15:51:13 -07:00
Phillip Webb 363f5829d1 Merge branch '2.3.x' into 2.4.x
Closes gh-25825
2021-03-29 15:46:50 -07:00
Phillip Webb 26dd1b9a26 Update deprecations with for removal targets
Update all deprecation tags to include a removal target.

Closes gh-25808
2021-03-29 15:44:58 -07:00
Scott Frederick 4015d70f00 Merge branch '2.3.x' into 2.4.x
Closes gh-25789
2021-03-26 15:16:01 -05:00
Scott Frederick 3ad5f1013a Fix Maven image building with classifiers
Fixes gh-25736
2021-03-26 11:36:38 -05:00
Andy Wilkinson af7e4e211c Support all known endpoint types
Previously, the configuration metadata annotation processor only
declared support for `@Endpoint` and none of the other more
specialized `@…Endpoint` annotations that are meta-annotated with
`@Endpoint` such as `@WebEndpoint` and `@JmxEndpoint. This would
result in missing metadata if a full or incremental build only
compiled classes annotated with one of the more specialized
`@…Endpoint` annotations as the annotation processor would not be
called.

This commit updates the processor's supported annotation types to
include every known `@…Endpoint` annotation. The test processor has
also been similarly updated to align its behaviour with that of the
main processor.

Fixes gh-25388
2021-03-25 15:23:09 +00:00
Phillip Webb ca9fae6b47 Merge branch '2.3.x' into 2.4.x
Closes gh-25774
2021-03-23 17:07:44 -07:00
Phillip Webb ec21202d54 Delete unpacked jars when the JVM exits
Update `JarFileArchive` so that any unpacked files are now deleted when
the JVM exits.

Closes gh-25773
2021-03-23 17:06:56 -07:00
Phillip Webb 05f61bccea Align unpack logic with Files.createTempDirectory
Update `JarFileArchive` to align the way that it creates temp files and
folders with the way that `Files.createTempDirectory` works.

Closes gh-25772
2021-03-23 17:06:56 -07:00
Phillip Webb b8873578ca Add missing @Deprecated annotations 2021-03-23 17:06:53 -07:00
Phillip Webb 11a94ee6f0 Merge branch '2.3.x' into 2.4.x 2021-03-23 12:52:07 -07:00
Phillip Webb 82127fdaa3 Update copyright year of changed files 2021-03-23 12:50:49 -07:00
Scott Frederick 6f860b441b Merge branch '2.3.x' into 2.4.x
Closes gh-25700
2021-03-19 14:52:20 -05:00
Scott Frederick e4fa39df01 Fail fast when finalName is misconfigured
When the `finalName` parameter is incorrectly set in the Spring Boot
Maven plugin configuration instead of in the `build` configuration, the
repackaged and original archive files are not named as expected. Prior
to this commit, the image building goal would detect this error
condition and throw an exception late in the process of creating the
build container, leaving the container in an unstable state. This
commit changes the image building goal to detect this condition early,
before attempting to create the container.

Fixes gh-25590
2021-03-17 15:19:21 -05:00
Andy Wilkinson c815195f13 Polish 2021-03-17 12:25:13 +00:00
Andy Wilkinson 5595fd4017 Merge branch '2.3.x' into 2.4.x
Closes gh-25715
2021-03-17 11:31:46 +00:00
Andy Wilkinson 0e0418546b Test spring-boot:build-image when repackage is also invoked
Closes gh-25714
2021-03-17 11:19:29 +00:00
Andy Wilkinson ed4e419b0c Revert "Merge branch '2.3.x' into 2.4.x"
This reverts commit eaa510872a, reversing
changes made to 3e69522e2d.

See gh-25700
2021-03-17 11:13:58 +00:00
Andy Wilkinson ae2ff7849b Revert "Fail fast when finalName is misconfigured"
This reverts commit 263b7c20e4.

See gh-25590
2021-03-17 11:11:24 +00:00
Scott Frederick eaa510872a Merge branch '2.3.x' into 2.4.x
Closes gh-25700
2021-03-16 17:31:32 -05:00
Scott Frederick 263b7c20e4 Fail fast when finalName is misconfigured
When the `finalName` parameter is incorrectly set in the Spring Boot
Maven plugin configuration instead of in the `build` configuration, the
repackaged and original archive files are not named as expected. Prior
to this commit, the image building goal would detect this error
condition and throw an exception late in the process of creating the
build container, leaving the container in an unstable state. This
commit changes the image building goal to detect this condition early,
before attempting to create the container.

Fixes gh-25590
2021-03-16 17:22:48 -05:00
izeye 09f4d4b9bf Polish
See gh-25617
2021-03-13 18:08:54 +01:00
Stephane Nicoll ddf75f095c Merge branch '2.3.x' into 2.4.x
Closes gh-25515
2021-03-05 15:47:36 +01:00
Stephane Nicoll 6ebc69d704 Polish "Include properties in source merge algorithm"
See gh-25507
2021-03-05 15:47:09 +01:00
Bertrand Renuart cf4bc6e9e0 Include properties in source merge algorithm
This commit improves SimpleConfigurationMetadataRepository to include
properties that are contributed to an existing configuration metadata
source.

See gh-25507
2021-03-05 15:47:09 +01:00
Andy Wilkinson ac258a95a2 Merge branch '2.3.x' into 2.4.x
Closes gh-25508
2021-03-05 10:39:52 +00:00
Andy Wilkinson c6ca7a53ab Polish "Prevent extracting zip entries outside of destination path"
See gh-25505
2021-03-05 10:13:32 +00:00
trungPa 2993e68715 Prevent extracting zip entries outside of destination path
See gh-25505
2021-03-05 10:12:06 +00:00
dreis2211 89a44f3da4 Fix some assertions
See gh-25499
2021-03-05 09:56:55 +01:00
Andy Wilkinson 1ce6e796fe Polish "Allow the project to be built with Java 16"
See gh-25171
2021-03-04 18:54:58 +00:00
dreis2211 1ccd8dae8a Allow the project to be built with Java 16
See gh-25171
2021-03-04 18:54:56 +00:00
Stephane Nicoll e5d8b6029b Merge branch '2.3.x' into 2.4.x
Closes gh-25483
2021-03-03 15:16:08 +01:00
Stephane Nicoll 8e67ae7113 Fix fallback fork value for spring-boot:stop
This commit harmonizes the fallback value that spring-boot:stop goal
should use if no information is available in the current context.

Closes gh-25472
2021-03-03 15:15:04 +01:00
Scott Frederick afb60d6161 Add tests for Gradle examples used in plugin docs
Fixes gh-25468
2021-03-01 15:22:15 -06:00
Stephane Nicoll ed1c68f567 Update copyright year of changed file
See gh-25454
2021-03-01 10:06:23 +01:00
jnizet cbab2396e2 Fix property name in gradle plugin documentation
See gh-25454
2021-03-01 10:01:52 +01:00
Andy Wilkinson d48551ff12 Merge branch '2.3.x' into 2.4.x
Closes gh-25437
2021-02-25 17:32:40 +00:00
Stefan Wolf 86ca32e694 Enable stricter validation for Gradle plugin
See gh-25409
2021-02-25 17:28:51 +00:00
Andy Wilkinson ecf8437d4a Merge branch '2.3.x' into 2.4.x
Closes gh-25430
2021-02-25 14:28:28 +00:00
dreis2211 101d88a840 Update Testcontainers image versions
See gh-25412
2021-02-25 14:27:41 +00:00
Stephane Nicoll 7c5a5c6663 Merge branch '2.3.x' into 2.4.x
Closes gh-25385
2021-02-22 10:45:55 +01:00
Stephane Nicoll 77daae1480 Update copyright year of changed file
See gh-25382
2021-02-22 10:41:49 +01:00
Mustafa Ulu abc90db32f Fix wording error in build-info goal description
See gh-25382
2021-02-22 10:26:53 +01:00
Andy Wilkinson b86351d0cf Merge branch '2.3.x' into 2.4.x
Closes gh-25307
2021-02-16 11:30:03 +00:00
Andy Wilkinson a2adb877ee Polish "Encourage use of maven-publish plugin in Gradle docs"
See gh-25299
2021-02-16 11:22:47 +00:00
Robert Smith c0a5245a3e Encourage use of maven-publish plugin in Gradle docs
See gh-25299
2021-02-16 11:19:27 +00:00
Andy Wilkinson 45e6c12cb6 Consider transitives when identifying project dependencies
Previously, when building a layered jar, the Gradle plugin only
considered a configuration's direct dependencies when identifying
project dependencies. This resulted in transitive project dependencies
being missed when deciding which dependencies belong in the
application layer.

This commit updates ResolvedDependencies to consider all projects
from the root project when collecting the IDs of local projects. This
ensures that any project dependency, no matter where it appears in the
dependency graph, is successfully identified.

Fixes gh-25163
2021-02-10 12:10:07 +00:00
Stephane Nicoll 9218965104 Merge branch '2.3.x' into 2.4.x
Closes gh-25140
2021-02-09 15:04:28 +01:00
dreis2211 4937547b8a Fix build deprecation warnings about duplicate jar entries
See gh-25116
2021-02-09 14:45:58 +01:00
Andy Wilkinson 788a42d694 Merge branch '2.3.x' into 2.4.x
See gh-25076
2021-02-02 15:12:27 +00:00
Andy Wilkinson 67479b6380 Add junit-platform-launcher dependency by convention
Closes gh-25074
2021-02-02 13:03:21 +00:00
Phillip Webb 230b4ab2eb Merge branch '2.3.x' into 2.4.x 2021-02-01 22:10:52 -08:00
Phillip Webb 630d216430 Update copyright year of changed files 2021-02-01 22:10:24 -08:00
Phillip Webb 331c7b756b Merge branch '2.3.x' into 2.4.x 2021-02-01 19:46:49 -08:00
Phillip Webb c404a50a2e Allow test to use snapshot/milestone repo
Update `spring-boot-maven-plugin` `settings.xml` so that milestone and
snapshot dependencies can be resolved.

See gh-23936
2021-02-01 19:45:11 -08:00
Phillip Webb 003f2f9521 Merge branch '2.3.x' into 2.4.x 2021-02-01 17:07:07 -08:00
Phillip Webb faaa5e4186 Fix BOM attached sourceSet
See gh-23936
2021-02-01 16:51:53 -08:00
Phillip Webb db52bf3d7a Merge branch '2.3.x' into 2.4.x
Closes gh-25078
2021-02-01 16:35:46 -08:00
Phillip Webb 40c1748e3c Remove hardcoded versions from MavenBuild
Use the dependencies BOM to ensure versions used in the `MavenBuild`
test class are always aligned.

Closes gh-23936
2021-02-01 16:20:55 -08:00