Currently, the KuduScanner for the C++ client has an iteration API that always results in the following (verbose) code pattern:
On top of the extra avoidable LOCs, the client has to manage individual batches and clear the vector. This batching should be done internally by the scanner, probably in the same manner above, but only exposing a bool HasNext() and const KuduRowResult& GetNext() interface. The simpler interface has another advantage in that it would allow us to change the way we gather rows while keeping the implementation details away from the client.
See discussion below for further API considerations.