Report the write load for SQLite too.

This commit is contained in:
JoelKatz
2013-06-13 21:08:02 -07:00
parent 111951cc52
commit a349b9bcd0

View File

@@ -243,6 +243,7 @@ bool HashedObjectStore::storeSQLite(HashedObjectType type, uint32 index,
void HashedObjectStore::bulkWriteSQLite(Job&)
{
assert(!mLevelDB);
int setSize = 0;
while (1)
{
std::vector< boost::shared_ptr<HashedObject> > set;
@@ -257,8 +258,11 @@ void HashedObjectStore::bulkWriteSQLite(Job&)
if (set.empty())
{
mWritePending = false;
mWriteLoad = 0;
return;
}
mWriteLoad = std::max(setSize, static_cast<int>(mWriteSet.size()));
setSize = set.size();
}
// WriteLog (lsTRACE, HashedObject) << "HOS: writing " << set.size();