mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2026-12-04 18:17:16 +01:00
filer: keep the chunks of a forwarded append whose outcome is unknown
The owner may have committed before its reply was lost, and with separate per-filer stores the local lookup may not see that commit yet, so deleting the chunks it does not find can strip a committed append. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
ce70eaed69
commit
af08337006
1 file changed
+3
-1
@@ -563,7 +563,9 @@ func (fs *FilerServer) saveMetaData(ctx context.Context, r *http.Request, fileNa
|
||||
case routed && errors.Is(dbErr, filer_pb.ErrPreconditionFailed):
|
||||
replyerr = fmt.Errorf("entry %s changed during append; retry the request", path)
|
||||
case routed:
|
||||
uncommittedChunks = fs.inlineAppendChunksNotReferenced(ctx, util.FullPath(path), uncommittedChunks)
|
||||
// The owner may have committed before the reply was lost, and a
|
||||
// separate local store may not hold that commit yet.
|
||||
uncommittedChunks = nil
|
||||
case inlineAppendConverted:
|
||||
uncommittedChunks = fs.inlineAppendChunksNotReferenced(ctx, util.FullPath(path), mergedChunks)
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user