{"record":{"id":"cbef0918d194a009","repo":"apache/dolphinscheduler","slug":"110014","errorCode":"110014","errorMessage":"Alert test sending failed, [{0}]","messagePattern":"Alert test sending failed, \\[(.+?)\\]","errorType":"error_code","errorClass":"ServiceException","httpStatus":null,"severity":"error","filePath":"dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/service/impl/AlertPluginInstanceServiceImpl.java","lineNumber":326,"sourceCode":"            throw new ServiceException(Status.ALERT_SERVER_NOT_EXIST);\n        }\n\n        Host alertServerAddress = alertServerAddressOptional.get();\n        AlertTestSendRequest alertTestSendRequest = new AlertTestSendRequest(\n                pluginDefineId,\n                pluginInstanceParams);\n\n        AlertSendResponse alertSendResponse;\n\n        try {\n            alertSendResponse = Clients\n                    .withService(IAlertOperator.class)\n                    .withHost(alertServerAddress.getAddress())\n                    .sendTestAlert(alertTestSendRequest);\n            log.info(\"Send alert to: {} successfully, response: {}\", alertServerAddress, alertSendResponse);\n        } catch (Exception e) {\n            log.error(\"Send alert: {} to: {} failed\", alertTestSendRequest, alertServerAddress, e);\n            throw new ServiceException(Status.ALERT_TEST_SENDING_FAILED, e.getMessage());\n        }\n\n        if (!alertSendResponse.isSuccess()) {\n            throw new ServiceException(Status.ALERT_TEST_SENDING_FAILED,\n                    alertSendResponse.getResResults().get(0).getMessage());\n        }\n    }\n}\n","sourceCodeStart":308,"sourceCodeEnd":335,"githubUrl":"https://github.com/apache/dolphinscheduler/blob/02eac45a1b6676e639fcbfb4be2243de5771b05d/dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/service/impl/AlertPluginInstanceServiceImpl.java#L308-L335","documentation":"Thrown by testSend in two cases: an exception occurred while RPC-calling the alert server's sendTestAlert, or the alert server responded with isSuccess()==false. The exception message from the call (or the first resResults entry) is embedded in the error.","triggerScenarios":"Network failure talking to the alert server host; alert plugin (email/Slack/DingTalk etc.) misconfigured so the server-side send fails; alert server returning a failure response for the test request.","commonSituations":"Wrong SMTP credentials/host for email alerts; expired webhook tokens for Slack/DingTalk/WeCom; alert server unreachable or timed out; plugin params JSON invalid causing server-side errors.","solutions":["Read the embedded message in the exception ({0} placeholder) for the underlying cause from the alert server.","Verify the pluginInstanceParams (SMTP config, webhook URLs, tokens) are correct for the chosen alert plugin.","Check dolphinscheduler-alert server logs for the corresponding send failure stack trace.","Confirm network reachability from the alert server to the upstream channel (SMTP/IM endpoints)."],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":"// validate plugin params shape before sending\nJSONUtils.checkJsonValidate(pluginInstanceParams); // plus verify SMTP/webhook fields non-empty for the plugin type","typeGuard":null,"tryCatchPattern":"try { alertPluginInstanceService.testSend(loginUser, pluginDefineId, params); } catch (ServiceException e) { if (e.getCode() == Status.ALERT_TEST_SENDING_FAILED.getCode()) { log.error(\"test send failed: {}\", e.getMessage()); /* inspect alert server logs; fix channel config */ } throw e; }","preventionTips":["Verify SMTP/webhook credentials periodically","Test channels after any credential rotation","Check alert-server logs whenever test send fails","Validate plugin parameter JSON in the UI before submit"],"tags":["alert-channel","network","rpc"],"backgroundTag":"upstream-api-error","analyzedSha":"02eac45a1b6676e639fcbfb4be2243de5771b05d","analyzedAt":"2026-09-06T17:43:00.555Z","contentChangedAt":"2026-09-06T17:43:00.555Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}