[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kmail-devel
Subject:    kmail and IMAP and startup (was imap performance issues)
From:       "Walter F.J. Mueller" <w.f.j.mueller () gsi ! de>
Date:       2001-04-21 22:18:59
[Download RAW message or body]

I updated today to the current KDE CVS snapshot and tried again kmail against
an IMAP server over a V.90 modem.

1. Observations:

   * After startup kmail inquires the list of toplevel folders. They appear
     quickly in the tree view window. All folders have initially 
     (+-) decoration in front.

   * kmail continues to IMAP4::listDir all folders, obviously to determine
     whether there are subfolders. For each processed folder the 
     (+-) decoration disappears when there are no subfolders.

     This scan of all folders takes quite some time, at least for me. There
     is no feedback (e.g. in status bar) as to when this scan has finished.
     
   * If one clicks on folders in the tree view during this scan of all 
     folders one gets the following behaviour (diagnosed with log messages 
     and tcpdump):

       -  first click on a folder -> no effect, scan continues
       -  second click -> scan stops
       -  third click -> message headers of this folder are loaded.

   * If the folder scan was aborted, the (+-) decorations of all
     the yet `unprocessed' folders stay visible. These folders can be opened,
     the message headers will be loaded and displayed. However, the list of
     subfolders is obviously not inquired. As a consequence, subfolders of
     those folders stay invisible.

   * If the initial folder scan was aborted, kmail sometimes crashes after
     some further folder open's. The traceback is appended.


2. Suggestions:

   * It should be sufficient to inquire about the toplevel folder when
     kmail starts. This is enough to setup the folder tree browser. Even
     though this usually completes quickly (even over a modem), it be helpful
     to have some sort of feedback, e.g. via the status bar.

   * It seems sufficient to determine the context of a folder when it is
     opened. At this point the subfolders as well as the current message ID's
     must be inquired. This allows to update the folder tree view in case
     subfolders are discovered (or in case they disappear!). It be helpful
     to signal this phase also in the status bar, e.g. with a message like
     'checking folder xyz'.

     Following this phase, the message headers, if not already cached, will
     be loaded (this is already signaled with a progress bar).


   With such a logic inconsistencies between the state of kmail and the
   actual state of the IMAP server are minimized and as a very welcome
   side effect the startup time is kept short.

			Cheers,	Walter


Traceback of a kmail crash (situation see above):
....
#4  0x411b9c71 in abort () from /lib/libc.so.6
#5  0x4115bf58 in __terminate () from /usr/lib/libstdc++-libc6.1-2.so.3
#6  0x4115bf75 in __terminate () from /usr/lib/libstdc++-libc6.1-2.so.3
#7  0x4115c960 in __unwinding_cleanup () from /usr/lib/libstdc++-libc6.1-2.so.3
#8  0x4115cb15 in __throw () from /usr/lib/libstdc++-libc6.1-2.so.3
#9  0x4115e6c6 in __builtin_vec_new () from /usr/lib/libstdc++-libc6.1-2.so.3
#10 0x40afb066 in QString::setLength () from /home/fsware/qt/lib/libqt.so.2
#11 0x40affca2 in QString::operator+= () from /home/fsware/qt/lib/libqt.so.2
#12 0x4048b8f2 in KIO::Slave::kill () from
/home/kde/KDE/kde-HEAD/lib/libkio.so.3
#13 0x811fdb1 in KMAcctImap::killAllJobs ()
#14 0x80920bc in KMFolderTree::doFolderSelected ()
#15 0x40d4054f in QListView::currentChanged () from
/home/fsware/qt/lib/libqt.so.2
#16 0x40c9dd7a in QListView::setCurrentItem () from
/home/fsware/qt/lib/libqt.so.2
#17 0x40c9b19f in QListView::contentsMousePressEvent () from
/home/fsware/qt/lib/libqt.so.2
#18 0x809494d in KMFolderTree::contentsMousePressEvent ()
#19 0x40ce6c61 in QScrollView::viewportMousePressEvent () from
/home/fsware/qt/lib/libqt.so.2
#20 0x40ce683d in QScrollView::eventFilter () from
/home/fsware/qt/lib/libqt.so.2
#21 0x40c9aa61 in QListView::eventFilter () from /home/fsware/qt/lib/libqt.so.2
#22 0x40bd7cb4 in QObject::activate_filters () from
/home/fsware/qt/lib/libqt.so.2
#23 0x40c3b76f in QWidget::event () from /home/fsware/qt/lib/libqt.so.2
....

--
Walter F.J. Mueller   Mail:  W.F.J.Mueller@gsi.de
GSI,  Abteilung KP3   Phone: +49-6159-71-2766
D-64291 Darmstadt     FAX:   +49-6159-71-2989
WWW:   http://www-kp3.gsi.de/www/kp3/people/mueller.html
PGP:   http://www-kp3.gsi.de/~mueller/pgp.shtml
_______________________________________________
Kmail Developers mailing list
Kmail@master.kde.org
http://master.kde.org/mailman/listinfo/kmail

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic