diff --git a/dolphinscheduler-alert/dolphinscheduler-alert-plugins/dolphinscheduler-alert-http/src/main/java/org/apache/dolphinscheduler/plugin/alert/http/HttpSender.java b/dolphinscheduler-alert/dolphinscheduler-alert-plugins/dolphinscheduler-alert-http/src/main/java/org/apache/dolphinscheduler/plugin/alert/http/HttpSender.java index 90280e802020..9c407e753660 100644 --- a/dolphinscheduler-alert/dolphinscheduler-alert-plugins/dolphinscheduler-alert-http/src/main/java/org/apache/dolphinscheduler/plugin/alert/http/HttpSender.java +++ b/dolphinscheduler-alert/dolphinscheduler-alert-plugins/dolphinscheduler-alert-http/src/main/java/org/apache/dolphinscheduler/plugin/alert/http/HttpSender.java @@ -91,9 +91,9 @@ private void paramsValidator(Map paramsMap) { throw new IllegalArgumentException("contentType is not a valid value"); } - timeout = StringUtils.isNotBlank(paramsMap.get(HttpAlertConstants.NAME_TIMEOUT)) + timeout = (StringUtils.isNotBlank(paramsMap.get(HttpAlertConstants.NAME_TIMEOUT)) ? Integer.parseInt(paramsMap.get(HttpAlertConstants.NAME_TIMEOUT)) - : HttpAlertConstants.DEFAULT_TIMEOUT * 1000; + : HttpAlertConstants.DEFAULT_TIMEOUT) * 1000; } public AlertResult send(String msg) {