20 #ifndef RIPPLE_NODESTORE_BATCHWRITER_H_INCLUDED
21 #define RIPPLE_NODESTORE_BATCHWRITER_H_INCLUDED
23 #include <ripple/nodestore/Scheduler.h>
24 #include <ripple/nodestore/Task.h>
25 #include <ripple/nodestore/Types.h>
Batch-writing assist logic.
void performScheduledTask() override
Performs the task.
CondvarType mWriteCondition
Derived classes perform scheduled tasks.
virtual void writeBatch(Batch const &batch)=0
This callback does the actual writing.
Scheduling for asynchronous backend activity.
~BatchWriter()
Destroy a batch writer.
virtual ~Callback()=default
Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.
int getWriteLoad()
Get an estimate of the amount of writing I/O pending.
BatchWriter(Callback &callback, Scheduler &scheduler)
Create a batch writer.
void store(std::shared_ptr< NodeObject > const &object)
Store the object.
Callback & operator=(Callback const &)=delete