cryptoe commented on code in PR #15176:
URL: https://github.com/apache/druid/pull/15176#discussion_r1368687200
##########
server/src/main/java/org/apache/druid/client/JsonParserIterator.java:
##########
@@ -185,8 +185,15 @@ private void init()
} else if (nextToken == JsonToken.START_OBJECT) {
throw convertException(jp.getCodec().readValue(jp,
QueryException.class));
} else {
+ String errMsg = jp.getValueAsString();
Review Comment:
Since jp.getValueAsString() can return null
```
Method that will try to convert value of current token to a String. JSON
Strings map naturally; scalar values get converted to their textual
representation. If representation can not be converted to a String value
(including structured types like Objects and Arrays and null token), default
value of null will be returned; no exceptions are thrown.
Since:
2.1
```
lets add a null check here.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]