Bug 295651

Summary: KMail2 consume large amount of memory when populating message list from a local maildir folder
Product: [Applications] kmail2 Reporter: LuRan <hephooey_dev>
Component: message listAssignee: kdepim bugs <kdepim-bugs>
Status: RESOLVED UNMAINTAINED    
Severity: normal    
Priority: NOR    
Version: Git (master)   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Linux   
Latest Commit: Version Fixed In:
Attachments: output of valgrind --tool=massif kmail

Description LuRan 2012-03-10 06:16:15 UTC
When I opened a folder with 260k messages, kmail2 used more than 3 G of memory before it is killed by oom, which is a lot comparing to kmail1 which only took about 300 M. The valgrind results seems to indicate most of the memory is used by Akonadi::ItemFetchJob, not sure if this is a similar issue like bug:258551 where the jobs never got deleted. You can find the valgrind --tool=massif output in the attachment.
Comment 1 LuRan 2012-03-10 06:25:44 UTC
Created attachment 69442 [details]
output of valgrind --tool=massif kmail

Sorry I have to gzip the log since it is bigger than 1M
Comment 2 Sergio Martins 2013-07-18 09:12:07 UTC
Git commit 815957a4a9ae567f271453aac222abf4c09900f9 by Sergio Martins.
Committed on 17/07/2013 at 09:45.
Pushed by smartins into branch 'KDE/4.11'.

mixedmaildir: don't use 1.5GB of memory when importing a very big folder

Subjobs pile up too fast because they are cheap to create and
because it's taking around 5 event loops for one to start.
Related: bug 260647, bug 317122, bug 309732, bug 307066

M  +41   -6    resources/mixedmaildir/retrieveitemsjob.cpp
M  +4    -2    resources/mixedmaildir/retrieveitemsjob.h

http://commits.kde.org/kdepim-runtime/815957a4a9ae567f271453aac222abf4c09900f9
Comment 3 Denis Kurz 2016-09-24 18:06:45 UTC
This bug has only been reported for versions before 4.14, which have been unsupported for at least two years now. Can anyone tell if this bug still present?

If noone confirms this bug for a Framework-based version of kmail2 (version 5.0 or later, as part of KDE Applications 15.12 or later), it gets closed in about three months.
Comment 4 Denis Kurz 2017-01-07 22:21:34 UTC
Just as announced in my last comment, I close this bug. If you encounter it again in a recent version (at least 5.0 aka 15.08), please open a new one unless it already exists. Thank you for all your input.