Complete.Org: Mailing Lists: Archives: offlineimap: May 2008:
Re: offlineimap optimisations
Home

Re: offlineimap optimisations

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: offlineimap@xxxxxxxxxxxx
Cc: martin f krafft <madduck@xxxxxxxxxxx>
Subject: Re: offlineimap optimisations
From: John Goerzen <jgoerzen@xxxxxxxxxxxx>
Date: Tue, 13 May 2008 08:06:09 -0500

On Tue May 13 2008 3:49:37 am martin f krafft wrote:
> also sprach martin f krafft <madduck@xxxxxxxxxxx> [2008.05.13.0945 +0100]:
> > 1. offlineimap *churns* through PIDs. I know the programme uses
> >    threads, but in my understanding, threads don't eat PIDs, only
> >    forks do. So what is it doing, consuming somewhere in the
> >    vicinity of 100 PIDs per minute?
>
> I've stand corrected. It makes me want to think that offlineimap
> should really be working threadlessly though. There's been an
> interesting discussion on #debian-devel on this:
>
>  
> http://git.debian.org/?p=netconf/netconf.git;a=blob;f=ref/irclog-2008.01.1
>6-no-polling-no-threads;hb=HEAD
> http://git.debian.org/?p=netconf/netconf.git;a=blob;f=ref/irclog-2008.01.2
>2-more-no-threads-and-timeouts;hb=HEAD

I haven't pored through these entire logs (can you point me to the 
interesting bits?).  I did actually rewrite OfflineIMAP using Twisted at one 
point.  The extreme crappiness of imaplib.py motivated me to do that.

Twisted led to a rather unmaintainable mess that was impossible to debug.  It 
did sort of work, but it was more complex than OfflineIMAP is now, hard to 
follow, and hard to debug.

I still have dreams of rewriting OfflineIMAP in Haskell, which has a very 
nice lightweight thread system -- when using that type of threads, 
everything lives in one OS thread, and it uses select/poll internally, but 
presents a standard-looking interface to the programmer.

It would also let me get rid of that festering heap that is imaplib.py.

Whether that will ever happen, who knows...

-- John



[Prev in Thread] Current Thread [Next in Thread]