Increase BATCH_SIZE to reduce no. of mongo conns. Add a MAX_BSON_SIZE - currently un-used.
Add flush debugging and basic validation for scanned strings.