Going back to snapshots
This commit is contained in:
@@ -122,7 +122,8 @@ public class TraceWebAutoConfiguration {
|
||||
String basePath = webEndpointProperties.getBasePath();
|
||||
String pattern = endpoints.stream().map(PathMappedEndpoint::getRootPath)
|
||||
.map(path -> path + "|" + path + "/.*")
|
||||
.collect(Collectors.joining("|", getPathPrefix(contextPath, basePath),
|
||||
.collect(Collectors.joining("|",
|
||||
getPathPrefix(contextPath, basePath),
|
||||
getPathSuffix(contextPath, basePath)));
|
||||
if (StringUtils.hasText(pattern)) {
|
||||
return Optional.of(Pattern.compile(pattern));
|
||||
@@ -148,8 +149,9 @@ public class TraceWebAutoConfiguration {
|
||||
|
||||
private static String getPathSuffix(String contextPath, String actuatorBasePath) {
|
||||
String result = ")";
|
||||
if (StringUtils.hasText(contextPath) || (StringUtils.hasText(actuatorBasePath)
|
||||
&& !"/".equals(actuatorBasePath))) {
|
||||
if (StringUtils.hasText(contextPath) ||
|
||||
(StringUtils.hasText(actuatorBasePath)
|
||||
&& !"/".equals(actuatorBasePath))) {
|
||||
result += ")?";
|
||||
}
|
||||
return result;
|
||||
|
||||
@@ -181,8 +181,7 @@ public class SkipPatternProviderConfigTest {
|
||||
.skipPattern();
|
||||
|
||||
then(pattern).isNotEmpty();
|
||||
then(pattern.get().pattern())
|
||||
.isEqualTo("foo(/|/(info|info/.*|health|health/.*))?");
|
||||
then(pattern.get().pattern()).isEqualTo("foo(/|/(info|info/.*|health|health/.*))?");
|
||||
}
|
||||
|
||||
@Test
|
||||
|
||||
Reference in New Issue
Block a user