20 #include <ripple/basics/contract.h>
21 #include <ripple/nodestore/Factory.h>
22 #include <ripple/nodestore/Manager.h>
42 open(
bool createIfMissing)
override
139 return std::make_unique<NullBackend>();
Holds a collection of configuration values.
Base class for backend factories.
void open(bool createIfMissing) override
Open the backend.
static NullFactory nullFactory
int fdRequired() const override
Returns the number of file descriptors the backend expects to need.
virtual void erase(Factory &factory)=0
Remove a factory.
std::unique_ptr< Backend > createInstance(size_t, Section const &, std::size_t, Scheduler &, beast::Journal) override
Create an instance of this factory's backend.
int getWriteLoad() override
Estimate the number of write operations pending.
void setDeletePath() override
Remove contents on disk upon destruction.
Status fetch(void const *, std::shared_ptr< NodeObject > *) override
Fetch a single object.
void close() override
Close the backend.
void storeBatch(Batch const &batch) override
Store a group of objects.
void for_each(std::function< void(std::shared_ptr< NodeObject >)> f) override
Visit every object in the database This is usually called during import.
virtual void insert(Factory &factory)=0
Add a factory.
std::pair< std::vector< std::shared_ptr< NodeObject > >, Status > fetchBatch(std::vector< uint256 const * > const &hashes) override
Fetch a batch synchronously.
A generic endpoint for log messages.
Scheduling for asynchronous backend activity.
std::string getName() override
Get the human-readable name of this backend.
std::string getName() const override
Retrieve the name of this factory.
Status
Return codes from Backend operations.
Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.
static Manager & instance()
Returns the instance of the manager singleton.
void store(std::shared_ptr< NodeObject > const &object) override
Store a single object.
bool isOpen() override
Returns true is the database is open.
A backend used for the NodeStore.