From e2119d33293008fcc876f5fcd58ede2993eb24d6 Mon Sep 17 00:00:00 2001 From: izeye Date: Sat, 22 Aug 2015 17:02:54 +0900 Subject: [PATCH] Fix typos Closes gh-3809 --- ...> ConditionalOnEnabledHealthIndicator.java} | 4 ++-- .../HealthIndicatorAutoConfiguration.java | 18 +++++++++--------- .../OnEnabledHealthIndicatorCondition.java | 2 +- .../HealthIndicatorAutoConfigurationTests.java | 2 +- ...ctConfigurableEmbeddedServletContainer.java | 2 +- ...ctEmbeddedServletContainerFactoryTests.java | 4 ++-- 6 files changed, 16 insertions(+), 16 deletions(-) rename spring-boot-actuator/src/main/java/org/springframework/boot/actuate/autoconfigure/{ConditionalOnEnablednHealthIndicator.java => ConditionalOnEnabledHealthIndicator.java} (93%) diff --git a/spring-boot-actuator/src/main/java/org/springframework/boot/actuate/autoconfigure/ConditionalOnEnablednHealthIndicator.java b/spring-boot-actuator/src/main/java/org/springframework/boot/actuate/autoconfigure/ConditionalOnEnabledHealthIndicator.java similarity index 93% rename from spring-boot-actuator/src/main/java/org/springframework/boot/actuate/autoconfigure/ConditionalOnEnablednHealthIndicator.java rename to spring-boot-actuator/src/main/java/org/springframework/boot/actuate/autoconfigure/ConditionalOnEnabledHealthIndicator.java index 284886de6a..47e4cb1c80 100644 --- a/spring-boot-actuator/src/main/java/org/springframework/boot/actuate/autoconfigure/ConditionalOnEnablednHealthIndicator.java +++ b/spring-boot-actuator/src/main/java/org/springframework/boot/actuate/autoconfigure/ConditionalOnEnabledHealthIndicator.java @@ -27,7 +27,7 @@ import org.springframework.context.annotation.Conditional; /** * {@link Conditional} that checks whether or not a default health indicator is enabled. * Matches if the value of the {@code management.health..enabled} property is - * {@code true}. Otherwise , matches if the value of the + * {@code true}. Otherwise, matches if the value of the * {@code management.health.defaults.enabled} property is {@code true} or if it is not * configured. * @@ -38,7 +38,7 @@ import org.springframework.context.annotation.Conditional; @Target({ ElementType.TYPE, ElementType.METHOD }) @Documented @Conditional(OnEnabledHealthIndicatorCondition.class) -public @interface ConditionalOnEnablednHealthIndicator { +public @interface ConditionalOnEnabledHealthIndicator { /** * The name of the health indicator. diff --git a/spring-boot-actuator/src/main/java/org/springframework/boot/actuate/autoconfigure/HealthIndicatorAutoConfiguration.java b/spring-boot-actuator/src/main/java/org/springframework/boot/actuate/autoconfigure/HealthIndicatorAutoConfiguration.java index 250e3ace8a..ceafa9dfa1 100644 --- a/spring-boot-actuator/src/main/java/org/springframework/boot/actuate/autoconfigure/HealthIndicatorAutoConfiguration.java +++ b/spring-boot-actuator/src/main/java/org/springframework/boot/actuate/autoconfigure/HealthIndicatorAutoConfiguration.java @@ -153,7 +153,7 @@ public class HealthIndicatorAutoConfiguration { @Configuration @ConditionalOnClass(JdbcTemplate.class) @ConditionalOnBean(DataSource.class) - @ConditionalOnEnablednHealthIndicator("db") + @ConditionalOnEnabledHealthIndicator("db") public static class DataSourcesHealthIndicatorConfiguration extends CompositeHealthIndicatorConfiguration implements InitializingBean { @@ -193,7 +193,7 @@ public class HealthIndicatorAutoConfiguration { @Configuration @ConditionalOnBean(MongoTemplate.class) - @ConditionalOnEnablednHealthIndicator("mongo") + @ConditionalOnEnabledHealthIndicator("mongo") public static class MongoHealthIndicatorConfiguration extends CompositeHealthIndicatorConfiguration { @@ -210,7 +210,7 @@ public class HealthIndicatorAutoConfiguration { @Configuration @ConditionalOnBean(RedisConnectionFactory.class) - @ConditionalOnEnablednHealthIndicator("redis") + @ConditionalOnEnabledHealthIndicator("redis") public static class RedisHealthIndicatorConfiguration extends CompositeHealthIndicatorConfiguration { @@ -228,7 +228,7 @@ public class HealthIndicatorAutoConfiguration { @Configuration @ConditionalOnBean(RabbitTemplate.class) - @ConditionalOnEnablednHealthIndicator("rabbit") + @ConditionalOnEnabledHealthIndicator("rabbit") public static class RabbitHealthIndicatorConfiguration extends CompositeHealthIndicatorConfiguration { @@ -245,7 +245,7 @@ public class HealthIndicatorAutoConfiguration { @Configuration @ConditionalOnBean(SolrServer.class) - @ConditionalOnEnablednHealthIndicator("solr") + @ConditionalOnEnabledHealthIndicator("solr") public static class SolrHealthIndicatorConfiguration extends CompositeHealthIndicatorConfiguration { @@ -261,7 +261,7 @@ public class HealthIndicatorAutoConfiguration { } @Configuration - @ConditionalOnEnablednHealthIndicator("diskspace") + @ConditionalOnEnabledHealthIndicator("diskspace") public static class DiskSpaceHealthIndicatorConfiguration { @Bean @@ -280,7 +280,7 @@ public class HealthIndicatorAutoConfiguration { @Configuration @ConditionalOnBean(JavaMailSenderImpl.class) - @ConditionalOnEnablednHealthIndicator("mail") + @ConditionalOnEnabledHealthIndicator("mail") public static class MailHealthIndicatorConfiguration extends CompositeHealthIndicatorConfiguration { @@ -298,7 +298,7 @@ public class HealthIndicatorAutoConfiguration { @Configuration @ConditionalOnBean(ConnectionFactory.class) - @ConditionalOnEnablednHealthIndicator("jms") + @ConditionalOnEnabledHealthIndicator("jms") public static class JmsHealthIndicatorConfiguration extends CompositeHealthIndicatorConfiguration { @@ -315,7 +315,7 @@ public class HealthIndicatorAutoConfiguration { @Configuration @ConditionalOnBean(Client.class) - @ConditionalOnEnablednHealthIndicator("elasticsearch") + @ConditionalOnEnabledHealthIndicator("elasticsearch") @EnableConfigurationProperties(ElasticsearchHealthIndicatorProperties.class) public static class ElasticsearchHealthIndicatorConfiguration extends CompositeHealthIndicatorConfiguration { diff --git a/spring-boot-actuator/src/main/java/org/springframework/boot/actuate/autoconfigure/OnEnabledHealthIndicatorCondition.java b/spring-boot-actuator/src/main/java/org/springframework/boot/actuate/autoconfigure/OnEnabledHealthIndicatorCondition.java index 2dba841ca6..2355200898 100644 --- a/spring-boot-actuator/src/main/java/org/springframework/boot/actuate/autoconfigure/OnEnabledHealthIndicatorCondition.java +++ b/spring-boot-actuator/src/main/java/org/springframework/boot/actuate/autoconfigure/OnEnabledHealthIndicatorCondition.java @@ -31,7 +31,7 @@ import org.springframework.core.type.AnnotatedTypeMetadata; */ class OnEnabledHealthIndicatorCondition extends SpringBootCondition { - private static final String ANNOTATION_CLASS = ConditionalOnEnablednHealthIndicator.class + private static final String ANNOTATION_CLASS = ConditionalOnEnabledHealthIndicator.class .getName(); @Override diff --git a/spring-boot-actuator/src/test/java/org/springframework/boot/actuate/autoconfigure/HealthIndicatorAutoConfigurationTests.java b/spring-boot-actuator/src/test/java/org/springframework/boot/actuate/autoconfigure/HealthIndicatorAutoConfigurationTests.java index 7695950ab9..a77ce1f878 100644 --- a/spring-boot-actuator/src/test/java/org/springframework/boot/actuate/autoconfigure/HealthIndicatorAutoConfigurationTests.java +++ b/spring-boot-actuator/src/test/java/org/springframework/boot/actuate/autoconfigure/HealthIndicatorAutoConfigurationTests.java @@ -122,7 +122,7 @@ public class HealthIndicatorAutoConfigurationTests { this.context.register(HealthIndicatorAutoConfiguration.class, ManagementServerProperties.class); EnvironmentTestUtils.addEnvironment(this.context, - "management.health.enabled:false", + "management.health.defaults.enabled:false", "management.health.diskspace.enabled:true"); this.context.refresh(); Map beans = this.context diff --git a/spring-boot/src/main/java/org/springframework/boot/context/embedded/AbstractConfigurableEmbeddedServletContainer.java b/spring-boot/src/main/java/org/springframework/boot/context/embedded/AbstractConfigurableEmbeddedServletContainer.java index 1b8f351e50..c7295ee0db 100644 --- a/spring-boot/src/main/java/org/springframework/boot/context/embedded/AbstractConfigurableEmbeddedServletContainer.java +++ b/spring-boot/src/main/java/org/springframework/boot/context/embedded/AbstractConfigurableEmbeddedServletContainer.java @@ -114,7 +114,7 @@ public abstract class AbstractConfigurableEmbeddedServletContainer implements } if (!contextPath.startsWith("/") || contextPath.endsWith("/")) { throw new IllegalArgumentException( - "ContextPath must start with '/ and not end with '/'"); + "ContextPath must start with '/' and not end with '/'"); } } } diff --git a/spring-boot/src/test/java/org/springframework/boot/context/embedded/AbstractEmbeddedServletContainerFactoryTests.java b/spring-boot/src/test/java/org/springframework/boot/context/embedded/AbstractEmbeddedServletContainerFactoryTests.java index fc37491cd0..bccafec2d6 100644 --- a/spring-boot/src/test/java/org/springframework/boot/context/embedded/AbstractEmbeddedServletContainerFactoryTests.java +++ b/spring-boot/src/test/java/org/springframework/boot/context/embedded/AbstractEmbeddedServletContainerFactoryTests.java @@ -245,14 +245,14 @@ public abstract class AbstractEmbeddedServletContainerFactoryTests { @Test public void contextPathMustStartWithSlash() throws Exception { this.thrown.expect(IllegalArgumentException.class); - this.thrown.expectMessage("ContextPath must start with '/ and not end with '/'"); + this.thrown.expectMessage("ContextPath must start with '/' and not end with '/'"); getFactory().setContextPath("missingslash"); } @Test public void contextPathMustNotEndWithSlash() throws Exception { this.thrown.expect(IllegalArgumentException.class); - this.thrown.expectMessage("ContextPath must start with '/ and not end with '/'"); + this.thrown.expectMessage("ContextPath must start with '/' and not end with '/'"); getFactory().setContextPath("extraslash/"); }