mirror of
https://github.com/minio/minio.git
synced 2024-12-23 21:55:53 -05:00
canceled PUTs throw frivolous logs (#14475)
remote drives might throw frivolous logs, if the caller canceled the PUT operation in such scenarios there is no reason to log.
This commit is contained in:
parent
9b0a8de7de
commit
66afa16aed
@ -2039,7 +2039,8 @@ func skipAccessChecks(volume string) (ok bool) {
|
||||
// RenameData - rename source path to destination path atomically, metadata and data directory.
|
||||
func (s *xlStorage) RenameData(ctx context.Context, srcVolume, srcPath string, fi FileInfo, dstVolume, dstPath string) (err error) {
|
||||
defer func() {
|
||||
if err != nil {
|
||||
if err != nil && !contextCanceled(ctx) {
|
||||
// Only log these errors if context is not yet canceled.
|
||||
logger.LogIf(ctx, fmt.Errorf("srcVolume: %s, srcPath: %s, dstVolume: %s:, dstPath: %s - error %v",
|
||||
srcVolume, srcPath,
|
||||
dstVolume, dstPath,
|
||||
|
Loading…
Reference in New Issue
Block a user