Bluehost.com Web Hosting $6.95

Re: [courier-users] Mail event notifications

This is a discussion on Re: [courier-users] Mail event notifications within the Courier-Imap forums, part of the Mail Servers and Related category; This is a MIME GnuPG-signed message. If you see this text, it means that your E-mail or Usenet ...


Go Back   Usenet Forums > Mail Servers and Related > Courier-Imap

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 10-06-2005
Sam Varshavchik
 
Posts: n/a
Default Re: [courier-users] Mail event notifications

This is a MIME GnuPG-signed message. If you see this text, it means that
your E-mail or Usenet software does not support MIME signed messages.
The Internet standard for MIME PGP messages, RFC 2015, was published in 1996.
To open this message correctly you will need to install E-mail or Usenet
software that supports modern Internet standards.

--=_mimegpg-commodore.email-scan.com-26947-1128552555-0002
Content-Type: text/plain; format=flowed; charset="US-ASCII"
Content-Disposition: inline
Content-Transfer-Encoding: 7bit

Greg Cawthorn writes:
>
> When one of our messaging subscribers receives a new message, we want to
> send them a Message Waiting Indicator (MWI) notification, which appears
> as an icon on a mobile phone or a stutter tone on a landline. When the
> message is read or deleted, we want to be able to clear the MWI from the
> phone. Since we may have several thousand subscribers per deployment we
> do not want our application to keep mail store connections open for each
> mailbox to be notified of new messages or changes to message flags. We
> are looking for a way to build a server-side agent for Courier that will
> receive triggers for all such message status changes in all mailboxes,
> from which we can then fire off a trigger to our application via
> something like a SOAP call.


Multiple folders in a mailbox, each one of which could have an unread
message in it, rather complicates this scenario. I think you're better off
monitoring only INBOX for unread messages.

After the scope of your situation is thusly reduced, I can think of a couple
of ways to implement something like this. There's nothing in Courier that
can do this, but it is not impossible to develop something this for your
custom application.

Provided, of course, that you get someone who knows what he's doing, to code
it. You need to execute a tiny program after delivering each message, and
you also need to modify the IMAP server's code to monitor what's going on in
INBOX. This presents a number of race conditions that you need to be aware
of, and understand. That's why you should give this job only to someone
with message background and experience, who knows what he is doing.

Basically, the message delivery agent needs to send a message to a
persistent daemon process: "DELIVERED to mailbox X". And the IMAP server
needs will be generating "UNREAD messages in INBOX of X is now n" and
"CHECKED for new mail in INBOX, and the number of UNREAD messages in INBOX
of X is now n". The persistent daemon handles these messages; updates the
state of each X's mailbox internally, and generates the message-waiting
events.

The reason you need different kinds of messages from the server, is to
properly handle race conditions. An IMAP server does not constantly monitor
for new messages in a folder, but only when instructed so. Therefore you
can have the mail delivery agent report that it delivered a new message to a
folder, you then flip on the MWI bit. Then, the IMAP server reports that it
thinks there are 0 unread messages; but it doesn't know about the new
message, because it hasn't checked for it.

Again, you need someone with messaging and networking experience, who
understands mail protocols, to implement this. It's not impossible, but
tricky. And I'm presently employed full time :-)




--=_mimegpg-commodore.email-scan.com-26947-1128552555-0002
Content-Type: application/pgp-signature
Content-Transfer-Encoding: 7bit

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.7 (GNU/Linux)

iD8DBQBDRFhrx9p3GYHlUOIRAkUfAJ45zD3WXflxRUmDXBkRj+ wuopzY8QCcCwHB
9TKICyN6W5D9nzj/KKY9eg8=
=zSJt
-----END PGP SIGNATURE-----

--=_mimegpg-commodore.email-scan.com-26947-1128552555-0002--


-------------------------------------------------------
This SF.Net email is sponsored by:
Power Architecture Resource Center: Free content, downloads, discussions,
and more. http://solutions.newsforge.com/ibmarch.tmpl
_______________________________________________
courier-users mailing list
courier-users@lists.sourceforge.net
Unsubscribe: https://lists.sourceforge.net/lists/.../courier-users
Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT +1. The time now is 03:22 PM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0