6.0.0-beta1
8/17/25

[#13043] Timeouts during as_state_map cleanup
Summary Timeouts during as_state_map cleanup
Queue Synchronization
Queue Version Git master
Type Bug
State Resolved
Priority 2. Medium
Owners jan (at) horde (dot) org
Requester hannes.brunssen (at) ewetel (dot) de
Created 03/12/2014 (4176 days ago)
Due
Updated 03/13/2014 (4175 days ago)
Assigned
Resolved 03/13/2014 (4175 days ago)
Github Issue Link
Github Pull Request
Milestone
Patch Yes

History
03/13/2014 11:30:36 AM Jan Schneider Assigned to Jan Schneider
State ⇒ Resolved
 
03/13/2014 11:30:32 AM Git Commit Comment #2 Reply to this comment
Changes have been made in Git (master):

commit 1467653f1536c355c2e2d9c63d46a327a63b8085
Author: Jan Schneider <jan@horde.org>
Date:   Thu Mar 13 12:30:20 2014 +0100

     [jan] Optimize SQL query for garbage collection 
(hannes.brunssen@ewetel.de, Bug #13043).

  .../ActiveSync/lib/Horde/ActiveSync/State/Sql.php  |    2 +-
  framework/ActiveSync/package.xml                   |    4 ++--
  2 files changed, 3 insertions(+), 3 deletions(-)

http://git.horde.org/horde-git/-/commit/1467653f1536c355c2e2d9c63d46a327a63b8085
03/12/2014 04:38:33 PM hannes (dot) brunssen (at) ewetel (dot) de Comment #1
Priority ⇒ 2. Medium
New Attachment: as_map_distinct.patch Download
Patch ⇒ Yes
Milestone ⇒
Queue ⇒ Synchronization
Summary ⇒ Timeouts during as_state_map cleanup
Type ⇒ Bug
State ⇒ Unconfirmed
Reply to this comment
We just found an ActiveSync-state with over 120k entries in the table 
horde_activesync_map. These entries could not be removed, because the 
garbage collector function tries to build a huge query which searches 
120k times for the same sync_key. The webserver processes were running 
at 100% for several minutes and finished with segfaults.

The attached patch fixes this problem by using DISTINCT in the query.

Saved Queries