Closes gh-10282
This commit is contained in:
Johnny Lim 2017-09-13 22:26:06 +09:00 committed by Stephane Nicoll
parent d89f3f9f2a
commit bd2d08bcd0
16 changed files with 21 additions and 33 deletions

View File

@ -116,8 +116,7 @@ is automatically set if you use the maven wrapper.
_Also see link:CONTRIBUTING.adoc[CONTRIBUTING.adoc] if you wish to submit pull requests,
and in particular please fill out the
https://support.springsource.com/spring_committer_signup[Contributor's Agreement]
before your first change, however trivial. (Or if you filed such an agreement already for
another project just mention that in your pull request.)_
before your first change, however trivial._
=== Building reference documentation

View File

@ -30,7 +30,7 @@ public class ConfigurationPropertiesReportEndpointProperties {
/**
* Keys that should be sanitized. Keys can be simple strings that the property ends
* with or regex expressions.
* with or regular expressions.
*/
private String[] keysToSanitize;

View File

@ -19,7 +19,7 @@ package org.springframework.boot.actuate.autoconfigure.endpoint.web;
import java.util.List;
/**
* Interface that provides path information for web mapped endpints.
* Interface that provides path information for web mapped endpoints.
*
* @author Phillip Webb
* @since 2.0.0

View File

@ -30,7 +30,7 @@ public class EnvironmentEndpointProperties {
/**
* Keys that should be sanitized. Keys can be simple strings that the property ends
* with or regex expressions.
* with or regular expressions.
*/
private String[] keysToSanitize;

View File

@ -16,9 +16,7 @@
package org.springframework.boot.actuate.autoconfigure.endpoint;
import org.junit.Rule;
import org.junit.Test;
import org.junit.rules.ExpectedException;
import org.springframework.boot.actuate.endpoint.DefaultEnablement;
import org.springframework.boot.actuate.endpoint.EndpointExposure;
@ -35,9 +33,6 @@ import static org.assertj.core.api.Assertions.assertThat;
*/
public class EndpointEnablementProviderTests {
@Rule
public ExpectedException thrown = ExpectedException.none();
@Test
public void defaultEnablementDisabled() {
EndpointEnablement enablement = getEndpointEnablement("foo",

View File

@ -36,7 +36,7 @@ import org.springframework.util.StringUtils;
import static org.assertj.core.api.Assertions.assertThat;
/**
* Integration tests for endpints over JMX.
* Integration tests for endpoints over JMX.
*
* @author Stephane Nicoll
* @author Andy Wilkinson

View File

@ -34,7 +34,7 @@ import static org.mockito.Mockito.mock;
/**
* Tests for {@link Neo4jHealthIndicatorAutoConfiguration}.
*
* @author Phillp Webb
* @author Phillip Webb
*/
public class Neo4jHealthIndicatorAutoConfigurationTests {

View File

@ -22,9 +22,7 @@ import java.util.List;
import javax.servlet.http.HttpServletRequest;
import org.assertj.core.api.AssertDelegateTarget;
import org.junit.Rule;
import org.junit.Test;
import org.junit.rules.ExpectedException;
import org.springframework.boot.actuate.autoconfigure.endpoint.web.EndpointPathProvider;
import org.springframework.boot.actuate.endpoint.annotation.Endpoint;
@ -43,9 +41,6 @@ import static org.assertj.core.api.Assertions.assertThat;
*/
public class EndpointRequestTests {
@Rule
public ExpectedException thrown = ExpectedException.none();
@Test
public void toAnyEndpointShouldMatchEndpointPath() throws Exception {
RequestMatcher matcher = EndpointRequest.toAnyEndpoint();

View File

@ -47,7 +47,7 @@ public class Sanitizer {
/**
* Keys that should be sanitized. Keys can be simple strings that the property ends
* with or regex expressions.
* with or regular expressions.
* @param keysToSanitize the keys to sanitize
*/
public void setKeysToSanitize(String... keysToSanitize) {

View File

@ -1094,7 +1094,7 @@ content into your application; rather pick only the properties that you need.
endpoints.configprops.cache.time-to-live=0 # Maximum time in milliseconds that a response can be cached.
endpoints.configprops.enabled= # Enable the configprops endpoint.
endpoints.configprops.jmx.enabled= # Expose the configprops endpoint as a JMX MBean.
endpoints.configprops.keys-to-sanitize=password,secret,key,token,.*credentials.*,vcap_services # Keys that should be sanitized. Keys can be simple strings that the property ends with or regex expressions.
endpoints.configprops.keys-to-sanitize=password,secret,key,token,.*credentials.*,vcap_services # Keys that should be sanitized. Keys can be simple strings that the property ends with or regular expressions.
endpoints.configprops.web.enabled= # Expose the configprops endpoint as a Web endpoint.
# ENDPOINT DEFAULT SETTINGS
@ -1106,7 +1106,7 @@ content into your application; rather pick only the properties that you need.
endpoints.env.cache.time-to-live=0 # Maximum time in milliseconds that a response can be cached.
endpoints.env.enabled= # Enable the env endpoint.
endpoints.env.jmx.enabled= # Expose the env endpoint as a JMX MBean.
endpoints.env.keys-to-sanitize=password,secret,key,token,.*credentials.*,vcap_services # Keys that should be sanitized. Keys can be simple strings that the property ends with or regex expressions.
endpoints.env.keys-to-sanitize=password,secret,key,token,.*credentials.*,vcap_services # Keys that should be sanitized. Keys can be simple strings that the property ends with or regular expressions.
endpoints.env.web.enabled= # Expose the env endpoint as a Web endpoint.
# FLYWAY ENDPOINT ({sc-spring-boot-actuator}/endpoint/FlywayEndpoint.{sc-ext}[FlywayEndpoint])

View File

@ -231,7 +231,7 @@ When a custom management context path is configured, the "`discovery page`" will
automatically move from `/application` to the root of the management context. For example,
if the management context path is `/management` then the discovery page will be available
from `/management`. When the management context path is set to `/` the discovery page
is disabled to prevent the possiblility of a clash with other mappings.
is disabled to prevent the possibility of a clash with other mappings.

View File

@ -2828,8 +2828,8 @@ you can configure `security.oauth2.resource.jwk.key-set-uri`. E.g. on PWS:
NOTE: Configuring both JWT and JWK properties will cause an error. Only one of `security.oauth2.resource.jwt.key-uri`
(or `security.oauth2.resource.jwt.key-value`) and `security.oauth2.resource.jwk.key-set-uri` should be configured.
WARNING: If you use the `security.oauth2.resource.jwt.key-uri` or `security.oauth2.resource.jwk.key-set-uri,
` the authorization server needs to be running when your application starts up. It will log a warning if it can't
WARNING: If you use the `security.oauth2.resource.jwt.key-uri` or `security.oauth2.resource.jwk.key-set-uri`,
the authorization server needs to be running when your application starts up. It will log a warning if it can't
find the key, and tell you what to do to fix it.
OAuth2 resources are protected by a filter chain with order

View File

@ -3,7 +3,6 @@ import groovy.io.FileType
import java.util.Properties
import org.springframework.core.io.InputStreamResource
import org.springframework.core.io.Resource
import org.springframework.core.type.AnnotationMetadata
import org.springframework.core.type.ClassMetadata
import org.springframework.core.type.classreading.MetadataReader
@ -72,10 +71,10 @@ MetadataReader createMetadataReader(MetadataReaderFactory factory, File classFil
}
TestSlice createTestSlice(Properties springFactories, ClassMetadata classMetadata, AnnotationMetadata annotationMetadata) {
new TestSlice(classMetadata.className, getImportedAutoConfiguration(springFactories, classMetadata, annotationMetadata))
new TestSlice(classMetadata.className, getImportedAutoConfiguration(springFactories, annotationMetadata))
}
Set<String> getImportedAutoConfiguration(Properties springFactories, ClassMetadata classMetadata, AnnotationMetadata annotationMetadata) {
Set<String> getImportedAutoConfiguration(Properties springFactories, AnnotationMetadata annotationMetadata) {
Set<String> importers = findMetaImporters(annotationMetadata)
if (annotationMetadata.isAnnotated('org.springframework.boot.autoconfigure.ImportAutoConfiguration')) {
importers.add(annotationMetadata.className)

View File

@ -28,7 +28,7 @@ import org.gradle.api.file.FileCollection;
import org.springframework.boot.loader.tools.MainClassFinder;
/**
* A {@link Callable} that provide a convention for the project's main class name.
* A {@link Callable} that provides a convention for the project's main class name.
*
* @author Andy Wilkinson
*/

View File

@ -69,7 +69,7 @@ public class EndpointMappingTests {
}
@Test
public void subPathWithoutALeadingSlashIsSeparaedFromBasePathBySingleSlash() {
public void subPathWithoutALeadingSlashIsSeparatedFromBasePathBySingleSlash() {
assertThat(new EndpointMapping("/test").createSubPath("one")).isEqualTo("/test/one");
}

View File

@ -104,7 +104,7 @@ public class ApplicationContextRequestMatcherTests {
static class TestApplicationContextRequestMatcher<C>
extends ApplicationContextRequestMatcher<C> {
private C provdedContext;
private C providedContext;
TestApplicationContextRequestMatcher(Class<? extends C> context) {
super(context);
@ -117,17 +117,17 @@ public class ApplicationContextRequestMatcherTests {
public C callMatchesAndReturnProvidedContext(HttpServletRequest request) {
matches(request);
return getProvdedContext();
return getProvidedContext();
}
@Override
protected boolean matches(HttpServletRequest request, C context) {
this.provdedContext = context;
this.providedContext = context;
return false;
}
public C getProvdedContext() {
return this.provdedContext;
public C getProvidedContext() {
return this.providedContext;
}
}