mirror of https://gitee.com/bigwinds/arangodb
Fixed return value of cache rebalancer in a few spots. (#3967)
This commit is contained in:
parent
635f11884a
commit
5e3b5526d0
|
@ -33,5 +33,5 @@ int Rebalancer::rebalance() {
|
|||
if (_manager != nullptr) {
|
||||
return _manager->rebalance();
|
||||
}
|
||||
return false;
|
||||
return TRI_ERROR_INTERNAL;
|
||||
}
|
||||
|
|
|
@ -317,8 +317,8 @@ TEST_CASE("cache with backing store", "[cache][!hide][longRunning]") {
|
|||
bool doneRebalancing = false;
|
||||
auto rebalanceWorker = [&rebalancer, &doneRebalancing]() -> void {
|
||||
while (!doneRebalancing) {
|
||||
bool rebalanced = rebalancer.rebalance();
|
||||
if (rebalanced) {
|
||||
int status = rebalancer.rebalance();
|
||||
if (status != TRI_ERROR_ARANGO_BUSY) {
|
||||
std::this_thread::sleep_for(std::chrono::milliseconds(500));
|
||||
} else {
|
||||
std::this_thread::sleep_for(std::chrono::microseconds(100));
|
||||
|
|
Loading…
Reference in New Issue