Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

The MailTo transport supports sending messages (E-Mail) over SMTP and receiving messages over POP3 or IMAP. This transport implementation is available as a module of the WS-Commons Transports project. 

...

Code Block
languagehtml/xml
<transportSender name="mailto" class="org.apache.axis2.transport.mail.MailTransportSender">
    <parameter name="mail.smtp.host">smtp.gmail.com</parameter>
    <parameter name="mail.smtp.port">587</parameter>
    <parameter name="mail.smtp.starttls.enable">true</parameter>
    <parameter name="mail.smtp.auth">true</parameter>
    <parameter name="mail.smtp.user">synapse.demo.0</parameter>
    <parameter name="mail.smtp.password">mailpassword</parameter>
    <parameter name="mail.smtp.from">synapse.demo.0@gmail.com</parameter>
</transportSender>
Note

Be sure to import the SSL certificate of your SMTP host server (specified by the mail.smtp.host parameter) to the client trust store of your ESB. The ESB will use the trusted certificates in this client trust store to validate the identity of the SMTP server.

When importing the certificate, be sure to use a certificate alias that is relevant to your server. For example, if you are using Gmail, use 'smtp.gmail.com' as the certificate alias. See the instructions on importing certificates to a keystore.

The MailTo transport sender is generally configured globally so that all services can share the same transport sender configuration.

...