CubDB.set_auto_file_sync
You're seeing just the function
set_auto_file_sync
, go back to CubDB module for more information.
Specs
set_auto_file_sync(GenServer.server(), boolean()) :: :ok
Configures whether to automatically force file sync upon each write operation.
If set to false
, no automatic file sync is performed. That improves write
performance, but leaves to the operative system the decision of when to flush
disk buffers. This means that there is the possibility that recent writes
might not be durable in case of a sudden machine shutdown. In any case,
atomicity of multi operations is preserved, and partial writes will not
corrupt the database.
If set to true
, the file buffer will be forced to flush upon every write
operation, ensuring durability even in case of sudden machine shutdowns, but
decreasing write performance.