Skip to content

Commit 2ef2baa

Browse files
committed
add code
1 parent 8b3e6ce commit 2ef2baa

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

server/odc-service/src/main/java/com/oceanbase/odc/service/connection/ConnectionService.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -893,8 +893,8 @@ public BinaryDataResult getBatchImportTemplateFile() throws IOException {
893893
if (input == null) {
894894
throw new UnexpectedException(DATASOURCE_TEMPLATE_FILE_NAME + " is not found");
895895
}
896-
byte[] buffer = new byte[input.available()];
897-
IOUtils.read(input, buffer);
896+
log.info("input.available(): " + input.available());
897+
byte[] buffer = IOUtils.toByteArray(input);
898898
return new ByteArrayDataResult(DATASOURCE_TEMPLATE_FILE_NAME, buffer);
899899
}
900900
}

0 commit comments

Comments
 (0)