[Kde-pim] [gsoc] Akonadi global outbox (was: Re: gsoc project: akonadi for pop3 and smtp)

Constantin Berzan exit3219 at gmail.com
Mon Mar 30 01:21:54 BST 2009


Hi all,

A while ago I sent in a draft proposal for separating the composer component 
from KMail and putting it into a standalone library.  Here is an updated 
version.  I've decided to focus on the Akonadi global outbox, since that and a 
composer library make for a complete solution.  This leaves the GUI to be 
separated and shared later.

A summary of what has changed:
What stayed:
* create message composing engine in a standalone library.
What went in:
* finish the mail dispatcher agent and make the composer lib use it.
What went out:
* separate GUI from KMail.
* port KMail to use the new message composing library (made optional due to 
time constraints, but I really hope to get it done).

As always, I'd appreciate any feedback.  Also, do you think it is written 
clearly enough for people who are unfamiliar with kdepim/Akonadi?

Thanks,
Constantin



Complete proposal follows.
=====================================================================


Abstract:

A global outbox is a shared Akonadi collection that application can put their 
emails into, and Akonadi will take care of sending them. This reduces code 
duplication, provides convenient centralized control, and allows applications 
to send email without having to load a full instance of KMail. My project is 
to implement a standalone mail composing library based on KMime, a global 
outbox collection and mail dispatcher agent for Akonadi, and to begin porting 
applications to this new framework.



Background / Motivation:

Currently KMail, KNode, and Mailody all have their own code for composing and 
sending messages. KNode and Mailody use KMime, while KMail still uses the 
antiquated mimelib. There is unnecessary duplication on four levels: the MIME 
library, the message builder, the mail sending code, and the composer GUI. On 
top of that, when a non-email application such as Amarok needs to send an 
email (such as a backtrace in case of a crash), it needs to launch a full 
instance of KMail to do that.
[current.png]
My project aims to solve these problems by creating a standalone message 
composing library that all applications can use. Once built, the messages will 
be dropped in an outbox collection. A mail dispatcher agent will watch this 
collection and automatically send all mail dropped into it. A plasmoid will 
provide easy interaction with the outbox and dispatcher agent.
Aside from reducing code duplication and making sending email much more 
convenient, this project opens the way for porting KMail to KMime, and 
splitting it into standalone, reusable parts. Plans for the future include 
separating the composer GUI from KMail, and sharing it with KNode, as well as 
having a standalone reader component and GUI.
[after.png]



Implementation Details:

Akonadi lingo:
Collection - holds pim data and other child collections, much like a folder on 
a file system.
Agent - a process which does something with Akonadi data, e.g. an agent that 
deletes old RSS articles.

Architecture:
* A standalone message composing library using KMime. This will probably be 
based on the current composer in Mailody, and Mailody will be ported to use 
this library. To ensure that this component is solid and well-tested, a suite 
of unit tests will be written.
* A global outbox collection in Akonadi. This is where the message builder 
will store the messages to be sent. Other applications can drop messages to 
this outbox as well (such as backtraces from Amarok, or event invitations from 
KOrganizer).
* A mail dispatcher agent in Akonadi, using the mailtransport library. Its job 
is to monitor the outbox and send (dispatch) the messages dropped in there. 
Ingo Klöcker has written a skeleton for this in playground/pim.
* A plasma applet to interact with the global outbox and dispatcher agent. The 
user will be able to see the messages to be sent, and cancel / edit them if 
they want. Potential errors will also be displayed here.

Optional goals:
* Port KMail and KNode to use the global outbox.
* Port KNode to use the new message composing library.
* Port KMail to use the new message composing library. This might be time-
intensive because currently, KMail's message builder and composer GUI are 
somewhat tied together.
* Separate the composer GUI from KMail, and share it with KNode.
* Add a DBus interface for sending email (will be more useful once the GUI is 
shared).

A subset of these goals will be achieved, depending on the remaining time 
available after implementing the main goals.



Tentative Timeline:

Now - May 22:
Study Mailody and Akonadi code and come up with an initial plan.
Read about MIME.
Do the Akonadi tutorials.
Begin designing the message composing library.
Discuss projected design with mentor and kdepim/Akonadi developers.

May 23 - July 6:
Code the global outbox collection.
Finish the mail dispatcher agent.
Port Mailody to use the global outbox for sending emails.
Begin work on the message composing library.

July 7 - August 10:
Finish the message composing library.
Write unit tests for the message composing library.
Port Mailody to use this new library.
Code plasmoid to interact with the outbox.
Weigh the remaining time and implement some of the optional goals.

August 11 - August 17:
Clean up code.
Improve unit tests and documentation.



About Me:

I am studying Computer Science at Tufts University. I have been using KDE 
since 2005, contributing sporadically since 2007 (mostly summers when I have 
the time). Since 2008 I am maintaining KCharSelect, where I have fixed some 
bugs and implemented some minor features. I am the developer of Konvert2Ogg 
[1], a sound conversion front end for audio book enthusiasts. I have also 
started a port of Filelight to KDE4 [2], but the project has stalled due to my 
lack of time and obsessive tinkering with the design. I am very well-versed in 
C++ and fairly well acquainted with Qt and kdelibs, as well as the open source 
development process. A KDE SoC project would be my largest contribution so 
far, and I am looking forward to spending my summer developing KDE.

[1] http://konvert2ogg.sourceforge.net/
[2] http://gitorious.org/projects/filelight-kde4port/

Coordinates:
email: exit3219 at gmail.com
IRC: exit
Now - May 10: Boston, USA, EDT (UTC-4)
May 10 - End: Moldova, EEST (UTC+3)

Other:
I have no other obligations during the summer, and I am planning to devote to 
GSoC full-time. I have submitted another proposal for KWin, but this project 
(global outbox with Akonadi) is my first choice. I am very excited to work on 
it if it gets accepted.


=====================================================================


-- 
http://ascending.wordpress.com/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: after.png
Type: image/png
Size: 18571 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-pim/attachments/20090329/4fa28654/attachment.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: current.png
Type: image/png
Size: 15659 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-pim/attachments/20090329/4fa28654/attachment-0001.png>
-------------- next part --------------
_______________________________________________
KDE PIM mailing list kde-pim at kde.org
https://mail.kde.org/mailman/listinfo/kde-pim
KDE PIM home page at http://pim.kde.org/


More information about the kde-pim mailing list