wood burning stoves 2.0*
The moose likes Other JSE/JEE APIs and the fly likes JavaMail and Lotus Notes chamber of secrets Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Other JSE/JEE APIs
Bookmark "JavaMail and Lotus Notes chamber of secrets" Watch "JavaMail and Lotus Notes chamber of secrets" New topic
Author

JavaMail and Lotus Notes chamber of secrets

Ashok Mash
Ranch Hand

Joined: Oct 13, 2000
Posts: 1936
Hi all,
This should be a simple one for you JavaMail Pros.
I have this application using JavaMail to send out emails (Purchase Orders, Invoices etc) and its working fine with Exchange Server.
At the same time, when I configured (I thought I did) it to send mails using Notes Server, its throwing Connection Exception: Connection Refused.
Here is the trace:
[ERROR] Connection refused;
nested exception is:
java.net.ConnectException: Connection refused
javax.mail.MessagingException: Connection refused;
nested exception is:
java.net.ConnectException: Connection refused
at com.sun.mail.imap.IMAPStore.protocolConnect(IMAPStore.java:298)
at javax.mail.Service.connect(Service.java:234)
at javax.mail.Service.connect(Service.java:135)

Notes server is running in a Solaris box, but it has SMTP service enabled and I already verified the availability of the server with sping and mconnect commands.
Any thoughts? Thanks in advance!
Ashok.


[ flickr ]
Lewin Chan
Ranch Hand

Joined: Oct 10, 2001
Posts: 214

at com.sun.mail.imap.IMAPStore.protocolConnect(IMAPStore.java:298)

Looks like you're trying to connect to the IMAP store, and not the SMTP service.
You could try telnetting onto your notes server, and doing a netstat -a and see if anything is listening on the IMAP port (143).
L


I have no java certifications. This makes me a bad programmer. Ignore my post.
Ashok Mash
Ranch Hand

Joined: Oct 13, 2000
Posts: 1936
Thanks Lewin,
I thought Lotus Notes works over IMAP by default and so IMAP service should be running by default!?!
Anyway, I will re-check that.
Cheers,
Ashok.
Ashok Mash
Ranch Hand

Joined: Oct 13, 2000
Posts: 1936
Originally posted by Lewin Chan:

You could try telnetting onto your notes server, and doing a netstat -a and see if anything is listening on the IMAP port (143).

Notes server is listening on IMAP port (143). I tried connecting a number of ways (different combination of domain+username), but no luck! Sending a simple SMTP mail is working with out a glitch.
Does any one has an example code of JavaMail actually connecting and fetching/sending mails using a Lotus Notes (Domino) Server?
Thanks in advance!
Ashok.
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: JavaMail and Lotus Notes chamber of secrets
 
Similar Threads
SMTP Connection Refused
SMTP Connection
Need some help me java mail-smtp
Could not connect to SMTP host: localhost, port: 25
Read emails from Microsoft Outlook Using Java Mail