Announcement Announcement Module
No announcement yet.
After commiting the transaction data not getting updated in database even no error Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • After commiting the transaction data not getting updated in database even no error

    Hi All,
    We're using DataSourceTransactionManager for implementing transaction management in our Spring-MVC 2.5 application.
    Its been felt that at few times even after committing the transaction explicitly through the code, the transaction is not getting committed (But not throwing any exception).
    Following is the snipped of code (how we are committing the transaction) :-

    xml file
    <bean id="dataSource" class="org.springframework.jndi.JndiObjectFactoryB ean">
    <property name="jndiName" value="jdbc/DBNAME"/>

    <bean id="txManager" class="org.springframework.jdbc.datasource.DataSou rceTransactionManager">
    <property name="dataSource" ref="dataSource"/>

    <bean id="JdbcDao" abstract="true" class=" eJdbcDaoSupport">
    <property name="dataSource" ref="dataSource"/>

    <bean id="abcController" class="com.ControllerClass">
    <property name="sessionForm" value="false"/>
    <property name="commandName" value="abcController"/>
    <property name="commandClass" value="com.CommandClass"/>
    <property name="formView" value="OutFile"/>
    <property name="successView" value="ResultFile"/>
    <property name="abcServices" ref="abcServices"/>

    <bean id="abcServices" class="com.ServiceClass">
    <property name="abcDao" ref="abcDao"/>
    <property name="pm" ref="txManager"/>

    <bean id="abcDao" class="com.DaoClass" parent="JdbcDao">
    <property name="CalculationService" ref="CalculationService"/>

    <bean id="CalculationService" class="com.CalculationService" parent="JdbcDao" />
    Controller class has following code for trnsaction management:-

    TransactionDefinition def = new DefaultTransactionDefinition(TransactionDefinition .PROPAGATION_REQUIRED);

    TransactionStatus status =;

    <//lot of code goes in here, then;>;

    Can anybody plz help in putting light on as to why some of the times transaction is not getting committed, while it is getting committed some times.
    Thanks in advance

  • #2
    Wrong forum, you need the Spring Web forum