bvstone

MAILTOOL Updated to Support Multiple Mail Routers for Failover

Posted:

MAILTOOL Updated to Support Multiple Mail Routers for Failover

MAILTOOL has been updated to v10.70.  The main update for this version is allow the user to specify a file containing a list of mail routers (and other settings for the router) in case of a failure.

To use a mail router file you need to specify *STMF for the Mail Router (MAILRTR) paramter on the MAILTOOL command and on the Router Stream File(RTRSTMF) parameter you will specify either *DFT or the fully qualified path to the router file.

If you are using the MAILTOOL ILE functions you will set value mail_router to *STMF and set value mail_router_stmf to either *DFT or the fully qualified path to the router file.

Both options allow the use of *DFT for the mail router file setting.  This value will first search for the file:

/bvstools/mailtool/config/<USERID>/routers.json

If this file isn't found then MAILTOOL will look for:

/bvstools/mailtool/config/routers.json

The router file layout will consist of a JSON array that specifies 1 or more mail routers that you can use.

{
  "mail_routers": [
    {
      "mail_router": "first.smtp.mail.com",
      "from_email": "email@domain.com",
      "perform_mx_lookup": "*NO",
      "use_ssl": "*YES",
      "smtp_port" : "465",
      "smtp_auth_user" : "userid",
      "smtp_auth_password" : "password",
      "sequence": 10
    },
    {
      "mail_router": "second.smtp.mail.com",
      "from_email": "email@domain.com",
      "perform_mx_lookup": "*YES",
      "use_ssl": "*TLS",
      "smtp_port" : "587",
      "smtp_auth_user" : "userid",
      "smtp_auth_password" : "password",
      "sequence": 20
    }
  ]
}

The only required value in each JSON array element is the mail_router setting.  The rest of the settings are optional and will default to the value used on the command.

If any of the secondary mail routers use a different sign on id and password, the from_email, smtp_auth_user and smtp_auth_password should be specified in the mail router element.

The values of *G4G_XOAUTH and *G4MS_XOAUTH can be used for the smtp_auth_user value to specify to use OAuth 2.0 authentication for your Google or Outlook account, respectively.  In this case the smtp_auth_password value does not need to be set.

 


Last edited 03/11/2017 at 12:26:17



Latest Posts:

Token Has an Invalid Signature Error for Office 365 Email Token Has an Invalid Signature Error for Office 365 Email
Posted by 1 day ago
BVSTools >> BVSTools Software Discussion >> GreenTools for Microsoft Apps (G4MS) Specific Discussion
Resending Emails that have Errored Out with Updated Router or Authentication Information Resending Emails that have Errored Out with Updated Router or Authentication Information
Posted by March 1, 2019
BVSTools >> BVSTools Software Discussion >> Email Tools (MAILTOOL) Specific Discussion
BVSTools Offers Toolset to Work With HubSpot OAuth 2.0 APIs On Your IBM i BVSTools Offers Toolset to Work With HubSpot OAuth 2.0 APIs On Your IBM i
Posted by January 27, 2019
BVSTools >> BVSTools Announcements
G4MSDRV Currently Not Supported G4MSDRV Currently Not Supported
Posted by January 17, 2019
BVSTools >> BVSTools Announcements >> GreenTools for Microsoft Apps (G4MS) Specific Announcements
Removing Trailing Carriage Returns and/or Line Feeds from a String with RPG Removing Trailing Carriage Returns and/or Line Feeds from a String with RPG
Posted by December 26, 2018
Programming >> RPG Programming
Create QRCODE in DDS Create QRCODE in DDS
Posted by September 21, 2018
Programming >> RPG Programming
Base64 Encoding a File with RPG Base64 Encoding a File with RPG
Posted by September 6, 2018
Programming >> RPG Programming
Building JSON with RPG and YAJL and Writing to Standard Output Building JSON with RPG and YAJL and Writing to Standard Output
Posted by August 31, 2018
Programming >> Proof of Concept (POC)
How to Delete Files or Empty Trash From Your Google Drive with your IBM i and RPG/ILE How to Delete Files or Empty Trash From Your Google Drive with your IBM i and RPG/ILE
Posted by July 24, 2018
BVSTools >> BVSTools Software Discussion >> GreenTools for G Suite (Google Apps) (G4G) Specific Discussion
GreenTools for G Suite (G4G) Updated to Include Delete and Empty Trash Function GreenTools for G Suite (G4G) Updated to Include Delete and Empty Trash Function
Posted by July 24, 2018
BVSTools >> BVSTools Announcements >> GreenTools for G Suite (Google Apps) (G4G) Specific Announcements
What to Do If Your License Keys Don't Work What to Do If Your License Keys Don't Work
Posted by July 18, 2018
BVSTools >> BVSTools Software Discussion
MAILTOOL Updated to Allow Failed Message on Invalid Recipient MAILTOOL Updated to Allow Failed Message on Invalid Recipient
Posted by May 20, 2018
BVSTools >> BVSTools Announcements >> eMail Tool (MAILTOOL) Specific Announcements
Non HTTPS Callbacks Removed from GreenTools for G Suite (G4G) Non HTTPS Callbacks Removed from GreenTools for G Suite (G4G)
Posted by April 15, 2018
BVSTools >> BVSTools Announcements >> GreenTools for G Suite (Google Apps) (G4G) Specific Announcements
IBM i Related Survey Available IBM i Related Survey Available
Posted by April 7, 2018
IBM Power Systems >> (QGPL) IBM i
BVSTools Releases Braintree Webhook Open Source Application - Node.js BVSTools Releases Braintree Webhook Open Source Application - Node.js
Posted by April 5, 2018
Programming >> Open Source

Reply




Copyright 1983-2019 BVSTools
GreenBoard(v3) Powered by the eRPG SDK, MAILTOOL Plus!, GreenTools for Google Apps, jQuery, jQuery UI, BlockUI, CKEditor and running on the IBM i (AKA AS/400, iSeries, System i).