1
0
Fork 0

fix reading of initial tick values from RocksDB

This commit is contained in:
jsteemann 2017-04-28 14:28:13 +02:00
parent 12df8249b3
commit 502d3ee354
1 changed files with 2 additions and 4 deletions

View File

@ -229,10 +229,8 @@ void RocksDBCounterManager::readSettings() {
if (!result.empty()) {
try {
std::shared_ptr<VPackBuilder> builder = VPackParser::fromJson(result);
VPackSlice s = builder->slice();
uint64_t lastTick = basics::VelocyPackHelper::stringUInt64(s.get("tick"));
uint64_t lastTick = basics::VelocyPackHelper::stringUInt64(slice.get("tick"));
LOG_TOPIC(TRACE, Logger::ENGINES) << "using last tick: " << lastTick;
TRI_UpdateTickServer(lastTick);
} catch (...) {
LOG_TOPIC(WARN, Logger::ENGINES) << "unable to read initial settings: invalid data";