Reinstate ConditionalOnBean

See gh-28131
pull/28398/head
Madhura Bhave 3 years ago
parent b7521e2fda
commit 40a3824279

@ -89,6 +89,7 @@ class JerseyWebEndpointManagementContextConfiguration {
@Bean @Bean
@ConditionalOnManagementPort(ManagementPortType.DIFFERENT) @ConditionalOnManagementPort(ManagementPortType.DIFFERENT)
@ConditionalOnBean(HealthEndpoint.class)
@ConditionalOnAvailableEndpoint(endpoint = HealthEndpoint.class, exposure = EndpointExposure.WEB) @ConditionalOnAvailableEndpoint(endpoint = HealthEndpoint.class, exposure = EndpointExposure.WEB)
JerseyAdditionalHealthEndpointPathsManagementResourcesRegistrar jerseyDifferentPortAdditionalHealthEndpointPathsResourcesRegistrar( JerseyAdditionalHealthEndpointPathsManagementResourcesRegistrar jerseyDifferentPortAdditionalHealthEndpointPathsResourcesRegistrar(
WebEndpointsSupplier webEndpointsSupplier, HealthEndpointGroups healthEndpointGroups) { WebEndpointsSupplier webEndpointsSupplier, HealthEndpointGroups healthEndpointGroups) {

@ -64,11 +64,11 @@ import org.springframework.web.servlet.DispatcherServlet;
*/ */
@Configuration(proxyBeanMethods = false) @Configuration(proxyBeanMethods = false)
@ConditionalOnWebApplication(type = Type.SERVLET) @ConditionalOnWebApplication(type = Type.SERVLET)
@ConditionalOnBean(HealthEndpoint.class)
@ConditionalOnAvailableEndpoint(endpoint = HealthEndpoint.class, exposure = EndpointExposure.WEB) @ConditionalOnAvailableEndpoint(endpoint = HealthEndpoint.class, exposure = EndpointExposure.WEB)
class HealthEndpointWebExtensionConfiguration { class HealthEndpointWebExtensionConfiguration {
@Bean @Bean
@ConditionalOnBean(HealthEndpoint.class)
@ConditionalOnMissingBean @ConditionalOnMissingBean
HealthEndpointWebExtension healthEndpointWebExtension(HealthContributorRegistry healthContributorRegistry, HealthEndpointWebExtension healthEndpointWebExtension(HealthContributorRegistry healthContributorRegistry,
HealthEndpointGroups groups) { HealthEndpointGroups groups) {

Loading…
Cancel
Save