Skip to content

Commit

Permalink
Fix excessive logging for S3 stream skipping.
Browse files Browse the repository at this point in the history
  • Loading branch information
gmagnu committed Dec 11, 2024
1 parent e5c0022 commit 2e903a2
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -74,10 +74,10 @@ public void close() throws IOException {
if (missingBytes < SKIP_BYTES_THRESHOLD) {
// If we are close to the end, skip the rest (to avoid aborting)
long skipped = s3is.skip(missingBytes);
logger.warn("S3 stream, not all bytes read, skipping {} ({}) bytes out of {} bytes.", skipped, missingBytes, maxBytes);
logger.debug("S3 stream, not all bytes read, skipping {} ({}) bytes out of {} bytes.", skipped, missingBytes, maxBytes);
s3is.close();
} else {
logger.warn("S3 stream, not all bytes read, aborting S3 input stream. {} bytes not read, of {} bytes.", missingBytes, maxBytes);
logger.debug("S3 stream, not all bytes read, aborting S3 input stream. {} bytes not read, of {} bytes.", missingBytes, maxBytes);
s3is.abort();
}
} else {
Expand Down

0 comments on commit 2e903a2

Please sign in to comment.