Uploaded image for project: 'iBatis for Java [READ ONLY]'
  1. iBatis for Java [READ ONLY]
  2. IBATIS-752

Db connections hanged on rollback statement of push and pop connection from pool

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 2.3.4
    • None
    • Core
    • None

    Description

      ibatis-2.3.4.726.jar
      ===============

      SimpleDataSource.popConnection()

      if (conn != null) {
      if (conn.isValid()) {
      if (!conn.getRealConnection().getAutoCommit())

      { conn.getRealConnection().rollback(); }

      SimpleDataSource.pushConnection()

      if (!conn.getRealConnection().getAutoCommit())

      { conn.getRealConnection().rollback(); }

      -----------------------------------------------------------------------------------

      i m using a thread pool to fetch data in parallel from a table but under heavy load all my threads locks on push and pop connections and one thread locks the pool while doing rollback from push connection. why are we doing rollback on push and pop connection and is there anyway to workaround this?

      i have set
      <property name="JDBC.DefaultAutoCommit" value="true"/>
      but that only creates connection with auto commit true once i run a statement autocommit is set as false.

      Code which sets autocommit false is
      JdbcTransaction.init()

      // AutoCommit
      if (connection.getAutoCommit())

      { connection.setAutoCommit(false); }

      Am i doing something wrong. i m stuck on this as i cant use iBatis connection pool under heavy data fetch/load because connection pool is becoming the bottleneck. Please advise.

      Attachments

        Activity

          People

            Unassigned Unassigned
            niketuec@yahoo.com Niket Arora
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: