GNOME Bugzilla – Bug 364766
The mmap patch for Camel
Last modified: 2009-01-07 06:24:50 UTC
Creating this bug as a tracker bug and will attach a patch.
Created attachment 75321 [details] [review] The mmap patch for Camel This is a combined patch with both the improved implementation of imap_update_summary and the mmap patch. It also contains a few bits that have been done by Matthew and me (GSlice, GMutex, etc etc replacements). It will therefore probably not work on a current Camel. I'm made this patch so that Matthew can take-out what he needs. This little patch also patches evolution-exchange to work with the mmap patch: http://pvanhoof.be/files/evolution_exchange__mmap_summary.diff
Note that this patch also removes meta-data support for folders in Camel as that support was created shortly after the mmap work, and I haven't yet found the time to remove the removal of it. Sorry ;) I guess that this situation can be restored by extracting the patch from the CVS service and reapplying it once done with this one. I remember it was not a large one, but that it accidently touched a lot parts that where near the mmap changes. So it had created quite a bit conficts (I simply decided to get rid of it, as I don't need the support for it in tinymail).
Note that 3th party vendors that create Camel providers must be informed when this change happens. One example is Brutus's evolution-brutus. I can (and probably will) soon create the patch for them. The changes aren't big, by the way. Look at the patch for evolution-exchange: basically rewriting those pieces of summary that are custom for the specific camel provider.
A small to do list for this (version of the) patch: o. Remove the Matthew/me specifics (thus removing and replacing the GMutex back into EMutex things) o. Or start from the patch that fejj prepared (I lost it, sorry) o. Removing or not removing the implementation of #364757 (improvements to the imap_update_summary function in camel-imap-folder.c) depending on whether or not it's desired o. Removing or not removing the protected (not really public, it doesn't have to be added to a public .h file) new api "camel_folder_summary_dump_mmap" depending on whether or not it's desired. o. Re-adding the meta-data support for folders o. Patch evolution-brutus to support this o. Merge the existing evolution-exchange patch (prepare it and test it) o. Patch review (will be a patches for evolution-data-server, evolution-exchange and evolution-brutus) o. Committing this in the for-it prepared branch (preferably also the evolution-exchange and evolution-brutus will have equal-named branches)
o. In the latest version the dump_mmap api is removed and embedded in the _save method (in a correct way that this time doesn't loose data cause existing info is still being mmapped).
Created attachment 75418 [details] [review] This doesn't finish the todo items, just a newer version than #75321
Created attachment 75419 [details] [review] More fixes (small memory leak)
Note that development on this is always-ongoing. In case somebody starts working on bringing this patch to Evolution, feel free to contact me for the latest version and the latest improvements.
Marking as obsolete, due to the recent summary-db work