Roger Duluth wrote:
> I have application that connects to a mailbox using IMAP. It polls
> periodically for new messages and replies back to email using SMTP. Is it
> possible to two different SMTP servers in the same application?
>
> I’m using currently using function Session.getInstance(props) to get session
> instance.
You can connect to multiple SMTP servers by using multiple Transport objects
that you manage explicitly, rather than depending on the Transport.send
static method. If the servers need drastically different configurations,
you might want to use multiple Sessions.
===========================================================================
To unsubscribe, send email to
listserv@... and include in the body
of the message "signoff JAVAMAIL-INTEREST". For general help, send email to
listserv@... and include in the body of the message "help".