Call afterPropertiesSet on the delegate `ResourceHttpRequestHandler`
to prevent an NPE. This change is required for compatibility with
Spring Framework 4.3 following SPR-13834.
Closes gh-6592
Previously, CLI extensions where installed into the CLI's lib
directory which meant that they were on the class path of the app
class loader. Following the change to an executable jar's packaging,
this meant that they could not see classes in the CLI and a
ClassNotFoundException would result.
This commit updates the CLI to install extensions into lib/ext and
load commands using a new ClassLoader that has all of the jars in
lib/ext on its class path and that uses the launch class loader as
its parent.
Closes gh-6615
Previously, if a single FailureAnalyzer failed to load, no failure
analysis would be performed. This commit updates FailureAnalyzers to
load the analysers defensively so that all but the problematic analyzer
are used for analysis.
Closes gh-6606
Previously, MetricExportAutoConfiguration consumed
ExportMetricWriter-annotated GaugeWriter beans in its constructor and
also produced such a bean from one of its @Bean methods. This cycle
caused a BeanCurrentlyInCreationException to be thrown when the
bean method was active (the spring.metrics.export.statsd.host property
was set).
This commit break the cycle by moving the bean method into a separate,
nested configuration class. It also updates the existing test for
auto-configuration of a Statsd writer to catch any possible cycles
and to verify that the writer has be registered with the
MetricsExporter.
Closes gh-6544
META-INF/INDEX.LIST files are pointless in an executable jar and
moving application classes from the root of the jar to
BOOT-INF/classes breaks the index, resulting in an
InvalidJarIndexException being thrown.
This commit updates the Repackager to automatically remove a
META-INF/INDEX.LIST file from a jar file that is being repackaged.
Closes gh-6601
Previously, MockitoPostProcessor would fail to replace a factory bean
with a mock if the factory bean didn't return a matching type from
getObjectType(). This prevented Spring Data respoitories from being
replaced with a mock as Spring Data's repository factory beans
generally do not know the specific repository type that they will
produce when MockPostProcesser (a bean factory post-processor) is
running.
Spring Data has been updated to add a factoryBeanObjectType attribute
to its factory bean definitions. MockitoPostProcessor has been updated
to look for FactoryBeans with this attribute and to use its value
to determine whether or not the factory bean produces a bean of the
required type and, therefore, should be replaced with a mock.
Closes gh-6541
Previously, a NullPointerException would occur if
endpoints.docs.curies.enabled was true and the default value was being
used for either server.port or management.port.
EndpointWebMvcHypermediaManagementContextConfiguration has been
restructured to ensure that the DocsMvcEndpoint bean is defined before
the condition on its existence is evaluated. Previously this was
dependant on the class’s bean methods being processed in a particular
ordering, something that would be ok when using ASM but would vary when
using reflection.
Closes gh-6584
Update JsonTestersAutoConfiguration so that GSON and Jackson specific
configuration are inner classes. This should prevent ClassNotFound
exception when the libraries are not on the classpath.
Fixes gh-6502
This commit fixes the `@ConditionalOnClass` typo on the GsonTester
FactoryBean, which was testing for `ObjectMapper` instead of `Gson`.
This means that the next condition `@ConditionalOnBean(Gson.class)`
throws a `ClassNotFoundException: com.google.gson.Gson` since it's
trying to load that class to check for an existing Bean of that type.
Fixes gh-6502
Update spring-boot-docs so that an empty jar file is produced. The
code is only needed for documentation includes and if included in the
deployed jar seems to prevent promotion to Maven Central.
Fixes gh-6495
Update ConfigurationPropertiesBindingPostProcessor with improved logging
when multiple PropertySourcesPlaceholderConfigurer beans are found.
See gh-6457