Hi, I spent a whole day trying to make "batchSize" work for JdbcDataSource with "org.postgresql.Driver", but got frustrated. At last I took a look into DIH's source code and found that there's actually a bug in there. When JDBC driver is placed in <solr-home>/lib (as instructed by DIHQuickStart page of Solr wiki), but not in tomcat's lib directory, the JDBC connection will not be configured as specified in the DIH configuration at all. Attributes like autoCommit, readOnly and batchSize will be ignored. The fix is simple, have attached my patch. (contrib/dataimporthandler/src/main/java/org/apache/solr/handler/dataimport/JdbcDataSource.java r817524)
One work-around is: place your JDBC driver jar under tomcat's application lib directory. e.g., tomcat/webapps/solr/WEB-INF/lib/ Have only tested with postgresql drivers, but seems the problem is generic to all drivers placed in <solr-home>/lib. Regards, Steve