Summary | Horde_Imap_Client_Data_Thread getRawData() |
Queue | Horde Framework Packages |
Type | Enhancement |
State | Resolved |
Priority | 1. Low |
Owners | mrubinsk (at) horde (dot) org |
Requester | mariusz.goch (at) spacja (dot) com |
Created | 08/20/2019 (2148 days ago) |
Due | |
Updated | 09/29/2019 (2108 days ago) |
Assigned | |
Resolved | 09/29/2019 (2108 days ago) |
Milestone | |
Patch | No |
commit a4ed34a22e7cf59d7af60a172cb8bcb4fcde445b
Author: Michael J Rubinsky <mrubinsk@horde.org>
Date: Sun, 29 Sep 2019 14:45:19 -0400
[mjr] Support returning entire thread list (
Ticket #14943,mariusz.goch@spacja.com).
M .horde.yml
M composer.json
M doc/Horde/Imap/Client/CHANGES
M doc/Horde/Imap/Client/changelog.yml
M package.xml
https://github.com/horde/Imap_Client/commit/a4ed34a22e7cf59d7af60a172cb8bcb4fcde445b
State ⇒ Resolved
commit 4fd4e120356b4a58053ab7b652cba0d4c04479d1
Author: Michael J Rubinsky <mrubinsk@horde.org>
Date: Sun, 29 Sep 2019 14:33:37 -0400
[mjr] Support returning entire thread list (
Ticket #14943,mariusz.goch@spacja.com).
M doc/Horde/Imap/Client/CHANGES
M package.xml
https://github.com/horde/Imap_Client/commit/4fd4e120356b4a58053ab7b652cba0d4c04479d1
commit e43f7439c14817e893f4ea62a94d49db18b27ac7
Author: Michael J Rubinsky <mrubinsk@horde.org>
Date: Sun, 29 Sep 2019 14:33:37 -0400
[mjr] Support returning entire thread list (
Ticket #14943,mariusz.goch@spacja.com).
M doc/Horde/Imap/Client/changelog.yml
https://github.com/horde/Imap_Client/commit/e43f7439c14817e893f4ea62a94d49db18b27ac7
commit 8fe3c993496325cf94b2f99869283ba3878c0915
Author: Michael J Rubinsky <mrubinsk@horde.org>
Date: Sun, 29 Sep 2019 14:32:31 -0400
Ticket: 14943Support returning entire thread list.mariusz.goch@spacja.com
M lib/Horde/Imap/Client/Data/Thread.php
https://github.com/horde/Imap_Client/commit/8fe3c993496325cf94b2f99869283ba3878c0915
commit 15f5250ff0f7e8d40c1d401c862f2285ca50d33f
Author: Michael J Rubinsky <mrubinsk@horde.org>
Date: Sun, 29 Sep 2019 14:30:41 -0400
Ticket: 14943Support returning entire thread list.mariusz.goch@spacja.com
M lib/Horde/Imap/Client/Data/Thread.php
https://github.com/horde/Imap_Client/commit/15f5250ff0f7e8d40c1d401c862f2285ca50d33f
New Attachment: thread_getThreads.patch
threads with summary. User than can pick one to view all messages in
this conversation. After user picks anything getThread() works fine
but there was a problem presenting whole list of threads. In fact I''m
presenting last 50 but IMAP does not allow paging in thread so I've
managed this on my own. Thankfully horde cache kicks in.
Anyway. II'm attaching patch with getThreads() method that result with
same array of threads with the same structures that are returned from
getThread().
Best regards
Assigned to Michael Rubinsky
options passed to Horde_Imap_Client_Base::thread().
threads one by one.
You shouldn't have to fetch anything else from the server after the
call to $imapOb->thread() to get UUIDs.
Horde_Imap_Client_Data_Thread::messageList() will return the (sorted)
list of all UUIDs that matched the search option in the thread() call.
While this list doesn't give you the thread structure, it would be
fairly easy to construct it by iterating once through the messageList().
Not sure exactly what your use case is here for having access to the
entire mailbox's thread sort like this, but I can see where they may
be some value in having that data exposed. I'd consider a patch that
outputs this as a more formal structure.
When I want to show all threads there is now easy way.
getThread() requires UID. So first I've got to fetch all messages to
get UIDs, then fetch threads one by one.
In this usage getThread() is really a performance issue because in
each call it go through whole array.
In mailbox that has few thousand messages should I call few thousand
times getThread() and any single time getThread() will search through
whole cached array.
Instead getThread() there could be getThreads() that will return same
structure for all threads.
If this would be acceptable I will be happy to provide a patch.
State ⇒ Rejected
was released. The data that getRawData() would expose is considered
internal to the class. The data structure may change, be improved
etc.... exposing it publicly introduces restrictions on what we can
change without breaking backwards compatibility.
Patch ⇒ No
State ⇒ New
Milestone ⇒
Queue ⇒ Horde Framework Packages
Summary ⇒ Horde_Imap_Client_Data_Thread getRawData()
Type ⇒ Enhancement
Priority ⇒ 1. Low
method any more?? There was one some time ago, before internal format
changed.
Now you can only iterate through getThread() and every time it's
called there is a loop across all threads. It's OK when I just want to
show information about one thread but when I want to show all threads
in a list in large mailboxes it's a real performance issue.
Simple getRawData() returning internal data would allow to customize this.