Cap the metadata record batch import

MongoDB has a threshold on the amount of data that can be sent in a
connection. Since some of the dumps are ready completely into memory
that threshold was hit.

Hence, I am slicing up the metadata record arrays into chucks that are
then imported. For now it is just an arbitrary value (4,000).

Signed-off-by: Konrad Reiche <konrad.reiche@gmail.com>