This commit adds GC and thread jvm metrics to the existing memory
metrics. All three are now managed by a unique
management.metrics.binders.jvm.enabled property.
Closes gh-11425
This commit moves management.server.context-path to
management.server.servlet.context-path to align with the configuration
key for the application's main context path.
Closes gh-11359
`CorsEndpointProperties` lives in `endpoint.web.servlet` but is also used
in `endpoint.web.reactive`, so this PR moves it to its common parent
package.
This commit also extracts `CorsConfiguration` creation logic duplicated
in `WebMvcEndpointManagementContextConfiguration` and
`WebFluxEndpointManagementContextConfiguration` into
`CorsEndpointProperties`.
See gh-11439
Change the default JSR-303 validator used by the configuration
properties binder so that it's initialized in a background thread.
This change allows the context to carry on loading additional beans
whilst the validator is initializing.
Fixes gh-11412
Update the `PropertyMapper` interface to return arrays rather than
Lists. Since implementations are package-private it's possible for us
to control how they are used and it helps to save a little memory.
Fixes gh-11411
Update the `LaunchedURLClassLoader` used for fat jar support so that
each iteration on a `findResources` result also allows for fast
exceptions.
Fixes gh-11406
Refactor fat jar loader classes so that less `char[]` instances are
created. This is primarily achieved by adding a new `StringSequence`
class that can chop up Strings without needing to copy the underlying
array. Since Java 8, calls to `String.subString(...)` always copy the
underlying char array. For many of the operations that we need, this
is unnecessary.
Fixes gh-11405
Remove support for the `__` environment variable list shortcut in order
to reduce complexity. The shortcut was developed before the new `Binder`
code was fully formed and isn't really necessary now since comma-lists
can be converted automatically.
Fixes gh-11410
Prior to this change, the Spring MVC auto-configuration would add a new
formatter to convert `java.util.Date` to/from `String` using the
configured configuration property `spring.mvc.date-format`.
This commit adds a new `WebConversionService` class that registers
date formatters with a custom date format, or register the default ones
if no custom configuration is provided.
This avoids duplicating equivalent formatters in the registry.
With this change, date types from `java.util`, `org.joda.time` and
`java.time` are now all supported.
This commit also replicates this feature for WebFlux applications by
adding a new `spring.webflux.date-format` configuration property.
Closes gh-5523
Closes gh-11402
This commit improve the couchbase health indicator to list the available
nodes. Doing so improves the reliability of the indicator as accessing
the bucket forces a remote call and better detect the cases where the
broker is down.
Closes gh-7369
Update ImageBanner to support animated GIFs. Animations rely on ANSI
cursor codes so don't work so well in an IDE. They do, however, work
when running the app from a terminal.
See also commit 47bc5e71ab
Closes gh-11118
Previously, the Health web extension was defined in the management
context and, as a result, it wasn't found when a separate port was
required. The side effect is that anything that the health web extension
does was not active anymore in that case.
This commit makes sure that the extension is always defined as part of
the main context where operations are discovered and merged.
Closes gh-11285
MeterRegistryConfigurers are now applied within the Bean method
creating the CompositeMeterRegistry, instead of applying them
later in its lifecycle, when the bean itself could have been
injected somewhere.
Fixes gh-11319