Details
Description
When using the URIs like this:
/sometable/*?limit=$limit&startrow=$startrow&endrow=$endrow
where $limit is smaller than the range between $startrow and $endrow, the rest server will start leaking memory.
The bug is in the TableScanResource.java class. Basically, the ResultScanner is not being closed in next() method when the limit has been reached.