Add logging to DirectDataLoader and do periodic commits.