: I would think you would see better performance by allowing auto commit : to handle the commit size instead of reopening the connection all the : time.
if your goal is "fast" indexing, don't use autoCommit at all ... just index everything, and don't commit until you are completely done. autoCommitting will slow your indexing down (the benefit being that more results will be visible to searchers as you proceed) -Hoss