private MailManager getMailManager(AppContext appContext) {
        Config config = appContext.getConfig();
        String host = config.getParameter(ExtConfig.MAIL_SMTP_HOST);
        String port = config.getParameter(ExtConfig.MAIL_SMTP_PORT);
        String userName = config.getParameter(ExtConfig.MAIL_USERNAME);
        String password = config.getParameter(ExtConfig.MAIL_PASSWORD);
        String adminAddress = config.getParameter(ExtConfig.MAIL_ADMIN_ADDR);
        boolean sslEnabled = config.getParameter(ExtConfig.MAIL_SSL_ENABLED, true);
        return new SMTPMailManagerImpl(host, port, userName, password, adminAddress, sslEnabled);
    }
@author Robert HG (254963746@qq.com)  on 2/17/16.
lts-core/src/main/java/com/github/ltsopensource/alarm/email/EmailAlarmNotifier.java