Thanks Alec,
I know what u are doing with your code and also know that mine have
problem.

Anyway I have not seen issue in the normal ordering in the 0.2.
Probably your solution was great for complex ordering but for standard
ordering fetch 5000 messages make rc unusable.

It's a possible idea to fetch all messages only for complex ordering? Or
make a config variable for fast or better ordering?

I don't know the solution but if no change will be made I'll must change
imap client because unusable for me.

Hope in your idea.

Thanks and sorry for diff file.

On Tue, 08 Sep 2009 13:28:21 +0200, "A.L.E.C" <[email protected]> wrote:
> Sandro Pazzi wrote:
>> Hi all,
>> I have modified the code in the rcube_imap.php and the performance was
>> good. I post the code modified:
>> 
>> Original:
>>       $a_index = iil_C_FetchHeaderIndex($this->conn, $mailbox, "1:*",
>> $this->sort_field, $this->skip_deleted);
>>       list($begin, $end) = $this->_get_message_range(count($msg_index),
>> $page);
> 
>> Modified:
>>       $max = $this->_messagecount($mailbox,'ALL',true);
>>       list($begin, $end) = $this->_get_message_range($max, $page);
>>       
>>       $a_index = iil_C_FetchHeaderIndex($this->conn, $mailbox,
>> ($begin+1).":".$end, $this->sort_field, $this->skip_deleted);
> 
>> Can u please check for some errors or issue?
> 
> You don't understand. In our code we're fetching all messages headers 
> and we're sorting them by (e.g.) date first, then we're fetching a part 
> needed for the one list page.
> In your code, you're fetching only part of the list and you're sorting 
> that part not all messages. This is not proper because "default sorting"

> is not "sorting by date". This sometimes would be ok, but definetly not 
> when sorting by subject and even by date.
> 
> So, we'll not break things to get better performance.

-- 
Sandro Pazzi

IdWeb s.r.l.
Viale Romagna 69/A - 06012 Citta' di Castello (PG)
Tel. 075 851 97 28
Fax 075 851 97 30
_______________________________________________
List info: http://lists.roundcube.net/dev/

Reply via email to