You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dolphinscheduler.apache.org by GitBox <gi...@apache.org> on 2022/08/01 13:40:06 UTC

[GitHub] [dolphinscheduler] jackfanwan commented on a diff in pull request #11033: [fix-10961][alert server]Change the content of alert to an array

jackfanwan commented on code in PR #11033:
URL: https://github.com/apache/dolphinscheduler/pull/11033#discussion_r934543576


##########
dolphinscheduler-alert/dolphinscheduler-alert-plugins/dolphinscheduler-alert-email/src/main/java/org/apache/dolphinscheduler/plugin/alert/email/EmailAlertChannel.java:
##########
@@ -38,6 +46,20 @@ public AlertResult process(AlertInfo info) {
         if (null == paramsMap) {
             return new AlertResult("false", "mail params is null");
         }
+        // Converts an object type to an array type to prevent subsequent conversions from reporting errors
+        if (StringUtils.isNotEmpty(alert.getContent())) {

Review Comment:
   > @jackfanwan why not just handle before `getTextTypeMessage`? Because I found the content of the Email Table type is defferent, see `getTableTypeMessage`.
   
   Excuse me, do I still need to make changes?



-- 
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.

To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org