[#11923] Transaction issues with ajax.php
Summary Transaction issues with ajax.php
Queue Horde Base
Queue Version 5.0.2
Type Bug
State No Feedback
Priority 2. Medium
Owners
Requester it (at) wenn (dot) com
Created 12/28/2012 (143 days ago)
Due
Updated 04/17/2013 (33 days ago)
Assigned 01/09/2013 (131 days ago)
Resolved 04/17/2013 (33 days ago)
Attachments
Milestone
Patch No

History
04/17/2013 01:03:37 PM Jan Schneider State ⇒ No Feedback
 
04/03/2013 11:16:58 AM Jan Schneider Comment #5 Reply to this comment
Ping?
01/10/2013 12:10:38 AM it (at) wenn (dot) com Comment #4 Reply to this comment
So, I guess the question is - why are there remaining transactions 
when closing the connection?
Indeed, this i do not know, last time i looked on the old ticket i got 
stuck in the Storage Stack code.

When i have some time ile have to put some debug backtrace or 
error_log commands out to a log and analize what is happening unless 
anyone has any better ideas on how to do this.
01/09/2013 11:06:58 PM Michael Rubinsky Comment #3
Priority ⇒ 2. Medium
State ⇒ Feedback
Reply to this comment
So, I guess the question is - why are there remaining transactions 
when closing the connection?
12/28/2012 06:03:36 PM it (at) wenn (dot) com Comment #2 Reply to this comment
#pear/php/Horde/Db/Adapter/Base.php"

     /**
      * Reconnect to the db.
      */
     public function reconnect()
     {
         $this->disconnect();
         $this->connect();
     }

     /**
      * Disconnect from db.
      */
     public function disconnect()
     {
         $this->_connection = null;
         $this->_active = false;
     }

On disconnect or reconnect all transactions are voided on the DB, the 
transaction counter should be reset acordingly by adding the following 
to the end of the disconnect function.

         $this->_transactionStarted=0;
12/28/2012 05:10:39 PM it (at) wenn (dot) com Comment #1
State ⇒ Unconfirmed
Patch ⇒ No
Milestone ⇒
Queue ⇒ Horde Base
Summary ⇒ Transaction issues with ajax.php
Type ⇒ Bug
Priority ⇒ 3. High
Reply to this comment
There seems to be an issue with all ajax calls and the transaction 
handler for PDO.
The last time i had an issue with transactions it was related to 
#10978 but seems that was resolved.

[Fri Dec 28 16:28:30 2012] [error] [client 79.123.35.132] PHP Fatal 
error:  Uncaught exception 'PDOException' with message 'There is no 
active transaction' in 
/home/httpd/live/example.com/htdocs/pear/php/Horde/Db/Adapter/Base.php:655
Stack trace:\n#0 
/home/httpd/live/example.comm/htdocs/pear/php/Horde/Db/Adapter/Base.php(655)
PDO->commit()
#1 
/home/httpd/live/example.comhtdocs/pear/php/Horde/SessionHandler/Storage/Sql.php(77): 
Horde_Db_Adapter_Base->commitDbTransaction()
#2 
/home/httpd/live/example.com/htdocs/pear/php/Horde/SessionHandler/Storage/Stack.php(79)
Horde_SessionHandler_Storage_Sql->close()
#3 
/home/httpd/live/example.com/htdocs/pear/php/Horde/SessionHandler.php(154)
Horde_SessionHandler_Storage_Stack->close()
#4 [internal function]: Horde_SessionHandler->close()
#5 
/home/httpd/live/example.com/htdocs/pear/php/Horde/SessionHandler.php(117)
session_write_close()
#6 [internal function]: Horde_SessionHandler->__destruct()
#7 {main}\n  thrown in 
/home/httpd/live/example.com/htdocs/pear/php/Horde/Db/Adapter/Base.php 
on line 655

At the moment ive had to revert to memcached as the backend for 
session tracking instead of PDO as it seems to work fine but ultimatly 
this is not a solution.