This commit introduces a DefaultEnablement enum that replaces the
"enabledByDefault" boolean flag of Endpoint. This allows to better
control what indicates the default enablement of an endpoint.
With DefaultEnablement#ENABLED, the endpoint is enabled unless an
endpoint specific property says otherwise. With DefaultEnabled#DISABLED,
the endpoint is disabled unless an endpoint specific property says
otherwise. DefaultEnablement#NEUTRAL provides a dedicated option to
indicate that we should resort to the default settings in absence of
a specific property.
See gh-10161
Following the rework on Security that expects web endpoints to be
disabled by default, this commit updates the metadata (including the
automatic generation) to reflect this decision.
This commit improves the configuration metadata annotation processor to
explicitly handle `@Endpoint` annotated class. Adding a new endpoint on
a project potentially creates the following keys:
* `endpoints.<id>.enabled`
* `endpoints.<id>.cache.time-to-live`
* `endpoints.<id>.jmx.enabled`
* `endpoints.<id>.web.enabled`
Default values are extracted from the annotation type. If an endpoint
is restricted to a given tech, properties from unrelated techs are not
generated.
Closes gh-9692
Remove test-jar artifacts from Maven projects and relocate classes. The
majority of utilities now live in the `spring-boot-testsupport` module.
This update will help us to deploy artifacts using the standard Maven
deploy plugin in the future (which doesn't support the filtering of
individual artifacts).
Fixes gh-9493
Previously, if lombok was running before the configuration metadata
annotation processor, duplicated keys were created as both the
getter/setter and the special lombok handling applied.
This commit makes sure to be lenient by removing duplicate metadata
entries. This commit also makes sure to identify the getter of a
nested group if present. That way, the sourceMethod is set consistently
and avoid the creation of a duplicate group.
Closes gh-8886
Add an annotation processor that generates properties files for certain
auto-configuration class annotations. Currently attribute values from
@AutoConfigureOrder, @AutoConfigureBefore, @AutoConfigureAfter and
@ConditionalOnClass annotations are stored.
The properties file will allow optimizations to be added in the
`spring-boot-autoconfigure` project. Primarily by removing the need
to ASM parse as many `.class` files.
See gh-7573