JNSimba commented on code in PR #91:
URL:
https://github.com/apache/doris-spark-connector/pull/91#discussion_r1161387749
##########
spark-doris-connector/src/main/java/org/apache/doris/spark/DorisStreamLoad.java:
##########
@@ -162,8 +120,10 @@ private HttpPut getHttpPut(String label, String
loadUrlStr) {
.filter(entry ->
!"read_json_by_line".equals(entry.getKey()))
.forEach(entry -> httpPut.setHeader(entry.getKey(),
entry.getValue()));
}
- if (fileType.equals("json")) {
+ if (dataFormat.getType().equalsIgnoreCase(FormatEnum.json.name())) {
httpPut.setHeader("strip_outer_array", "true");
+ //to solve the error : The size of this batch exceed the max size
[104857600] of json type data. Split the file, or use 'read_json_by_line'
+ httpPut.setHeader("read_json_by_line","true");
Review Comment:
The default maximum input of jsonarray is 100MB (be.conf:
streaming_load_json_max_mb ), maybe you can add a maximum byte limit
--
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]