[ https://issues.apache.org/jira/browse/SOLR-812?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12655615#action_12655615 ]
Shalin Shekhar Mangar commented on SOLR-812: -------------------------------------------- bq. Certainly exposing these and the above in JdbcDataSource via properties would be more flexible to users. But sensible defaults should be set for read-only. Any extra attributes that you specify to the <dataSource> element are passed on to the DriverManager in a Properties object. So if your driver supports url parameters for these optimizations, you can use them right now. However, each driver has a different way of specifying this configuration, so we should support a way of making them configurable. I'm not very comfortable with making changes to the default configuration for the sake of backwards-compatibility. But we should make these possible and document their usage. > JDBC optimizations: setReadOnly, setMaxRows > ------------------------------------------- > > Key: SOLR-812 > URL: https://issues.apache.org/jira/browse/SOLR-812 > Project: Solr > Issue Type: Improvement > Components: contrib - DataImportHandler > Affects Versions: 1.3 > Reporter: David Smiley > > I'm looking at the DataImport code as of Solr v1.3 and using it with Postgres > and very large data sets and there some improvement suggestions I have. > 1. call setReadOnly(true) on the connection. DIH doesn't change the data so > this is obvious. > 2. call setAutoCommit(false) on the connection. (this is needed by Postgres > to ensure that the fetchSize hint actually works) > 3. call setMaxRows(X) on the statement which is to be used when the > dataimport.jsp debugger is only grabbing X rows. fetchSize is just a hint > and alone it isn't sufficient. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.