dailidong commented on a change in pull request #2402: simplify and optimize 
config
URL: 
https://github.com/apache/incubator-dolphinscheduler/pull/2402#discussion_r408649782
 
 

 ##########
 File path: 
dolphinscheduler-alert/src/main/java/org/apache/dolphinscheduler/alert/template/AlertTemplateFactory.java
 ##########
 @@ -30,25 +27,13 @@
 
     private static final Logger logger = 
LoggerFactory.getLogger(AlertTemplateFactory.class);
 
-    private static final String alertTemplate = 
PropertyUtils.getString(Constants.ALERT_TEMPLATE);
-
     private AlertTemplateFactory(){}
 
     /**
      * get a template from alert.properties conf file
      * @return a template, default is DefaultHTMLTemplate
      */
     public static AlertTemplate getMessageTemplate() {
-
-        if(StringUtils.isEmpty(alertTemplate)){
-            return new DefaultHTMLTemplate();
-        }
-
-        switch (alertTemplate){
 
 Review comment:
   I think we can add simpleTextTemplate again in the future, not complicated

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to