Compare commits

..

2 Commits

Author SHA1 Message Date
Carl Schwan 3caa1467b1 refactor: Improve log message
Co-authored-by: Josh <josh.t.richards@gmail.com>
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2026-03-02 13:19:08 +01:00
Robin Appelman 2c2335b8b4 fix: improve logging around failed chunked object store uploads
Signed-off-by: Robin Appelman <robin@icewind.nl>
2026-02-27 14:50:49 +01:00
2 changed files with 13 additions and 8 deletions
@@ -92,12 +92,7 @@ class CacheJail extends CacheWrapper {
protected function formatCacheEntry($entry) {
if (isset($entry['path'])) {
$jailedPath = $this->getJailedPath($entry['path']);
if ($jailedPath !== null) {
$entry['path'] = $jailedPath;
} else {
return false;
}
$entry['path'] = $this->getJailedPath($entry['path']);
}
return $entry;
}
@@ -800,14 +800,24 @@ 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,
'Unable to complete multipart upload for "' . $urn . '" (uploadId: "' . $writeToken . '")',
[
'app' => 'objectstore',
'exception' => $e,
]
);
try {
$this->objectStore->abortMultipartUpload($urn, $writeToken);
} catch (S3Exception $e) {
$this->logger->error(
'Unable to abort multipart upload for "' . $urn . '" (uploadId: "' . $writeToken . '") after completion error',
[
'app' => 'objectstore',
'exception' => $e,
]
);
}
throw new GenericFileException('Could not write chunked file');
}
return $size;