Remove String.formatter from DefaultServerRequestObservationConvention
Closes gh-30218
This commit is contained in:
parent
5609e67100
commit
5ba6944145
|
|
@ -84,7 +84,7 @@ public class DefaultServerRequestObservationConvention implements ServerRequestO
|
|||
public String getContextualName(ServerRequestObservationContext context) {
|
||||
String httpMethod = context.getCarrier().getMethod().toLowerCase();
|
||||
if (context.getPathPattern() != null) {
|
||||
return "http %s %s".formatted(httpMethod, context.getPathPattern());
|
||||
return "http " + httpMethod + " " + context.getPathPattern();
|
||||
}
|
||||
return "http " + httpMethod;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -84,7 +84,7 @@ public class DefaultServerRequestObservationConvention implements ServerRequestO
|
|||
public String getContextualName(ServerRequestObservationContext context) {
|
||||
String httpMethod = context.getCarrier().getMethod().name().toLowerCase();
|
||||
if (context.getPathPattern() != null) {
|
||||
return "http %s %s".formatted(httpMethod, context.getPathPattern());
|
||||
return "http " + httpMethod + " " + context.getPathPattern();
|
||||
}
|
||||
return "http " + httpMethod;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue