Add a new `ClientHttpConnectorBuilder` interface to support the
creation of `ClientHttpConnector` instances. The new code is similar
to the `ClientHttpRequestFactoryBuilder` interface that was added to
Spring Boot 3.4.
The `ClientHttpConnectorBuilder` is a functional interface with
additional static factory methods for the various supported
`ClientHttpConnector` types. Each type has it's own builder
which to support client specific customization.
The previous auto-configuration has been relocated to the
`org.springframework.boot.autoconfigure.http.client.reactive`
package and updated to make use of the builder.
Closes gh-43079
Update CassandraRepositoriesAutoConfigurationTests to use the correct
'spring.data.cassandra.repositories.type' property.
See gh-44942
Signed-off-by: Dmytro Nosan <dimanosan@gmail.com>
This commit deprecates spring.mvc.converters.preferred-json-mapper
and replaces it with spring.http.converters.preferred-json-mapper.
If both properties are specified, the latter takes precedence.
Closes gh-44925
This commit updates the WebFlux security documentation, primarily to
link to reactive types rather than their Servlet-based equivalents.
It also attempts to clarify when a user details service is
auto-configured.
Closes gh-44955
Add tests for decoding percent-encoded strings with non-ASCII characters
and multi-byte sequences.
See gh-44944
Signed-off-by: Dmytro Nosan <dimanosan@gmail.com>
This commit updates `TaskExecutionAutoConfiguration` to permit the
auto-configuration of a `TaskExecutor` even if a user-defined `Executor`
bean is present.
Such `Executor` may have been created for totally unrelated reason, and
it may or may not be an `AsyncTaskExecutor`. The default behavior has
not changed, but this commit provides a new property,
`spring.task.execution.mode` that can be set to `force` to
auto-configure the `TaskExecutor` anyway.
Because this mode made it so that two `Executor` will be present in the
context, this commit also automatically configures an `AsyncConfigurer`
if none is present already to make sure task processing uses the
auto-configured TaskExecutor.
Closes gh-44659
This commit adds customizers for both OtlpHttpSpanExporterBuilder
and OtlpGrpcSpanExporterBuilder.
See gh-44900
Signed-off-by: Dmytro Nosan <dimanosan@gmail.com>
Prior to this commit, the SSL file hot reloading feature would
create file watchers for all configured locations and would resolve
symbolic links if they're found as registrations.
This arrangement would work for typical Let's Encrypt setups, but
would not get notified of consecutive changes for k8s setups.
Kubernetes uses a mix of symlinks and atomic file moves to update
secrets.
This commit not only tracks changes to symlinks targets, but also
to the original symlink.
Closes gh-44807
Signed-off-by: Dmytro Nosan <dimanosan@gmail.com>
[brian.clozel@broadcom.com: apply code conventions]
Signed-off-by: Brian Clozel <brian.clozel@broadcom.com>
Previously, managed dependencies were documented using Gradle's
dependency constraints. This has proven to be non-deterministic for
reasons that are not fully understood. The working theory is that
the constraints that are documented vary depending on the tasks
that the build has run at the point at which the constraints are
being examined and documented.
This commit replaces approach with one that builds a model of a
resolved bom by examining the configured bom extension and the
XML of the Maven boms that it imports. This model is written to
disk from where it can then be consumed as a dependency on other
projects. The existing tasks for documenting the constrained
versions and version properties have been rewritten to use the
resolved bom model instead.
Closes gh-44855
Update `IndexedElementsBinder` so that bind operations are faster at
the expense of not checking that all elements have been bound. The
updated code now uses a window of 10 elements and assumes that if
no elements are missing from that window then exhaustive checking is
not required.
Closes gh-44867
Replace a few usages of stream with simple for loops. Although
this doesn't seem to make much difference to performance, it does
help when profiling applications since it reduces the stack
depth.
Add a simple cache that is used for the system environment property
source to cache `containsDescendantOf` results since descendants
cannot be used due to the more complicated algorithm.
Closes gh-44863
Update `ConfigurationPropertySource` adapters so accessing the
`SystemEnvironmentPropertySource` is handled by directly calling
the source.
This saves potentially expensive calls to `resolvePropertyName`
which are unnecessary since mappings are handled directly.
Closes gh-44862
Introduce a general purpose cache in the `Binder` and make use of it
in `JavaBeanBinder` and `ValueObjectBinder` to reuse potentially
expensive operations.
Closes gh-44861
Add `ConfigurationPropertyCaching.override()` method which can be
used to temporarily enable caching for the duration of an
operation.
The `Binder` now uses this method to ensure that caching is
enabled whilst a set of related binding operations are performed.
Closes gh-44860
Update `SystemEnvironmentPropertySourceEnvironmentPostProcessor` so
that our origin aware subclass is marked as immutable. This aligns
with the behavior we had before introducing origin tracking, which
assumes that environment variables changes made after the application
starts are not re-bound.
Closes gh-44859
Update `ConfigurationPropertyName` to improve performance of
the `equals(...)` and `hashCode()` methods by making the
following changes:
- Move element hashCode logic to Element and cache the results
- Exit the equals method early if hashcodes don't match
- Exit the equals method early if toString() values match
Closes gh-44857