We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3e30379 commit 4a9cef3Copy full SHA for 4a9cef3
1 file changed
prometheus/src/main/java/org/opensearch/sql/prometheus/client/PrometheusClientImpl.java
@@ -106,7 +106,8 @@ private JSONObject readResponse(Response response) throws IOException {
106
}
107
} else {
108
throw new RuntimeException(
109
- String.format("Request to Prometheus is Unsuccessful with : %s", response.message()));
+ String.format("Request to Prometheus is Unsuccessful with : %s", Objects.requireNonNull(
110
+ response.body(), "Response body can't be null").string()));
111
112
113
0 commit comments