Topic awaiting preservation: Anyone used IMAP Proxy???? |
|
---|---|
Author | Thread |
Bipolar (III) Inmate From: you tell me |
posted 01-07-2009 17:08
Hi guys I was wondering has anyone used an IMAP Proxy like the one on http://www.imapproxy.org/. If so how do you set it up and how much of an improvement is it? |
Maniac (V) Mad Scientist with Finglongers From: Germany |
posted 01-08-2009 10:21
I don't even see why you'd use something like this? Seriously, login on an IMAP server |
Bipolar (III) Inmate From: you tell me |
posted 01-08-2009 21:32
Well its not me actually the project we are working on utilizes roundcube mail. And its really slow so we need to speed it up - my boss wants it to be almost as quick as outlook. The thing is that well outlook downlaods all emails to a local file system. The IMAP PROXY is just a temporary fix and so far we checked its only available for linux systems - DAYAM MICROSOFT AGAIN! |
Maniac (V) Mad Scientist with Finglongers From: Germany |
posted 01-09-2009 09:15
huh? by checking for each mail in the inbox if it's already in the database, if it isn't, upload it. Start going 'forwards' in time from the date of the newest message you have in the database. No deletion on the IMAP needed, I believe, and no chance of loosing messages. |
Bipolar (III) Inmate From: you tell me |
posted 01-10-2009 07:26
Hmm well teh idea is to clean up our IMAP server - the thing is that how do we implement the writing to the databse part i.e. retrieve message from inbox and write it to teh database. I mean theres teh risk of losing a connection or time out problems - lets like suppose and this is a common occurrence that we end up having almost 100s of emails coming in every 5 minutes. DOwnloading a 100 emails every minute is in itself a tall order which I don't think woudl be wise to be implemented using an ajax call. Any other way to do this? Like I heard about using a cron job or so - but how would I get about to do it - we're running on windows platform and whatever process we choose must be configurable in code. |
Bipolar (III) Inmate From: you tell me |
posted 01-12-2009 14:52
Come on guys I really need some ideas for this - Im running outta time my deadlines in 48 hours |
Bipolar (III) Inmate From: you tell me |
posted 01-12-2009 16:31
OK I have one idea - just tell me if its a good idea. Im thinking of having a simple script run in a hidden iframe. The script would downlaod all teh emails form the IMAP server and upon inserting it into the database it woudl out put some javascript which would refresh teh script in teh iframe again after X seconds to check for and download newer messages. |
Maniac (V) Mad Scientist with Finglongers From: Germany |
posted 01-12-2009 16:47
I am sorry parity, but you're teeming up this horse from the wrong end. |
Bipolar (III) Inmate From: you tell me |
posted 01-13-2009 08:57
Ok that pretty much set everything in perspective. So right now what I've done so far is pretty much separate the process of downloading emails into the db from the IMAP server from the actual mail program that reads teh db as though it was a mailbox. code: Get all emails from imap server - assuming that if an email exists it wasnt downloaded and deleted For each allemails as one email does the message id of this email exist btw? If yes donot download this email and move on else download this email If this email has attachments { download attachments and associate to teh email }else{ go on } // if we get till here then only would we delete the email delete the email from the imap server loop
|
Bipolar (III) Inmate From: you tell me |
posted 01-13-2009 09:27
There is one thing though - the downloading should check for new updates every few minutes - I dont think Windows scheduled task has anything that could be scheduled in such a short period... |
Maniac (V) Mad Scientist with Finglongers From: Germany |
posted 01-13-2009 14:39
though I don't believe your last point, you can either set up a task every x minutes, or have an 'eternally running' service that simply pauses for a few minutes each time (per mailbox!... next layer of looping...) (and get's restarted if it ever dies), but you are going to need to make sure that only one of them is running at a given time. |
Bipolar (III) Inmate From: you tell me |
posted 01-14-2009 18:02
Well I fixed it up as you stated - now I have two code snippets working one downloads the emails to the message db. The webclient just checks the db as usual and when it finds an email marked recent bingo it grabs it - the idea is to make this webmail client work as fast as possible. You might think its pretty unnecessary though but the end result is that after rigging it up to read from the database rather than an imap server and having an independent script called via a scheduled task every couple of minutes to populate the db with new emails - the speed is so amazing it even beats outlook! |
Obsessive-Compulsive (I) Inmate From: |
posted 02-06-2013 21:25
I know this is a bit old, but I am using imapproxy in a web-app environment. Configuring it just involved filling in the blanks in the config file, and it has significantly improved the performance i.e: first thing in the morning it takes about 15 seconds to connect to the server, but subsequent connections are more or less immediate. |