[bootstrap] Reduce the memory size consumed when bootstrap

When a tserver bootstraps, it loads all tablets metadata,
and finds out the maximum fs block id it has seen to notify
the block manager to avoid generating duplicate ids.
However, a tablet may contain a large number of blocks,
that means it consumes a large amount of memory when
tablets parellel loaded when tserver bootstrap.

This patch optimizes the tablet bootstrap to find the
maximum block id for a tablet without storing all the
block identifiers in the memory.

Change-Id: If4df35f63e99a3f8331da51114991515ea4ee496
Reviewed-on: http://gerrit.cloudera.org:8080/18924
Tested-by: Yingchun Lai <acelyc1112009@gmail.com>
Reviewed-by: Alexey Serbin <alexey@apache.org>
5 files changed