ChenSammi commented on PR #699: URL: https://github.com/apache/ratis/pull/699#issuecomment-1200938843
> @ChenSammi , thanks for working on this. Async flush is a very good idea! Some thoughts > > * We should support unsafe flush since the existing unsafe flush still has a better performance than async flush. @SincereXIA , do you need unsafe flush if we have the async flush provided here? > > * Async flush needs to honor stateMachineDataPolicy; otherwise, it is unsafe. @szetszwo The stateMachineDataPolicy is controlled by raft.server.log.statemachine.data.sync. When it's true, state machine will be flushed before it reaches raft log write and flush. When it's false, the current sync flush is unsafe too. Since we have defined the raft.server.log.statemachine.data.sync to control the state machine data flush, we can just focus on the write log flush with .async-flush.enabled property. Otherwise, maybe we should merge this two property into one to guarantee a safe flush of both state machine data and log data with sync and async two modes. What do you think? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
