FastMail Enables IMAP Push for iOS
FastMail (via Gabe Weatherhead):
While our own app has had push notifications for some time, with the built-in Mail app you would have to wait until it next decided to check the server for your new messages. But no more! From today, new mail will be pushed straight to your inbox.
robn_fastmail (via Milen Dzhumerov):
IMAP “push” usually means the IDLE extension, where a client holds a connection open and waits for the server to report that something has happened. This works ok, but isn’t great on mobile because holding a TCP connection open is usually difficult on flaky networks and consumes battery.
iOS Mail doesn’t implement it, instead doing a poll every 15 minutes. However it also implements a separate push system which allows true push if the server supports it. The details on how to support this aren’t public information.
We talked to Apple, and they were kind enough to give us access to this system. We implemented it on our side, and now when an email arrives at FastMail we can immediately signal to Mail.app that there’s new mail available.
Emphasis added.
3 Comments RSS · Twitter
It's not entirely true that the Apple IMAP push system isn't public information. They do release the source code for their Dovecot patches used in OS X Server, and there are other implementations such as this one:
https://github.com/st3fan/dovecot-xaps-daemon
The only private part, if you can call it that, is a certificate to talk to the push server, which is contained in OS X Server as described above.
The Dovecot patch only does the IMAP part of the protocol. I wrote an equivalent patch for Cyrus, which is also open source:
https://git.cyrus.foundation/rIa4470bf0f79de49030b3d66d2b385a1345c1a040
The private part isn't just the certificate. There's actual protocol stuff back there too.