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:

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
BVSTools Now Offering Web Services (BETA) BVSTools Now Offering Web Services (BETA)
Posted by April 3, 2018
BVSTools >> BVSTools Announcements
Creating a Reverse SSL Proxy Using RPG on the IBM i - Part 2 Creating a Reverse SSL Proxy Using RPG on the IBM i - Part 2
Posted by March 29, 2018
Programming >> Web Programming
Still on V7R1 or Earlier?  Here's Why You Should Upgrade NOW! Still on V7R1 or Earlier? Here's Why You Should Upgrade NOW!
Posted by February 21, 2018
IBM Power Systems >> (QGPL) IBM i
Converting a MMDDYY date format to YYMMDD for Sorting Using SQL Converting a MMDDYY date format to YYMMDD for Sorting Using SQL
Posted by February 16, 2018
Programming >> RPG Programming
Moving All Files from a Google Drive Folder to the Trash Using GreenTools for Google Apps (G4G) Moving All Files from a Google Drive Folder to the Trash Using GreenTools for Google Apps (G4G)
Posted by February 3, 2018
BVSTools >> BVSTools Software Discussion >> GreenTools for G Suite (Google Apps) (G4G) Specific Discussion
Removing Unwanted Characters from a String with RPG Removing Unwanted Characters from a String with RPG
Posted by February 2, 2018
Programming >> RPG Programming
GETURI Version 8.10 Released GETURI Version 8.10 Released
Posted by January 23, 2018
BVSTools >> BVSTools Announcements >> Get URI (GETURI) Specific Announcements
BVSTools is Now a Sponsor of ALLAS400S.com BVSTools is Now a Sponsor of ALLAS400S.com
Posted by January 17, 2018
BVSTools >> BVSTools Announcements
Service Pack SP171219 Released for G4PP v3.10 Service Pack SP171219 Released for G4PP v3.10
Posted by December 20, 2017
BVSTools >> BVSTools Announcements >> GreenTools for PayPal (G4PP) Specific Announcements
GETURI Now Requires Minimum OS of V7R1 or Higher GETURI Now Requires Minimum OS of V7R1 or Higher
Posted by December 12, 2017
BVSTools >> BVSTools Software Discussion >> Get URI (GETURI) Specific Discussion
Need Help Updating Your Software Versions?  We Can Help. Need Help Updating Your Software Versions? We Can Help.
Posted by December 8, 2017
BVSTools >> BVSTools Announcements

Reply




Copyright 1983-2018 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).