We observed odd behavior regarding the operationResult object returned in the rebalance API:
- It contains success=false if the cluster has no regions or has no servers. This is confusing because the rebalance didn't fail — it just didn't have anything to rebalance so it was basically a no-op. As a consumer of this API, I need to be able to distinguish between "real" failures and this "no-op" failure, and I should not have to write code to parse the "statusMessage" to do that.
- Sometimes, success=true and other times success=false for the same statusMessage: "Distributed system has no regions that can be rebalanced." This is confusing because I don't know why it sometimes considers this a failure and other times considers it a success. If #1 above is fixed, then this would not be an issue because it would always return success=true for this particular statusMessage.
Here is an example of two confusing operationResults we observed: