SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6 - OCEJPAD 6
How To Ask Questions How To Answer Questions
Rob Spoor wrote:If the supplier has given you port number 110, that probably means that it's a POP server. Trying to use IMAP won't work then. Try asking the supplier if they support IMAP as well.
Regarding "new" status and POP, that should be maintained by the client. The client you're writing should keep track of (and store) which emails have already been encountered and which not. But yeah, if IMAP is available that would be better.
The secret of how to be miserable is to constantly expect things are going to happen the way that they are "supposed" to happen.
You can have faith, which carries the understanding that you may be disappointed. Then there's being a willfully-blind idiot, which virtually guarantees it.
Tim Holloway wrote:POP isn't a very powerful protocol compared to IMAP. If I'm not mistaken, it doesn't have folders or a query-based retrieval capability. Personally, I'd run an "nmap" on the POP server and see if IMAP/IMAPS is truly not an option, since a lot of the popular email servers these days support multiple protocols. And if IMAP or IMAPS is available, lean on them. It's to their own benefit ultimately.
Every email should have a Message-Id header in it. When you download an email, keep a database of these Message-Ids and only forward the ones you haven't yet added to the database. That's less resource-intensive than keeping the entire email on file. And the Message-ID is designed to be unique, just like UUID/GUIDs are - perhaps moreso, since UUIDs and GUIDs are hash values and the email ID may be 100% unique.
The secret of how to be miserable is to constantly expect things are going to happen the way that they are "supposed" to happen.
You can have faith, which carries the understanding that you may be disappointed. Then there's being a willfully-blind idiot, which virtually guarantees it.
Did you see how Paul cut 87% off of his electric heat bill with 82 watts of micro heaters? |