Fix Micrometer tag providers after HttpStatus changes
Since SPR-16898, `HttpStatus.toString()` has changed and we should instead rely on `HttpStatus.value()` to get the HTTP status number.
This commit is contained in:
@@ -83,7 +83,7 @@ public final class WebClientExchangeTags {
|
||||
* @return the status tag
|
||||
*/
|
||||
public static Tag status(ClientResponse response) {
|
||||
return Tag.of("status", response.statusCode().toString());
|
||||
return Tag.of("status", String.valueOf(response.statusCode().value()));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -69,7 +69,7 @@ public final class WebFluxTags {
|
||||
if (status == null) {
|
||||
status = HttpStatus.OK;
|
||||
}
|
||||
return Tag.of("status", status.toString());
|
||||
return Tag.of("status", String.valueOf(status.value()));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user