code: public static final void setAutoCommit(final Connection connection, boolean autocommit) {
          try {
              connection.setAutoCommit(autocommit);
          } catch (Exception e) {
              if (LOG.isWarnEnabled())
                  LOG.warn("Error committing Connection: " + connection + " to: " + autocommit, e);
          }
      }
docs: Set auto commit state for the connection. Unlike the underlying connection.setAutoCommit(),
  this method does not throw SQLException or any other Exception. It fails silently from the
  perspective of calling code, logging any errors encountered using Commons Logging.
  
  @param connection
  @param autocommit