From: atulksh <do-...@jb...> - 2005-12-20 22:40:53
|
Okay. I have found how to resolve my issue. The original issue still remains. I had followed the jboss official documentation to setup the Oracle 9i data source. This tells to setup an xa datasource. http://docs.jboss.org/jbossas/getting_started/v4/html/db.html This was giving me the issue. My EJBs could write the data to the db but the transaction was not comitted by the container and the data was not reflected until I stop the server wherein all commits would seemingly be done and the data became visible. The data was not visible even to other ejbs in the application when the server was running. Then I thought of trying the normal datasource. So I followd the documentation on the wiki to setup a regular datasource. http://wiki.jboss.org/wiki/Wiki.jsp?page=SetUpAOracleDatasource And viola my application started to run fine. So the issue still remains why does the xa datasource behave that way? Am I missing some configuration that I need to do to tell it to commit? If anybody ever finds it out please do reply. For reference I am giving both ot the blocks of my configuration. this one works --- <local-tx-datasource> <jndi-name>dbPool</jndi-name> <use-java-context>false</use-java-context> <connection-url>jdbc:oracle:thin:@dbserver:1521:schema</connection-url> <driver-class>oracle.jdbc.driver.OracleDriver</driver-class> <user-name>user</user-name> pwd <min-pool-size>5</min-pool-size> <max-pool-size>20</max-pool-size> <!-- Checks the Oracle error codes and messages for fatal errors --> <exception-sorter-class-name>org.jboss.resource.adapter.jdbc.vendor.OracleExceptionSorter</exception-sorter-class-name> <type-mapping>Oracle9i</type-mapping> </local-tx-datasource> this one does not --- <xa-datasource> <jndi-name>dbPool</jndi-name> <use-java-context>false</use-java-context> <track-connection-by-tx>true</track-connection-by-tx> <isSameRM-override-value>false</isSameRM-override-value> <xa-datasource-class>oracle.jdbc.xa.client.OracleXADataSource</xa-datasource-class> <xa-datasource-property name="URL"> jdbc:oracle:thin:@dbserver:1521:schema </xa-datasource-property> <xa-datasource-property name="User">user</xa-datasource-property> <xa-datasource-property name="Password">pwd</xa-datasource-property> <exception-sorter-class-name> org.jboss.resource.adapter.jdbc.vendor.OracleExceptionSorter </exception-sorter-class-name> <no-tx-separate-pools/> </xa-datasource> View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3913673#3913673 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3913673 |