hi,all:
  i have a question about the option "commitlog_sync" in cassandra.yaml 
file.when its value is set to "batch",the ICommitLogExecutorService instance of 
CommitLog will be BatchCommitLogExecutorService in which there is a method 
named processWithSyncBatch.and in this method,there is a code segment:
        while (!queue.isEmpty()
               && queue.peek().getRawCallable() instanceof 
CommitLog.LogRecordAdder
               && System.nanoTime() < end)
        {
            CheaterFutureTask task = queue.remove();
            incompleteTasks.add(task);
            taskValues.add(task.getRawCallable().call());
        }
task.getRawCallable().call() will call CommitLog.LogRecordAdder.run()  which 
does the same thing as appendingThread in PeriodicCommitLogExecutorService. we 
can see the task in the queue is excecuted one by one,use logWriter to do the 
write operaton, finally do sync when the commitlog_sync_batch_window_in_ms is 
up or the queue has no task,just as PeriodicCommitLogExecutorService. i don't 
understand where reflect the conception of "batch"? or the question can be what 
is the difference between PeriodicCommitLogExecutorService and 
BatchCommitLogExecutorService?
   Be expectingyourresponse! Thks very much.

Reply via email to