How to make rust send a flush system call when writing data?

72 Views Asked by At

We know that Write::flush for on-disk file is actually a no-op. And BufWriter::flush also wont send flush system call in Linux. So, how to do?

Btw, I don't want to call mem::drop(file)

Because I want to write to mounted path with blobfuse. Blobfuse may be for the sake of perf, so the upload file is only available when close file. Refer: https://github.com/Azure/azure-storage-fuse/blob/master/blobfuse/fileapis.cpp#L346

0

There are 0 best solutions below