Skip to content

Commit d8d8f9a

Browse files
committed
Log fix
1 parent 9fdefaa commit d8d8f9a

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

plugins/repository-s3/src/main/java/org/opensearch/repositories/s3/S3BlobContainer.java

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -256,9 +256,11 @@ public void asyncBlobUploadConditionally(
256256
);
257257
} catch (Exception ex) {
258258
logger.error(
259-
"Failed to conditionally upload large file {} of size {}",
260-
uploadRequest.getKey(),
261-
uploadRequest.getContentLength(),
259+
() -> new ParameterizedMessage(
260+
"Failed to conditionally upload large file {} of size {} ",
261+
uploadRequest.getKey(),
262+
uploadRequest.getContentLength()
263+
),
262264
ex
263265
);
264266
completionListener.onFailure(ex);
@@ -316,7 +318,7 @@ public void asyncBlobUploadConditionally(
316318
}
317319
}
318320
} catch (Exception e) {
319-
logger.info("Exception during conditional blob upload for file {}", writeContext.getFileName(), e);
321+
logger.info("Exception during conditional blob upload for file {}", writeContext.getFileName());
320322
throw new IOException(e);
321323
}
322324
}

0 commit comments

Comments
 (0)