More predictable LevelDB latency, LevelDB write batching.

This commit is contained in:
JoelKatz
2013-05-12 21:33:08 -07:00
parent 0193c48bf8
commit 40355c7b58
5 changed files with 63 additions and 27 deletions

View File

@@ -88,14 +88,16 @@ public:
bool storeSQLite(HashedObjectType type, uint32 index, const std::vector<unsigned char>& data,
const uint256& hash);
HashedObject::pointer retrieveSQLite(const uint256& hash);
void bulkWriteSQLite();
#ifdef USE_LEVELDB
bool storeLevelDB(HashedObjectType type, uint32 index, const std::vector<unsigned char>& data,
const uint256& hash);
HashedObject::pointer retrieveLevelDB(const uint256& hash);
void bulkWriteLevelDB();
#endif
void bulkWrite();
void waitWrite();
void tune(int size, int age);
void sweep() { mCache.sweep(); mNegativeCache.sweep(); }