public void cleanupZK(int numVersionsToLeave) {
    deleteOldBarrierVersions(numVersionsToLeave);
    deleteOldJobModels(numVersionsToLeave);
  }
cleanup old data from ZK
@param numVersionsToLeave - number of versions to leave
samza-core/src/main/java/org/apache/samza/zk/ZkUtils.java