This week's book giveaway is in the General Computing forum.
We're giving away four copies of Arduino in Action and have Martin Evans, Joshua Noble, and Jordan Hochenbaum on-line!
See this thread for details.
The moose likes Other JSE/JEE APIs and the fly likes Javamail IMAP connection to exchange just hangs Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


JavaRanch » Java Forums » Java » Other JSE/JEE APIs
Reply Bookmark "Javamail IMAP connection to exchange just hangs" Watch "Javamail IMAP connection to exchange just hangs" New topic
Author

Javamail IMAP connection to exchange just hangs

Moshe Bar-Nachoom
Greenhorn

Joined: Dec 31, 2011
Posts: 1
hi,
i'm trying to connect to an Exchange server in my company's HQ. The server has a web interface and this is the one I'm using to also connect (successfully) through android exchange clients - say it's https://xxx.yyy.com.
So I was trying to use the JavaMail API to connect to the exchange server using the IMAP store. When I run the code, on connection attempt, the code just hangs there. It looks frozen. Does nothing.
I also tried sniffing it out with Wireshark and it looks it goes through the handshaking process just fine. And then... nothing.
Please help. here's the code:

The debugger prints: "DEBUG: trying to connect to host "xxx.yyy.com", port 443, isSSL true" and then... just sits there... doing nothing... waiting... i don't know.

The user name is as proposed by the documentations: "DOMAIN\\DomainUser\\Mail.User(Without domain.com extension)"
Thanks guys. Looking forward to your help.

Moshe
James Boswell
Ranch Hand

Joined: Nov 09, 2011
Posts: 657
    
    2

Hi Moshe

Does the code terminate or sit idle? Also, I wouldn't leave the catch block empty.
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: Javamail IMAP connection to exchange just hangs
 
Similar Threads
error in retrieving mail through a proxy.
IMAP/TLS Problem in connecting using java mail api.
IMAP /TLS standalone programm works fine, in Tomcat fails.
how to read inbox using javamail from microsoft exchange server through proxy server?
JavaMail and security