mirror of
https://github.com/nextcloud/server.git
synced 2026-06-13 10:40:40 -04:00
fix: improve logging around failed chunked object store uploads
Signed-off-by: Robin Appelman <robin@icewind.nl>
This commit is contained in:
parent
fea2f67f38
commit
ccb1d9afa7
1 changed files with 11 additions and 1 deletions
|
|
@ -818,7 +818,6 @@ class ObjectStoreStorage extends Common implements IChunkedFileWrite {
|
|||
$this->getCache()->update($stat['fileid'], $stat);
|
||||
}
|
||||
} catch (S3MultipartUploadException|S3Exception $e) {
|
||||
$this->objectStore->abortMultipartUpload($urn, $writeToken);
|
||||
$this->logger->error(
|
||||
'Could not complete multipart upload ' . $urn . ' with uploadId ' . $writeToken,
|
||||
[
|
||||
|
|
@ -826,6 +825,17 @@ class ObjectStoreStorage extends Common implements IChunkedFileWrite {
|
|||
'exception' => $e,
|
||||
]
|
||||
);
|
||||
try {
|
||||
$this->objectStore->abortMultipartUpload($urn, $writeToken);
|
||||
} catch (S3Exception $e) {
|
||||
$this->logger->error(
|
||||
'Failed to abort multi-part upload for ' . $urn . ' with uploadId ' . $writeToken,
|
||||
[
|
||||
'app' => 'objectstore',
|
||||
'exception' => $e,
|
||||
]
|
||||
);
|
||||
}
|
||||
throw new GenericFileException('Could not write chunked file');
|
||||
}
|
||||
return $size;
|
||||
|
|
|
|||
Loading…
Reference in a new issue