3680 Commits
Author SHA1 Message Date
Phillip Webb 448acaa5be Remove Apache header from spring-boot-gradle-plugin examples
Closes gh-48474
2025-12-09 08:35:00 -08:00
geopark021 6b60d89b28 Remove unnecessary cast
Replace explicit casts with pattern variables to improve readability and
remove redundancy.

See gh-48297

Signed-off-by: geopark021 <geobrown021@gmail.com>
2025-11-26 15:55:47 +01:00
Andy Wilkinson 710e567ba5 Check javadoc macros in adoc files
Closes gh-48298
2025-11-26 10:41:49 +00:00
Andy Wilkinson 859606ae13 Split architecture checks by language as well as source set
Closes gh-48224
2025-11-21 16:44:54 +00:00
Phillip Webb 4a8d01d2b6 Exclude starter POMs from lib-provided when using Gradle
Fixes gh-48195
2025-11-19 21:58:03 -08:00
Phillip Webb 7837583484 Add credentials to ivy settings to support commercial builds
Closes gh-46824
2025-11-17 20:54:34 -08:00
Phillip Webb 53bda71c3e Use platform when exporting buildpack images
Update `DockerApi` and `Builder` to support export of images with a
specified platform. This prevents 'NotFound: content digest sha256:'
errors when building an amd64 image on an arm64 machine.

Fixes gh-46665
2025-11-13 15:19:26 -08:00
Stéphane Nicoll fc826218b4 Merge pull request #48100 from nosan
* pr/48100:
  Use ObjectNode for building ImagePlatform JSON

Closes gh-48100
2025-11-13 10:53:55 +01:00
Dmytro Nosan d251b99615 Use ObjectNode for building ImagePlatform JSON
See gh-48100

Signed-off-by: Dmytro Nosan <dimanosan@gmail.com>

Closes gh-48100
2025-11-13 10:53:41 +01:00
Stéphane NicollandCatiaCorreia catia.correia97@gmail.com 9e656c1554 Remove unnecessary field initialization
Closes gh-45168

Co-authored-by: CatiaCorreia catia.correia97@gmail.com
2025-11-13 10:21:05 +01:00
Phillip Webb 9b387cbe77 Support recent Docker installs by raising the API version when possible
Update `DockerApi` so that the URL uses version `v1.50` whenever
possible. Prior to this commit, `v1.24` was often used which breaks
recent Docker installs due to the dropping of API version v1.43 and
below.

If the actual API version running is less than `v1.50`, but greater
than the minimum required for the API call, it will be used instead.
This hopefully means that older versions of Docker will continue to
work as they did previously.

Fixes gh-48050
2025-11-12 19:57:36 -08:00
Phillip Webb 39f3d1c72c Polish 'Correctly handle platform specific buildpack builds'
See gh-47292
2025-11-12 11:07:29 -08:00
hojooo 913c434b90 Correctly handle platform specific buildpack builds
Prior to this commit, performing a build on a ARM Mac with the default
configuration and then building it again with the image platform set to
`linux/amd64` results in an "Image platform mismatch detected" failure.

This is due to the fact that `docker inspect` returns JSON for the
default platform, regardless of the fact that another architecture
has been pulled.

To solve the issue, the `inspect` API call on Docker 1.49+ can now
accept a platform query parameter which when specified returns platform
specific JSON.

At the time of this commit, the Docker API documentation hasn't been
updated, despite PR https://github.com/moby/moby/pull/49586 being
merged.

In addition to using the correct inspect JSON, we also need to pin
the run image we use to a specific digest. Without doing this,
buildpacks revert back to the default platform image and
"content digest not found" errors are thrown (similar to
https://github.com/buildpacks/docs/issues/818).

See gh-47292

Signed-off-by: hojooo <ghwn5833@gmail.com>
2025-11-12 10:33:22 -08:00
Andy Wilkinson f1957a9740 Address warnings reported by Eclipse 2025-11-10 09:55:50 +00:00
namest504 de7cad3d63 Remove unnecessary stream opening in BootZipCopyAction
See gh-47902

Signed-off-by: namest504 <namest504@gmail.com>
2025-11-03 10:18:48 +01:00
Phillip Webb abce914a76 Polish 'Handle HTTP 407 with clear error message'
See gh-47180
2025-10-31 11:50:39 -07:00
SSUday 5aa841dd53 Handle HTTP 407 with clear error message
Refine error handling logic so that HTTP 407 (Proxy Authentication
Required) responses from the Docker daemon are treated as plain
text rather than JSON.

See gh-47180

Signed-off-by: Siva Sai Udayagiri <udayagirishivasai@gmail.com>
2025-10-31 11:49:14 -07:00
Tran Ngoc Nhan 0546e3035d Fix typos
See gh-47801

Signed-off-by: Tran Ngoc Nhan <ngocnhan.tran1996@gmail.com>
2025-10-27 11:40:32 +01:00
Dmitrii Karagodin 43d91aee38 Write signature files to uber wars for Oracle Java 17 verification
Extend commit 33c5e126 to include uber Wars.

See gh-47284

Signed-off-by: Dmitrii Karagodin <4319788@gmail.com>
2025-10-22 20:27:53 -07:00
Tran Ngoc Nhan 4bebd47c4e Fix typos
See gh-47747
2025-10-21 11:27:41 -07:00
Andy Wilkinson 43cbd9d90a Correct Sbom-Location for wars, add integration tests
Closes gh-47407
Fixes gh-47408
2025-10-21 10:03:06 +01:00
Stéphane Nicoll f8e04e0be2 Polish "Fix Homebrew formula to use libexec"
See gh-47696
2025-10-21 07:58:58 +02:00
Vinicius Lublanski 72832b06d3 Fix Homebrew formula to use libexec
See gh-47696

Signed-off-by: Vinicius Lublanski <vlublima@gmail.com>
2025-10-20 15:54:16 +02:00
Vincent Potucek 168fa858c5 Remove unnused parameter
See gh-47694

Signed-off-by: Vincent Potucek <vpotucek@me.com>
2025-10-19 16:45:59 +02:00
Stéphane Nicoll 2973f3cb4d Upgrade to Lombok 1.18.42
Closes gh-47518
2025-10-11 12:17:56 +02:00
Stéphane Nicoll 30938e30f0 Rename annotations used by tests of the configuration processor
This commit renames the annotations and other signals that the
annotation processor uses to process configuration metadata. By adding
a `Test` prefix, this prevents the confusion with the real annotation.

Closes gh-47468
2025-10-10 14:04:59 +02:00
Phillip Webb b43d2f2088 Remove version number from assertions 2025-09-24 14:08:26 -07:00
Scott Frederick 6354d802c0 Update managed dependency version override examples in documentation
The examples for overriding a managed dependency version with Maven
were using an outdated version property. This commit updates the
example to use a valid property.

The version override warning from the Gradle plugin docs was also
copied to the Maven docs.

See gh-47304

Signed-off-by: Scott Frederick <scottyfred@gmail.com>
2025-09-24 11:39:49 +02:00
Moritz Halbritter 4a1de8534f Add detection for Bitnami Legacy images
This commit also adjusts the tests to use bitnamilegacy images because we have no way to test against the original bitnami images.

Closes gh-46983
2025-09-19 10:18:59 +02:00
Moritz Halbritter 507f868fe9 Remove quoting for system properties
Before this commit, system properties with a value has been quoted all the time.
This is fine as long if the resulting string is passed into the RunArguments(String) constructor, which then parses it again into a String[].
This isn't fine if they are added to ProcessBuilder.command, because then quoting is unnecessary.

This commit also fixes the unnecessary Map -> String -> String[] parsing by adding the entries directly into the array.

Closes gh-46555
2025-09-12 10:06:16 +02:00
Andy Wilkinson f28caee30d Fix NestedJarFile.JarEntryInputStream's available() behavior
Previously, available() would return 0 initially and then negative
values once some data head been read. It should be a positive value
(for entries with content) initially a decrease as data is read
reaching zero once an entry's data has been read in its entirety.

This commit initialises the count of the remaining bytes to
be equal to the entry's uncompressed size. It also removes logic
that closes the stream when remaining equals zero upon read or skip.
This condition was not reached before as remaining would become
negative as soon as any data was read or skipped. With the correct
initialization of remaining, the condition is now reached and it
results in test failures due to premature closure. Furthermore, the
javadoc of read and skip do not require the stream to be closed
when the reach end of file.

Closes gh-47056
2025-09-05 17:29:22 +01:00
Johnny Lim 438df257b5 Polish
See gh-47028

Signed-off-by: Johnny Lim <izeye@naver.com>
2025-09-05 14:13:02 +02:00
Stefano Cordio c7b659cb7e Replace AssertJ internal APIs with alternative implementations
See gh-46855

Signed-off-by: Stefano Cordio <stefano.cordio@gmail.com>
2025-08-18 13:57:27 +02:00
Stéphane Nicoll b190e8077b Consistently detect the default value of a property
This is a follow-up of gh-46599 where detecting the default value
suffer from the same problem. Rather than using a name, the resolver now
provides the field itself. This also adds a dedicated test for the use
of @Name with Lombok.

Closes gh-46662
2025-08-04 15:32:51 +02:00
Stéphane Nicoll 27d7c5992b Polish "Stop using custom name for elements resolution"
See gh-46599
2025-08-04 15:00:08 +02:00
Bohdan Pryshedko 1014fc2106 Stop using custom name for elements resolution
Previously, when a property was customized with @Name, getter, setter,
field, and record component were looked up using the custom name, rather
than the property name. This lead to missing information as the custom
name is not meant to match the field name, for instance.

This commit keeps the custom name, but uses the property name as for
other cases.

See gh-46599

Signed-off-by: Bohdan Pryshedko <prishedko@gmail.com>
2025-08-04 14:59:54 +02:00
Andy Wilkinson 8b4623653c Simplify code by making of us shouldResolveConsistentlyWith
Closes gh-46642
2025-08-01 06:57:06 +01:00
Stéphane Nicoll 079bf986f2 Polish "Do not set primitive default value for unsupported expressions"
See gh-46551
2025-07-28 12:49:34 +02:00
Now 5cf373aded Do not set primitive default value for unsupported expressions
See gh-46551

Signed-off-by: Now <khj990322@gmail.com>
2025-07-28 12:39:38 +02:00
Andy Wilkinson 3e6e64ec49 Use build instead of temp dir for Gradle TestKit directories
Closes gh-46479
2025-07-22 11:24:40 +01:00
Johnny Lim e5862c69b8 Fix BootZipCopyAction.Processor.getDirMode(FileCopyDetails)
See gh-46408

Signed-off-by: Johnny Lim <izeye@naver.com>
2025-07-14 09:50:48 +01:00
Phillip Webb ea8af9af56 Fix checkstyle violation
See gh-46401
2025-07-10 19:42:02 -07:00
Phillip Webb 08cc62a6b6 Simplify JarFileUrlKey to prevent issues with Cortex XDR agent
Replace the string based `JarFileUrlKey` and cache with a simple key
built directly from URL components. This should allow cache lookups
to remain fast whilst removing any `URLStreamHandler.getHostAddress`
calls.

Prior to this commit, we assumed that it was safe to use the URL
directly as a cache key as long as it had an empty or null `host`.
This assumption isn't correct when Palo Alto Network Cortex XDR agent
is present as it appears to intercept calls to `getHostAddress`
and, unlike the JDK code, always perform a DNS lookup.

Fixes gh-46401
2025-07-10 18:05:16 -07:00
Andy Wilkinson f61c54632a Work around Kotlin plugin breaking AOT compile classpaths
Compilation of AOT-generated source code requires runtime
dependencies to be on the classpath. This is necessary as a class
from a runtime dependency may appear in the signature of a generated
method that defines a bean. To accomplish this, Boot's AOT plugin
sets the org.gradle.usage attribute of the compile classpath
configurations of the aot and aotTest source sets to java-runtime.

When the Kotlin plugin is applied after Boot's AOT plugin it breaks
this arrangement by setting org.gradle.usage to java-api. There
doesn't appear to be a way to prevent it from messing with the aot
and aotTest source sets despite them not using Kotlin. This commit
works around the problem by repairing the damage and setting the
attribute back to java-runtime again.

Fixes gh-46397
2025-07-10 15:59:37 +01:00
Piyal Ahmed b9589203dc Polish
Signed-off-by: Piyal Ahmed <piya.salamence@gmail.com>

See gh-46291
2025-07-07 09:31:43 +01:00
Andy Wilkinson 8c261ce2fc Test Gradle plugin against Gradle 7.6.6
Closes gh-46300
2025-07-07 07:52:21 +01:00
Piyal Ahmed 8fb3010942 Remove unnecessary semicolons from Gradle build scripts
Signed-off-by: Piyal Ahmed <piya.salamence@gmail.com>

See gh-46252
2025-07-02 20:31:01 +01:00
Dmytro Nosan 67f380c2bc Add @EnabledOnLocale annotation for locale-based tests
Introduce @EnabledOnLocale annotation to enable or disable tests
based on the system's default locale.

See gh-46211

Signed-off-by: Dmytro Nosan <dimanosan@gmail.com>
2025-06-27 12:45:35 +02:00
Andy Wilkinson 49fdc31532 Add jars that were missed due to .gitignore
See gh-46043
2025-06-25 15:14:04 +01:00
Andy Wilkinson bdee9c9b19 Ensure consistent versions between dev and production classpaths
Prior to this change, versions in the dev and production classpaths
could differ. These differing versions could result in a transitive
dependency that should have been present in both development and
production only being present in the former. This would likely
result in failures at runtime.

This commit aligns the versions by adding constraints to the
production runtime classpath for each dependency in the runtime
classpath.

Closes gh-46043
2025-06-25 13:35:39 +01:00