bugfix
cleanup in rebalancer and planner