Hi All,
For my application , I need to create a utlity batch file which will create the lucene index file from database (DB2).
I have tried quite a few things, my configuration (hbm xml) looks like : <property name="connection.url">jdbc:db2://appDB:50000/DBDATA</property> <property name="connection.username">user</property> <property name="connection.password">password</property> <property name="connection.driver_class">com.ibm.db2.jcc.DB2Driver</property> <property name="hibernate.dialect">org.hibernate.dialect.DB2Dialect</property> <property name="hibernate.transaction.factory_class">org.hibernate.transaction.JTATransactionFactory</property> <property name="hibernate.transaction.manager_lookup_class"> org.hibernate.transaction.WebSphereExtendedJTATransactionLookup</property> <property name="jta.UserTransaction">java:comp/UserTransaction</property> <property name="hibernate.connection.release_mode">after_statement</property> <property name="hibernate.transaction.auto_close_session">true</property> <property name="hibernate.search.default.indexBase">C:/luceneIndexes</property>
I am not very much sure if I can use JTA transacations here . But if I switch to JDBC transaction , the hibernate code to populate indexes fails,as I am using ScrollableResults.
Any help will be appreciated .TIA.
|