新增数据类型转换
This commit is contained in:
@@ -531,6 +531,10 @@ class LocalDataProcessStorage:
|
||||
|
||||
@staticmethod
|
||||
def _fsync_directory(directory: Path) -> None:
|
||||
# Windows 不支持以 O_RDONLY 打开目录做 fsync,跳过即可。
|
||||
# 数据完整性在 Linux 生产环境保障,Windows 开发环境忽略。
|
||||
if os.name == "nt":
|
||||
return
|
||||
descriptor = os.open(directory, os.O_RDONLY)
|
||||
try:
|
||||
os.fsync(descriptor)
|
||||
|
||||
Reference in New Issue
Block a user