add batch run limit, close issue #2