set max batch size to avoid sql overflows