mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2025-12-20 03:59:49 +08:00
filer: option to create file only if it is new, O_EXCL
This commit is contained in:
@@ -139,7 +139,7 @@ func (fs *FilerServer) CreateEntry(ctx context.Context, req *filer_pb.CreateEntr
|
||||
FullPath: fullpath,
|
||||
Attr: filer2.PbToEntryAttribute(req.Entry.Attributes),
|
||||
Chunks: chunks,
|
||||
})
|
||||
}, req.OExcl)
|
||||
|
||||
if err == nil {
|
||||
fs.filer.DeleteChunks(garbages)
|
||||
|
||||
Reference in New Issue
Block a user