status
stringclasses
1 value
repo_name
stringclasses
31 values
repo_url
stringclasses
31 values
issue_id
int64
1
104k
title
stringlengths
4
233
body
stringlengths
0
186k
issue_url
stringlengths
38
56
pull_url
stringlengths
37
54
before_fix_sha
stringlengths
40
40
after_fix_sha
stringlengths
40
40
report_datetime
timestamp[us, tz=UTC]
language
stringclasses
5 values
commit_datetime
timestamp[us, tz=UTC]
updated_file
stringlengths
7
188
chunk_content
stringlengths
1
1.03M
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/service/impl/ExecutorServiceImpl.java
} // tod List<Server> masterServerList = monitorService.getServerListFromRegistry(true); Host host = new Host(masterServerList.get(0).getHost(), masterServerList.get(0).getPort()); TaskExecuteStartCommand taskExecuteStartCommand = new TaskExecuteStartCommand(); taskExecuteStartCommand.setExecutorId(loginUser.getId()); taskExecuteStartCommand.setExecutorName(loginUser.getUserName()); taskExecuteStartCommand.setProjectCode(projectCode); taskExecuteStartCommand.setTaskDefinitionCode(taskDefinitionCode); taskExecuteStartCommand.setTaskDefinitionVersion(taskDefinitionVersion); taskExecuteStartCommand.setWorkerGroup(workerGroup); taskExecuteStartCommand.setWarningGroupId(warningGroupId); taskExecuteStartCommand.setEnvironmentCode(environmentCode); taskExecuteStartCommand.setStartParams(startParams); taskExecuteStartCommand.setDryRun(dryRun); org.apache.dolphinscheduler.remote.command.Command response = stateEventCallbackService.sendSync(host, taskExecuteStartCommand.convert2Command()); if (response != null) { logger.info("Send task execute start command complete, response is {}.", response); putMsg(result, Status.SUCCESS); } else { logger.error( "Start to execute stream task instance error, projectCode:{}, taskDefinitionCode:{}, taskVersion:{}.", projectCode, taskDefinitionCode, taskDefinitionVersion); putMsg(result, Status.START_TASK_INSTANCE_ERROR); } return result; } }
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/controller/ExecutorControllerTest.java
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License.
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/controller/ExecutorControllerTest.java
*/ package org.apache.dolphinscheduler.api.controller; import com.google.common.collect.ImmutableMap; import com.google.gson.Gson; import com.google.gson.JsonObject; import org.apache.dolphinscheduler.api.enums.ExecuteType; import org.apache.dolphinscheduler.api.enums.Status; import org.apache.dolphinscheduler.api.service.ExecutorService; import org.apache.dolphinscheduler.common.Constants; import org.apache.dolphinscheduler.common.enums.*; import org.apache.dolphinscheduler.dao.entity.User; import org.junit.Test; import org.springframework.boot.test.mock.mockito.MockBean; import org.springframework.http.MediaType; import org.springframework.test.web.servlet.MvcResult; import org.springframework.util.LinkedMultiValueMap; import org.springframework.util.MultiValueMap; import java.util.HashMap; import java.util.Map; import static org.assertj.core.api.AssertionsForClassTypes.assertThat; import static org.mockito.ArgumentMatchers.any; import static org.mockito.ArgumentMatchers.eq; import static org.mockito.Mockito.when; import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.post; import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.content; import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; /** * executor controller test */ public class ExecutorControllerTest extends AbstractControllerTest {
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/controller/ExecutorControllerTest.java
final Gson gson = new Gson(); final long projectCode = 1L; final long processDefinitionCode = 2L; final String scheduleTime = "scheduleTime"; final FailureStrategy failureStrategy = FailureStrategy.END; final String startNodeList = "startNodeList"; final TaskDependType taskDependType = TaskDependType.TASK_ONLY; final CommandType execType = CommandType.PAUSE; final WarningType warningType = WarningType.NONE; final int warningGroupId = 3; final RunMode runMode = RunMode.RUN_MODE_SERIAL; final Priority processInstancePriority = Priority.HIGH; final String workerGroup = "workerGroup"; final Long environmentCode = 4L; final Integer timeout = 5; final ImmutableMap<String, String> startParams = ImmutableMap.of("start", "params"); final Integer expectedParallelismNumber = 6; final int dryRun = 7; final int testFlag = 0; final ComplementDependentMode complementDependentMode = ComplementDependentMode.OFF_MODE; final JsonObject expectResponseContent = gson .fromJson("{\"code\":0,\"msg\":\"success\",\"data\":\"Test Data\",\"success\":true,\"failed\":false}" , JsonObject.class); final ImmutableMap<String, Object> executeServiceResult = ImmutableMap.of(Constants.STATUS, Status.SUCCESS, Constants.DATA_LIST, "Test Data"); @MockBean(name = "executorServiceImpl") private ExecutorService executorService;
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/controller/ExecutorControllerTest.java
@Test public void testStartProcessInstanceWithFullParams() throws Exception { final MultiValueMap<String, String> paramsMap = new LinkedMultiValueMap<>(); paramsMap.add("processDefinitionCode", String.valueOf(processDefinitionCode)); paramsMap.add("scheduleTime", scheduleTime); paramsMap.add("failureStrategy", String.valueOf(failureStrategy)); paramsMap.add("startNodeList", startNodeList); paramsMap.add("taskDependType", String.valueOf(taskDependType)); paramsMap.add("execType", String.valueOf(execType)); paramsMap.add("warningType", String.valueOf(warningType)); paramsMap.add("warningGroupId", String.valueOf(warningGroupId)); paramsMap.add("runMode", String.valueOf(runMode)); paramsMap.add("processInstancePriority", String.valueOf(processInstancePriority)); paramsMap.add("workerGroup", workerGroup); paramsMap.add("environmentCode", String.valueOf(environmentCode)); paramsMap.add("timeout", String.valueOf(timeout)); paramsMap.add("startParams", gson.toJson(startParams)); paramsMap.add("expectedParallelismNumber", String.valueOf(expectedParallelismNumber)); paramsMap.add("dryRun", String.valueOf(dryRun)); paramsMap.add("testFlag", String.valueOf(testFlag)); when(executorService.execProcessInstance(any(User.class), eq(projectCode), eq(processDefinitionCode), eq(scheduleTime), eq(execType), eq(failureStrategy), eq(startNodeList), eq(taskDependType), eq(warningType), eq(warningGroupId), eq(runMode), eq(processInstancePriority), eq(workerGroup), eq(environmentCode), eq(timeout), eq(startParams), eq(expectedParallelismNumber), eq(dryRun), eq(testFlag), eq(complementDependentMode))) .thenReturn(executeServiceResult); final MvcResult mvcResult = mockMvc.perform(post("/projects/{projectCode}/executors/start-process-instance", projectCode) .header("sessionId", sessionId) .params(paramsMap))
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/controller/ExecutorControllerTest.java
.andExpect(status().isOk()) .andExpect(content().contentType(MediaType.APPLICATION_JSON)) .andReturn(); final JsonObject actualResponseContent = gson.fromJson(mvcResult.getResponse().getContentAsString(), JsonObject.class); assertThat(actualResponseContent).isEqualTo(expectResponseContent); } @Test public void testStartProcessInstanceWithoutTimeout() throws Exception { final MultiValueMap<String, String> paramsMap = new LinkedMultiValueMap<>(); paramsMap.add("processDefinitionCode", String.valueOf(processDefinitionCode)); paramsMap.add("scheduleTime", scheduleTime); paramsMap.add("failureStrategy", String.valueOf(failureStrategy)); paramsMap.add("startNodeList", startNodeList); paramsMap.add("taskDependType", String.valueOf(taskDependType)); paramsMap.add("execType", String.valueOf(execType)); paramsMap.add("warningType", String.valueOf(warningType)); paramsMap.add("warningGroupId", String.valueOf(warningGroupId)); paramsMap.add("runMode", String.valueOf(runMode)); paramsMap.add("processInstancePriority", String.valueOf(processInstancePriority)); paramsMap.add("workerGroup", workerGroup); paramsMap.add("environmentCode", String.valueOf(environmentCode)); paramsMap.add("startParams", gson.toJson(startParams)); paramsMap.add("expectedParallelismNumber", String.valueOf(expectedParallelismNumber)); paramsMap.add("dryRun", String.valueOf(dryRun)); paramsMap.add("testFlag", String.valueOf(testFlag)); when(executorService.execProcessInstance(any(User.class), eq(projectCode), eq(processDefinitionCode), eq(scheduleTime), eq(execType), eq(failureStrategy), eq(startNodeList), eq(taskDependType), eq(warningType),
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/controller/ExecutorControllerTest.java
eq(warningGroupId), eq(runMode), eq(processInstancePriority), eq(workerGroup), eq(environmentCode), eq(Constants.MAX_TASK_TIMEOUT), eq(startParams), eq(expectedParallelismNumber), eq(dryRun), eq(testFlag), eq(complementDependentMode))).thenReturn(executeServiceResult); final MvcResult mvcResult = mockMvc.perform(post("/projects/{projectCode}/executors/start-process-instance", projectCode) .header("sessionId", sessionId) .params(paramsMap)) .andExpect(status().isOk()) .andExpect(content().contentType(MediaType.APPLICATION_JSON)) .andReturn(); final JsonObject actualResponseContent = gson.fromJson(mvcResult.getResponse().getContentAsString(), JsonObject.class); assertThat(actualResponseContent).isEqualTo(expectResponseContent); } @Test public void testStartProcessInstanceWithoutStartParams() throws Exception { final MultiValueMap<String, String> paramsMap = new LinkedMultiValueMap<>(); paramsMap.add("processDefinitionCode", String.valueOf(processDefinitionCode)); paramsMap.add("scheduleTime", scheduleTime); paramsMap.add("failureStrategy", String.valueOf(failureStrategy)); paramsMap.add("startNodeList", startNodeList); paramsMap.add("taskDependType", String.valueOf(taskDependType)); paramsMap.add("execType", String.valueOf(execType)); paramsMap.add("warningType", String.valueOf(warningType)); paramsMap.add("warningGroupId", String.valueOf(warningGroupId)); paramsMap.add("runMode", String.valueOf(runMode)); paramsMap.add("processInstancePriority", String.valueOf(processInstancePriority)); paramsMap.add("workerGroup", workerGroup); paramsMap.add("environmentCode", String.valueOf(environmentCode));
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/controller/ExecutorControllerTest.java
paramsMap.add("timeout", String.valueOf(timeout)); paramsMap.add("expectedParallelismNumber", String.valueOf(expectedParallelismNumber)); paramsMap.add("dryRun", String.valueOf(dryRun)); paramsMap.add("testFlag", String.valueOf(testFlag)); when(executorService.execProcessInstance(any(User.class), eq(projectCode), eq(processDefinitionCode), eq(scheduleTime), eq(execType), eq(failureStrategy), eq(startNodeList), eq(taskDependType), eq(warningType), eq(warningGroupId), eq(runMode), eq(processInstancePriority), eq(workerGroup), eq(environmentCode), eq(timeout), eq(null), eq(expectedParallelismNumber), eq(dryRun), eq(testFlag), eq(complementDependentMode))).thenReturn(executeServiceResult); final MvcResult mvcResult = mockMvc.perform(post("/projects/{projectCode}/executors/start-process-instance", projectCode) .header("sessionId", sessionId) .params(paramsMap)) .andExpect(status().isOk()) .andExpect(content().contentType(MediaType.APPLICATION_JSON)) .andReturn(); final JsonObject actualResponseContent = gson.fromJson(mvcResult.getResponse().getContentAsString(), JsonObject.class); assertThat(actualResponseContent).isEqualTo(expectResponseContent); } @Test public void testStartProcessInstanceWithRequiredParams() throws Exception { final MultiValueMap<String, String> paramsMap = new LinkedMultiValueMap<>(); paramsMap.add("processDefinitionCode", String.valueOf(processDefinitionCode)); paramsMap.add("failureStrategy", String.valueOf(failureStrategy)); paramsMap.add("warningType", String.valueOf(warningType)); paramsMap.add("scheduleTime", scheduleTime); when(executorService.execProcessInstance(any(User.class), eq(projectCode), eq(processDefinitionCode), eq(scheduleTime), eq(null), eq(failureStrategy), eq(null), eq(null), eq(warningType),
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/controller/ExecutorControllerTest.java
eq(0), eq(null), eq(null), eq("default"), eq(-1L), eq(Constants.MAX_TASK_TIMEOUT), eq(null), eq(null), eq(0), eq(0), eq(complementDependentMode))).thenReturn(executeServiceResult); final MvcResult mvcResult = mockMvc.perform(post("/projects/{projectCode}/executors/start-process-instance", projectCode) .header("sessionId", sessionId) .params(paramsMap)) .andExpect(status().isOk()) .andExpect(content().contentType(MediaType.APPLICATION_JSON)) .andReturn(); final JsonObject actualResponseContent = gson.fromJson(mvcResult.getResponse().getContentAsString(), JsonObject.class); assertThat(actualResponseContent).isEqualTo(expectResponseContent); } @Test public void testExecuteWithSuccessStatus() throws Exception { final ExecuteType executeType = ExecuteType.NONE; final int processInstanceId = 40; final long projectCode = 1113; final MultiValueMap<String, String> paramsMap = new LinkedMultiValueMap<>(); paramsMap.add("processInstanceId", Integer.toString(processInstanceId)); paramsMap.add("executeType", String.valueOf(executeType)); final Map<String, Object> executeServiceResult = new HashMap<>(); executeServiceResult.put(Constants.STATUS, Status.SUCCESS); executeServiceResult.put(Constants.DATA_LIST, "Test Data"); final JsonObject expectResponseContent = gson .fromJson("{\"code\":0,\"msg\":\"success\",\"data\":\"Test Data\",\"success\":true,\"failed\":false}" , JsonObject.class); when(executorService.execute(any(User.class), eq(projectCode), eq(processInstanceId), eq(ExecuteType.NONE)))
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/controller/ExecutorControllerTest.java
.thenReturn(executeServiceResult); final MvcResult mvcResult = mockMvc.perform(post("/projects/{projectCode}/executors/execute", projectCode) .header("sessionId", sessionId) .params(paramsMap)) .andExpect(status().isOk()) .andExpect(content().contentType(MediaType.APPLICATION_JSON)) .andReturn(); final JsonObject actualResponseContent = gson.fromJson(mvcResult.getResponse().getContentAsString(), JsonObject.class); assertThat(actualResponseContent).isEqualTo(expectResponseContent); } @Test public void testStartCheckProcessDefinition() throws Exception { when(executorService.startCheckByProcessDefinedCode(processDefinitionCode)) .thenReturn(executeServiceResult); final MvcResult mvcResult = mockMvc.perform(post("/projects/{projectCode}/executors/start-check", projectCode) .header(SESSION_ID, sessionId) .param("processDefinitionCode", String.valueOf(processDefinitionCode))) .andExpect(status().isOk()) .andExpect(content().contentType(MediaType.APPLICATION_JSON)) .andReturn(); final JsonObject actualResponseContent = gson.fromJson(mvcResult.getResponse().getContentAsString(), JsonObject.class); assertThat(actualResponseContent).isEqualTo(expectResponseContent); } }
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/service/ExecutorServiceTest.java
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.dolphinscheduler.api.service; import static org.apache.dolphinscheduler.api.constants.ApiFuncIdentificationConstant.RERUN; import static org.apache.dolphinscheduler.api.constants.ApiFuncIdentificationConstant.WORKFLOW_START; import static org.mockito.ArgumentMatchers.any;
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/service/ExecutorServiceTest.java
import static org.mockito.ArgumentMatchers.argThat; import static org.mockito.Mockito.doReturn; import static org.mockito.Mockito.times; import static org.mockito.Mockito.verify; import org.apache.dolphinscheduler.api.enums.ExecuteType; import org.apache.dolphinscheduler.api.enums.Status; import org.apache.dolphinscheduler.api.permission.ResourcePermissionCheckService; import org.apache.dolphinscheduler.api.service.impl.BaseServiceImpl; import org.apache.dolphinscheduler.api.service.impl.ExecutorServiceImpl; import org.apache.dolphinscheduler.api.service.impl.ProjectServiceImpl; import org.apache.dolphinscheduler.common.Constants; import org.apache.dolphinscheduler.common.enums.CommandType; import org.apache.dolphinscheduler.common.enums.ComplementDependentMode; import org.apache.dolphinscheduler.common.enums.FailureStrategy; import org.apache.dolphinscheduler.common.enums.Priority; import org.apache.dolphinscheduler.common.enums.ReleaseState; import org.apache.dolphinscheduler.common.enums.RunMode; import org.apache.dolphinscheduler.common.enums.TaskGroupQueueStatus; import org.apache.dolphinscheduler.common.enums.WarningType; import org.apache.dolphinscheduler.common.enums.WorkflowExecutionStatus; import org.apache.dolphinscheduler.common.model.Server; import org.apache.dolphinscheduler.dao.entity.Command; import org.apache.dolphinscheduler.dao.entity.DependentProcessDefinition; import org.apache.dolphinscheduler.dao.entity.ProcessDefinition; import org.apache.dolphinscheduler.dao.entity.ProcessInstance; import org.apache.dolphinscheduler.dao.entity.Project; import org.apache.dolphinscheduler.dao.entity.Schedule; import org.apache.dolphinscheduler.dao.entity.TaskGroupQueue; import org.apache.dolphinscheduler.dao.entity.Tenant; import org.apache.dolphinscheduler.dao.entity.User;
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/service/ExecutorServiceTest.java
import org.apache.dolphinscheduler.dao.mapper.ProcessDefinitionMapper; import org.apache.dolphinscheduler.dao.mapper.ProcessInstanceMapper; import org.apache.dolphinscheduler.dao.mapper.ProcessTaskRelationMapper; import org.apache.dolphinscheduler.dao.mapper.ProjectMapper; import org.apache.dolphinscheduler.dao.mapper.TaskDefinitionMapper; import org.apache.dolphinscheduler.dao.mapper.TaskGroupQueueMapper; import org.apache.dolphinscheduler.service.process.ProcessService; import java.util.ArrayList; import java.util.Collections; import java.util.Date; import java.util.HashMap; import java.util.LinkedList; import java.util.List; import java.util.Map; import java.util.Optional; import org.assertj.core.util.Lists; import org.junit.Assert; import org.junit.Before; import org.junit.Test; import org.junit.runner.RunWith; import org.mockito.InjectMocks; import org.mockito.Mock; import org.mockito.Mockito; import org.mockito.junit.MockitoJUnitRunner; import org.slf4j.Logger; import org.slf4j.LoggerFactory; /** * executor service 2 test */ @RunWith(MockitoJUnitRunner.Silent.class)
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/service/ExecutorServiceTest.java
public class ExecutorServiceTest { private static final Logger logger = LoggerFactory.getLogger(ExecutorServiceTest.class); private static final Logger baseServiceLogger = LoggerFactory.getLogger(BaseServiceImpl.class); @Mock private ResourcePermissionCheckService resourcePermissionCheckService; @InjectMocks private ExecutorServiceImpl executorService; @Mock private ProcessService processService; @Mock private ProcessDefinitionMapper processDefinitionMapper; @Mock private ProcessTaskRelationMapper processTaskRelationMapper; @Mock private TaskDefinitionMapper taskDefinitionMapper; @Mock private ProjectMapper projectMapper; @Mock private ProjectServiceImpl projectService; @Mock private MonitorService monitorService; @Mock private TaskGroupQueueMapper taskGroupQueueMapper; @Mock private ProcessInstanceMapper processInstanceMapper; private int processDefinitionId = 1; private long processDefinitionCode = 1L;
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/service/ExecutorServiceTest.java
private int processInstanceId = 1; private int tenantId = 1; private int userId = 1; private int taskQueueId = 1; private ProcessDefinition processDefinition = new ProcessDefinition(); private ProcessInstance processInstance = new ProcessInstance(); private TaskGroupQueue taskGroupQueue = new TaskGroupQueue(); private User loginUser = new User(); private long projectCode = 1L; private String projectName = "projectName"; private Project project = new Project(); private String cronTime; @Before public void init() { loginUser.setId(userId); processDefinition.setId(processDefinitionId); processDefinition.setReleaseState(ReleaseState.ONLINE); processDefinition.setTenantId(tenantId); processDefinition.setUserId(userId); processDefinition.setVersion(1); processDefinition.setCode(1L); processDefinition.setProjectCode(projectCode); processInstance.setId(processInstanceId); processInstance.setState(WorkflowExecutionStatus.FAILURE); processInstance.setExecutorId(userId); processInstance.setTenantId(tenantId); processInstance.setProcessDefinitionVersion(1);
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/service/ExecutorServiceTest.java
processInstance.setProcessDefinitionCode(1L); project.setCode(projectCode); project.setName(projectName); taskGroupQueue.setId(taskQueueId); taskGroupQueue.setStatus(TaskGroupQueueStatus.WAIT_QUEUE); taskGroupQueue.setProcessId(processInstanceId); cronTime = "2020-01-01 00:00:00,2020-01-31 23:00:00"; Mockito.when(projectMapper.queryByCode(projectCode)).thenReturn(project); Mockito.when(projectService.checkProjectAndAuth(loginUser, project, projectCode, WORKFLOW_START)) .thenReturn(checkProjectAndAuth()); Mockito.when(processDefinitionMapper.queryByCode(processDefinitionCode)).thenReturn(processDefinition); Mockito.when(processService.getTenantForProcess(tenantId, userId)).thenReturn(new Tenant()); doReturn(1).when(processService).createCommand(argThat(c -> c.getId() == null)); doReturn(0).when(processService).createCommand(argThat(c -> c.getId() != null)); Mockito.when(monitorService.getServerListFromRegistry(true)).thenReturn(getMasterServersList()); Mockito.when(processService.findProcessInstanceDetailById(processInstanceId)).thenReturn(Optional.ofNullable(processInstance)); Mockito.when(processService.findProcessDefinition(1L, 1)).thenReturn(processDefinition); Mockito.when(taskGroupQueueMapper.selectById(1)).thenReturn(taskGroupQueue); Mockito.when(processInstanceMapper.selectById(1)).thenReturn(processInstance); } @Test public void testForceStartTaskInstance() { Map<String, Object> result = executorService.forceStartTaskInstance(loginUser, taskQueueId); Assert.assertEquals(Status.SUCCESS, result.get(Constants.STATUS)); } /**
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/service/ExecutorServiceTest.java
* not complement */ @Test public void testNoComplement() { Mockito.when(processService.queryReleaseSchedulerListByProcessDefinitionCode(processDefinitionCode)) .thenReturn(zeroSchedulerList()); Map<String, Object> result = executorService.execProcessInstance(loginUser, projectCode, processDefinitionCode, "{\"complementStartDate\":\"2020-01-01 00:00:00\",\"complementEndDate\":\"2020-01-31 23:00:00\"}", CommandType.START_PROCESS, null, null, null, null, 0, RunMode.RUN_MODE_SERIAL, Priority.LOW, Constants.DEFAULT_WORKER_GROUP, 100L, 10, null, 0, Constants.DRY_RUN_FLAG_NO, Constants.TEST_FLAG_NO, ComplementDependentMode.OFF_MODE); Assert.assertEquals(Status.SUCCESS, result.get(Constants.STATUS)); verify(processService, times(1)).createCommand(any(Command.class)); } /** * not complement */ @Test public void testComplementWithStartNodeList() { Mockito.when(processService.queryReleaseSchedulerListByProcessDefinitionCode(processDefinitionCode)) .thenReturn(zeroSchedulerList()); Map<String, Object> result = executorService.execProcessInstance(loginUser, projectCode, processDefinitionCode, "{\"complementStartDate\":\"2020-01-01 00:00:00\",\"complementEndDate\":\"2020-01-31 23:00:00\"}", CommandType.START_PROCESS, null, "n1,n2",
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/service/ExecutorServiceTest.java
null, null, 0, RunMode.RUN_MODE_SERIAL, Priority.LOW, Constants.DEFAULT_WORKER_GROUP, 100L, 110, null, 0, Constants.DRY_RUN_FLAG_NO, Constants.TEST_FLAG_NO, ComplementDependentMode.OFF_MODE); Assert.assertEquals(Status.SUCCESS, result.get(Constants.STATUS)); verify(processService, times(1)).createCommand(any(Command.class)); } @Test public void testComplementWithDependentMode() { Schedule schedule = new Schedule(); schedule.setStartTime(new Date()); schedule.setEndTime(new Date()); schedule.setCrontab("0 0 7 * * ? *"); schedule.setFailureStrategy(FailureStrategy.CONTINUE); schedule.setReleaseState(ReleaseState.OFFLINE); schedule.setWarningType(WarningType.NONE); schedule.setCreateTime(new Date()); schedule.setUpdateTime(new Date()); List<Schedule> schedules = Lists.newArrayList(schedule); Mockito.when(processService.queryReleaseSchedulerListByProcessDefinitionCode( processDefinitionCode)) .thenReturn(schedules); DependentProcessDefinition dependentProcessDefinition = new DependentProcessDefinition(); dependentProcessDefinition.setProcessDefinitionCode(2); dependentProcessDefinition.setProcessDefinitionVersion(1); dependentProcessDefinition.setTaskDefinitionCode(1); dependentProcessDefinition.setWorkerGroup(Constants.DEFAULT_WORKER_GROUP); dependentProcessDefinition.setTaskParams( "{\"localParams\":[],\"resourceList\":[],\"dependence\":{\"relation\":\"AND\",\"dependTaskList\":[{\"relation\":\"AND\",\"dependItemList\":[{\"depTaskCode\":2,\"status\":\"SUCCESS\"}]}]},\"conditionResult\":{\"successNode\":[1],\"failedNode\":[1]}}"); Mockito.when(processService.queryDependentProcessDefinitionByProcessDefinitionCode(processDefinitionCode))
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/service/ExecutorServiceTest.java
.thenReturn(Lists.newArrayList(dependentProcessDefinition)); Map<Long, String> processDefinitionWorkerGroupMap = new HashMap<>(); processDefinitionWorkerGroupMap.put(1L, Constants.DEFAULT_WORKER_GROUP); Mockito.when(processService.queryWorkerGroupByProcessDefinitionCodes(Lists.newArrayList(1L))) .thenReturn(processDefinitionWorkerGroupMap); Command command = new Command(); command.setId(1); command.setCommandType(CommandType.COMPLEMENT_DATA); command.setCommandParam( "{\"StartNodeList\":\"1\",\"complementStartDate\":\"2020-01-01 00:00:00\",\"complementEndDate\":\"2020-01-31 23:00:00\"}"); command.setWorkerGroup(Constants.DEFAULT_WORKER_GROUP); command.setProcessDefinitionCode(processDefinitionCode); command.setExecutorId(1); int count = executorService.createComplementDependentCommand(schedules, command); Assert.assertEquals(1, count); } /** * date error */ @Test public void testDateError() { Mockito.when(processService.queryReleaseSchedulerListByProcessDefinitionCode(processDefinitionCode)) .thenReturn(zeroSchedulerList()); Map<String, Object> result = executorService.execProcessInstance(loginUser, projectCode, processDefinitionCode, "{\"complementStartDate\":\"2022-01-07 12:12:12\",\"complementEndDate\":\"2022-01-06 12:12:12\"}", CommandType.COMPLEMENT_DATA, null, null, null, null, 0, RunMode.RUN_MODE_SERIAL,
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/service/ExecutorServiceTest.java
Priority.LOW, Constants.DEFAULT_WORKER_GROUP, 100L, 110, null, 0, Constants.DRY_RUN_FLAG_NO, Constants.TEST_FLAG_NO, ComplementDependentMode.OFF_MODE); Assert.assertEquals(Status.START_PROCESS_INSTANCE_ERROR, result.get(Constants.STATUS)); verify(processService, times(0)).createCommand(any(Command.class)); } /** * serial */ @Test public void testSerial() { Mockito.when(processService.queryReleaseSchedulerListByProcessDefinitionCode(processDefinitionCode)) .thenReturn(zeroSchedulerList()); Map<String, Object> result = executorService.execProcessInstance(loginUser, projectCode, processDefinitionCode, "{\"complementStartDate\":\"2020-01-01 00:00:00\",\"complementEndDate\":\"2020-01-31 23:00:00\"}", CommandType.COMPLEMENT_DATA, null, null, null, null, 0, RunMode.RUN_MODE_SERIAL, Priority.LOW, Constants.DEFAULT_WORKER_GROUP, 100L, 110, null, 0, Constants.DRY_RUN_FLAG_NO, Constants.TEST_FLAG_NO, ComplementDependentMode.OFF_MODE); Assert.assertEquals(Status.SUCCESS, result.get(Constants.STATUS)); verify(processService, times(1)).createCommand(any(Command.class)); } /** * without schedule */ @Test public void testParallelWithOutSchedule() { Mockito.when(processService.queryReleaseSchedulerListByProcessDefinitionCode(processDefinitionCode))
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/service/ExecutorServiceTest.java
.thenReturn(zeroSchedulerList()); Map<String, Object> result = executorService.execProcessInstance(loginUser, projectCode, processDefinitionCode, "{\"complementStartDate\":\"2020-01-01 00:00:00\",\"complementEndDate\":\"2020-01-31 23:00:00\"}", CommandType.COMPLEMENT_DATA, null, null, null, null, 0, RunMode.RUN_MODE_PARALLEL, Priority.LOW, Constants.DEFAULT_WORKER_GROUP, 100L, 110, null, 0, Constants.DRY_RUN_FLAG_NO, Constants.TEST_FLAG_NO, ComplementDependentMode.OFF_MODE); Assert.assertEquals(Status.SUCCESS, result.get(Constants.STATUS)); verify(processService, times(31)).createCommand(any(Command.class)); } /** * with schedule */ @Test public void testParallelWithSchedule() { Mockito.when(processService.queryReleaseSchedulerListByProcessDefinitionCode(processDefinitionCode)) .thenReturn(oneSchedulerList()); Map<String, Object> result = executorService.execProcessInstance(loginUser, projectCode, processDefinitionCode, "{\"complementStartDate\":\"2020-01-01 00:00:00\",\"complementEndDate\":\"2020-01-31 23:00:00\"}", CommandType.COMPLEMENT_DATA, null, null, null, null, 0, RunMode.RUN_MODE_PARALLEL, Priority.LOW, Constants.DEFAULT_WORKER_GROUP, 100L, 110, null, 15, Constants.DRY_RUN_FLAG_NO, Constants.TEST_FLAG_NO, ComplementDependentMode.OFF_MODE); Assert.assertEquals(Status.SUCCESS, result.get(Constants.STATUS));
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/service/ExecutorServiceTest.java
verify(processService, times(15)).createCommand(any(Command.class)); } @Test public void testNoMasterServers() { Mockito.when(monitorService.getServerListFromRegistry(true)).thenReturn(new ArrayList<>()); Map<String, Object> result = executorService.execProcessInstance(loginUser, projectCode, processDefinitionCode, "{\"complementStartDate\":\"2020-01-01 00:00:00\",\"complementEndDate\":\"2020-01-31 23:00:00\"}", CommandType.COMPLEMENT_DATA, null, null, null, null, 0, RunMode.RUN_MODE_PARALLEL, Priority.LOW, Constants.DEFAULT_WORKER_GROUP, 100L, 110, null, 0, Constants.DRY_RUN_FLAG_NO, Constants.TEST_FLAG_NO, ComplementDependentMode.OFF_MODE); Assert.assertEquals(result.get(Constants.STATUS), Status.MASTER_NOT_EXISTS); } @Test public void testExecuteRepeatRunning() { Mockito.when(processService.verifyIsNeedCreateCommand(any(Command.class))).thenReturn(true); Mockito.when(projectService.checkProjectAndAuth(loginUser, project, projectCode, RERUN)) .thenReturn(checkProjectAndAuth()); Map<String, Object> result = executorService.execute(loginUser, projectCode, processInstanceId, ExecuteType.REPEAT_RUNNING); Assert.assertEquals(Status.SUCCESS, result.get(Constants.STATUS)); } @Test public void testOfTestRun(){ Mockito.when(processService.verifyIsNeedCreateCommand(any(Command.class))).thenReturn(true); Mockito.when(projectService.checkProjectAndAuth(loginUser, project, projectCode, RERUN)) .thenReturn(checkProjectAndAuth());
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/service/ExecutorServiceTest.java
Map<String, Object> result = executorService.execProcessInstance(loginUser, projectCode, processDefinitionCode, "{\"complementStartDate\":\"2020-01-01 00:00:00\",\"complementEndDate\":\"2020-01-31 23:00:00\"}", CommandType.COMPLEMENT_DATA, null, null, null, null, 0, RunMode.RUN_MODE_PARALLEL, Priority.LOW, Constants.DEFAULT_WORKER_GROUP, 100L, 110, null, 15, Constants.DRY_RUN_FLAG_NO, Constants.TEST_FLAG_YES, ComplementDependentMode.OFF_MODE); Assert.assertEquals(Status.SUCCESS, result.get(Constants.STATUS)); } @Test public void testStartCheckByProcessDefinedCode() { List<Long> ids = new ArrayList<>(); ids.add(1L); Mockito.doNothing().when(processService).recurseFindSubProcess(1, ids); List<ProcessDefinition> processDefinitionList = new ArrayList<>(); ProcessDefinition processDefinition = new ProcessDefinition(); processDefinition.setId(1); processDefinition.setReleaseState(ReleaseState.ONLINE); processDefinitionList.add(processDefinition); Mockito.when(processDefinitionMapper.queryDefinitionListByIdList(new Integer[ids.size()])) .thenReturn(processDefinitionList); Map<String, Object> result = executorService.startCheckByProcessDefinedCode(1L); Assert.assertEquals(Status.SUCCESS, result.get(Constants.STATUS)); } private List<Server> getMasterServersList() { List<Server> masterServerList = new ArrayList<>(); Server masterServer1 = new Server(); masterServer1.setId(1);
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/service/ExecutorServiceTest.java
masterServer1.setHost("192.168.220.188"); masterServer1.setPort(1121); masterServerList.add(masterServer1); Server masterServer2 = new Server(); masterServer2.setId(2); masterServer2.setHost("192.168.220.189"); masterServer2.setPort(1122); masterServerList.add(masterServer2); return masterServerList; } private List zeroSchedulerList() { return Collections.EMPTY_LIST; } private List<Schedule> oneSchedulerList() { List<Schedule> schedulerList = new LinkedList<>(); Schedule schedule = new Schedule(); schedule.setCrontab("0 0 0 1/2 * ?"); schedulerList.add(schedule); return schedulerList; } private Map<String, Object> checkProjectAndAuth() { Map<String, Object> result = new HashMap<>(); result.put(Constants.STATUS, Status.SUCCESS); return result; } @Test public void testCreateComplementToParallel() { List<String> result = new ArrayList<>(); int expectedParallelismNumber = 3; LinkedList<Integer> listDate = new LinkedList<>();
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-api/src/test/java/org/apache/dolphinscheduler/api/service/ExecutorServiceTest.java
listDate.add(0); listDate.add(1); listDate.add(2); listDate.add(3); listDate.add(4); int listDateSize = listDate.size(); int createCount = Math.min(listDate.size(), expectedParallelismNumber); logger.info("In parallel mode, current expectedParallelismNumber:{}", createCount); int itemsPerCommand = (listDateSize / createCount); int remainingItems = (listDateSize % createCount); int startDateIndex = 0; int endDateIndex = 0; for (int i = 1; i <= createCount; i++) { int extra = (i <= remainingItems) ? 1 : 0; int singleCommandItems = (itemsPerCommand + extra); if (i == 1) { endDateIndex += singleCommandItems - 1; } else { startDateIndex = endDateIndex + 1; endDateIndex += singleCommandItems; } logger.info("startDate:{}, endDate:{}", listDate.get(startDateIndex), listDate.get(endDateIndex)); result.add(listDate.get(startDateIndex) + "," + listDate.get(endDateIndex)); } Assert.assertEquals("0,1", result.get(0)); Assert.assertEquals("2,3", result.get(1)); Assert.assertEquals("4,4", result.get(2)); } }
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-dao/src/main/java/org/apache/dolphinscheduler/dao/AlertDao.java
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.dolphinscheduler.dao; import org.apache.dolphinscheduler.common.enums.AlertEvent; import org.apache.dolphinscheduler.common.enums.AlertStatus; import org.apache.dolphinscheduler.common.enums.AlertType;
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-dao/src/main/java/org/apache/dolphinscheduler/dao/AlertDao.java
import org.apache.dolphinscheduler.common.enums.AlertWarnLevel; import org.apache.dolphinscheduler.common.enums.WarningType; import org.apache.dolphinscheduler.common.utils.JSONUtils; import org.apache.dolphinscheduler.dao.entity.Alert; import org.apache.dolphinscheduler.dao.entity.AlertPluginInstance; import org.apache.dolphinscheduler.dao.entity.AlertSendStatus; import org.apache.dolphinscheduler.dao.entity.ProcessAlertContent; import org.apache.dolphinscheduler.dao.entity.ProcessInstance; import org.apache.dolphinscheduler.dao.entity.ProjectUser; import org.apache.dolphinscheduler.dao.entity.ServerAlertContent; import org.apache.dolphinscheduler.dao.entity.TaskInstance; import org.apache.dolphinscheduler.dao.mapper.AlertGroupMapper; import org.apache.dolphinscheduler.dao.mapper.AlertMapper; import org.apache.dolphinscheduler.dao.mapper.AlertPluginInstanceMapper; import org.apache.dolphinscheduler.dao.mapper.AlertSendStatusMapper; import org.apache.commons.codec.digest.DigestUtils; import org.apache.commons.collections4.CollectionUtils; import java.time.LocalDateTime; import java.time.ZoneId; import java.util.ArrayList; import java.util.Arrays; import java.util.Date; import java.util.List; import java.util.Optional; import java.util.stream.Collectors; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Value; import org.springframework.stereotype.Component; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-dao/src/main/java/org/apache/dolphinscheduler/dao/AlertDao.java
import com.google.common.base.Strings; import com.google.common.collect.Lists; @Component public class AlertDao { private static final int QUERY_ALERT_THRESHOLD = 100; @Value("${alert.alarm-suppression.crash:60}") private Integer crashAlarmSuppression; @Autowired private AlertMapper alertMapper; @Autowired private AlertPluginInstanceMapper alertPluginInstanceMapper; @Autowired private AlertGroupMapper alertGroupMapper; @Autowired private AlertSendStatusMapper alertSendStatusMapper; /** * insert alert * * @param alert alert * @return add alert result */ public int addAlert(Alert alert) { String sign = generateSign(alert); alert.setSign(sign); return alertMapper.insert(alert); } /** * update alert sending(execution) status * * @param alertStatus alertStatus
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-dao/src/main/java/org/apache/dolphinscheduler/dao/AlertDao.java
* @param log alert results json * @param id id * @return update alert result */ public int updateAlert(AlertStatus alertStatus, String log, int id) { Alert alert = new Alert(); alert.setId(id); alert.setAlertStatus(alertStatus); alert.setUpdateTime(new Date()); alert.setLog(log); return alertMapper.updateById(alert); } /** * generate sign for alert * * @param alert alert * @return sign's str */ private String generateSign(Alert alert) { return Optional.of(alert) .map(Alert::getContent) .map(DigestUtils::sha1Hex) .map(String::toLowerCase) .orElse(""); } /** * add AlertSendStatus * * @param sendStatus alert send status * @param log log
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-dao/src/main/java/org/apache/dolphinscheduler/dao/AlertDao.java
* @param alertId alert id * @param alertPluginInstanceId alert plugin instance id * @return insert count */ public int addAlertSendStatus(AlertStatus sendStatus, String log, int alertId, int alertPluginInstanceId) { AlertSendStatus alertSendStatus = new AlertSendStatus(); alertSendStatus.setAlertId(alertId); alertSendStatus.setAlertPluginInstanceId(alertPluginInstanceId); alertSendStatus.setSendStatus(sendStatus); alertSendStatus.setLog(log); alertSendStatus.setCreateTime(new Date()); return alertSendStatusMapper.insert(alertSendStatus); } public int insertAlertSendStatus(List<AlertSendStatus> alertSendStatuses) { if (CollectionUtils.isEmpty(alertSendStatuses)) { return 0; } return alertSendStatusMapper.batchInsert(alertSendStatuses); } /** * MasterServer or WorkerServer stopped * * @param alertGroupId alertGroupId * @param host host * @param serverType serverType */ public void sendServerStoppedAlert(int alertGroupId, String host, String serverType) { ServerAlertContent serverStopAlertContent = ServerAlertContent.newBuilder().type(serverType) .host(host) .event(AlertEvent.SERVER_DOWN)
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-dao/src/main/java/org/apache/dolphinscheduler/dao/AlertDao.java
.warningLevel(AlertWarnLevel.SERIOUS).build(); String content = JSONUtils.toJsonString(Lists.newArrayList(serverStopAlertContent)); Alert alert = new Alert(); alert.setTitle("Fault tolerance warning"); alert.setWarningType(WarningType.FAILURE); alert.setAlertStatus(AlertStatus.WAIT_EXECUTION); alert.setContent(content); alert.setAlertGroupId(alertGroupId); alert.setCreateTime(new Date()); alert.setUpdateTime(new Date()); alert.setAlertType(AlertType.FAULT_TOLERANCE_WARNING); alert.setSign(generateSign(alert)); Date crashAlarmSuppressionStartTime = Date.from( LocalDateTime.now().plusMinutes(-crashAlarmSuppression).atZone(ZoneId.systemDefault()).toInstant()); alertMapper.insertAlertWhenServerCrash(alert, crashAlarmSuppressionStartTime); } /** * process time out alert * * @param processInstance processInstance * @param projectUser projectUser */ public void sendProcessTimeoutAlert(ProcessInstance processInstance, ProjectUser projectUser) { int alertGroupId = processInstance.getWarningGroupId(); Alert alert = new Alert(); List<ProcessAlertContent> processAlertContentList = new ArrayList<>(1); ProcessAlertContent processAlertContent = ProcessAlertContent.builder() .projectCode(projectUser.getProjectCode())
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-dao/src/main/java/org/apache/dolphinscheduler/dao/AlertDao.java
.projectName(projectUser.getProjectName()) .owner(projectUser.getUserName()) .processId(processInstance.getId()) .processDefinitionCode(processInstance.getProcessDefinitionCode()) .processName(processInstance.getName()) .processType(processInstance.getCommandType()) .processState(processInstance.getState()) .runTimes(processInstance.getRunTimes()) .processStartTime(processInstance.getStartTime()) .processHost(processInstance.getHost()) .event(AlertEvent.TIME_OUT) .warnLevel(AlertWarnLevel.MIDDLE) .build(); processAlertContentList.add(processAlertContent); String content = JSONUtils.toJsonString(processAlertContentList); alert.setTitle("Process Timeout Warn"); alert.setProjectCode(projectUser.getProjectCode()); alert.setProcessDefinitionCode(processInstance.getProcessDefinitionCode()); alert.setProcessInstanceId(processInstance.getId()); alert.setAlertType(AlertType.PROCESS_INSTANCE_TIMEOUT); saveTaskTimeoutAlert(alert, content, alertGroupId); } private void saveTaskTimeoutAlert(Alert alert, String content, int alertGroupId) { alert.setAlertGroupId(alertGroupId); alert.setWarningType(WarningType.FAILURE); alert.setContent(content); alert.setCreateTime(new Date()); alert.setUpdateTime(new Date()); String sign = generateSign(alert); alert.setSign(sign);
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-dao/src/main/java/org/apache/dolphinscheduler/dao/AlertDao.java
alertMapper.insert(alert); } /** * task timeout warn * * @param processInstance processInstanceId * @param taskInstance taskInstance * @param projectUser projectUser */ public void sendTaskTimeoutAlert(ProcessInstance processInstance, TaskInstance taskInstance, ProjectUser projectUser) { Alert alert = new Alert(); List<ProcessAlertContent> processAlertContentList = new ArrayList<>(1); ProcessAlertContent processAlertContent = ProcessAlertContent.builder() .projectCode(projectUser.getProjectCode()) .projectName(projectUser.getProjectName()) .owner(projectUser.getUserName()) .processId(processInstance.getId()) .processDefinitionCode(processInstance.getProcessDefinitionCode()) .processName(processInstance.getName()) .taskCode(taskInstance.getTaskCode()) .taskName(taskInstance.getName()) .taskType(taskInstance.getTaskType()) .taskStartTime(taskInstance.getStartTime()) .taskHost(taskInstance.getHost()) .event(AlertEvent.TIME_OUT) .warnLevel(AlertWarnLevel.MIDDLE) .build(); processAlertContentList.add(processAlertContent); String content = JSONUtils.toJsonString(processAlertContentList);
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-dao/src/main/java/org/apache/dolphinscheduler/dao/AlertDao.java
alert.setTitle("Task Timeout Warn"); alert.setProjectCode(projectUser.getProjectCode()); alert.setProcessDefinitionCode(processInstance.getProcessDefinitionCode()); alert.setProcessInstanceId(processInstance.getId()); alert.setAlertType(AlertType.TASK_TIMEOUT); saveTaskTimeoutAlert(alert, content, processInstance.getWarningGroupId()); } /** * List alerts that are pending for execution */ public List<Alert> listPendingAlerts() { return alertMapper.listingAlertByStatus(AlertStatus.WAIT_EXECUTION.getCode(), QUERY_ALERT_THRESHOLD); } public List<Alert> listAlerts(int processInstanceId) { LambdaQueryWrapper<Alert> wrapper = new QueryWrapper<>(new Alert()).lambda() .eq(Alert::getProcessInstanceId, processInstanceId); return alertMapper.selectList(wrapper); } /** * for test * * @return AlertMapper */ public AlertMapper getAlertMapper() { return alertMapper; } /** * list all alert plugin instance by alert group id * * @param alertGroupId alert group id
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-dao/src/main/java/org/apache/dolphinscheduler/dao/AlertDao.java
* @return AlertPluginInstance list */ public List<AlertPluginInstance> listInstanceByAlertGroupId(int alertGroupId) { String alertInstanceIdsParam = alertGroupMapper.queryAlertGroupInstanceIdsById(alertGroupId); if (!Strings.isNullOrEmpty(alertInstanceIdsParam)) { String[] idsArray = alertInstanceIdsParam.split(","); List<Integer> ids = Arrays.stream(idsArray) .map(s -> Integer.parseInt(s.trim())) .collect(Collectors.toList()); return alertPluginInstanceMapper.queryByIds(ids); } return null; } public AlertPluginInstanceMapper getAlertPluginInstanceMapper() { return alertPluginInstanceMapper; } public void setAlertPluginInstanceMapper(AlertPluginInstanceMapper alertPluginInstanceMapper) { this.alertPluginInstanceMapper = alertPluginInstanceMapper; } public AlertGroupMapper getAlertGroupMapper() { return alertGroupMapper; } public void setAlertGroupMapper(AlertGroupMapper alertGroupMapper) { this.alertGroupMapper = alertGroupMapper; } public void setCrashAlarmSuppression(Integer crashAlarmSuppression) { this.crashAlarmSuppression = crashAlarmSuppression; } }
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-dao/src/main/java/org/apache/dolphinscheduler/dao/entity/ProcessDefinition.java
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License.
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-dao/src/main/java/org/apache/dolphinscheduler/dao/entity/ProcessDefinition.java
*/ package org.apache.dolphinscheduler.dao.entity; import org.apache.dolphinscheduler.common.enums.Flag; import org.apache.dolphinscheduler.common.enums.ProcessExecutionTypeEnum; import org.apache.dolphinscheduler.common.enums.ReleaseState; import org.apache.dolphinscheduler.common.utils.JSONUtils; import org.apache.dolphinscheduler.plugin.task.api.model.Property; import java.util.ArrayList; import java.util.Date; import java.util.List; import java.util.Map; import java.util.stream.Collectors; import lombok.AllArgsConstructor; import lombok.Builder; import lombok.Data; import lombok.NoArgsConstructor; import com.baomidou.mybatisplus.annotation.IdType; import com.baomidou.mybatisplus.annotation.TableField; import com.baomidou.mybatisplus.annotation.TableId; import com.baomidou.mybatisplus.annotation.TableName; import com.google.common.base.Strings; @Data @Builder @NoArgsConstructor @AllArgsConstructor @TableName("t_ds_process_definition") public class ProcessDefinition { /** * id */
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-dao/src/main/java/org/apache/dolphinscheduler/dao/entity/ProcessDefinition.java
@TableId(value = "id", type = IdType.AUTO) private Integer id; /** * code */ private long code; /** * name */ private String name; /** * version */ private int version; /** * release state : online/offline */ private ReleaseState releaseState; /** * project code */ private long projectCode; /** * description */ private String description; /** * user defined parameters */ private String globalParams;
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-dao/src/main/java/org/apache/dolphinscheduler/dao/entity/ProcessDefinition.java
/** * user defined parameter list */ @TableField(exist = false) private List<Property> globalParamList; /** * user define parameter map */ @TableField(exist = false) private Map<String, String> globalParamMap; /** * create time */ private Date createTime; /** * update time */ private Date updateTime; /** * process is valid: yes/no */ private Flag flag; /** * process user id */ private int userId; /** * user name */ @TableField(exist = false)
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-dao/src/main/java/org/apache/dolphinscheduler/dao/entity/ProcessDefinition.java
private String userName; /** * project name */ @TableField(exist = false) private String projectName; /** * locations array for web */ private String locations; /** * schedule release state : online/offline */ @TableField(exist = false) private ReleaseState scheduleReleaseState; /** * process warning time out. unit: minute */ private int timeout; /** * tenant id */ private int tenantId; /** * tenant code */ @TableField(exist = false) private String tenantCode; /** * modify user name
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-dao/src/main/java/org/apache/dolphinscheduler/dao/entity/ProcessDefinition.java
*/ @TableField(exist = false) private String modifyBy; /** * warningGroupId */ @TableField(exist = false) private int warningGroupId; /** * execution type */ private ProcessExecutionTypeEnum executionType; public ProcessDefinition(long projectCode, String name, long code, String description, String globalParams, String locations, int timeout, int userId, int tenantId) { set(projectCode, name, description, globalParams, locations, timeout, tenantId); this.code = code; this.userId = userId; Date date = new Date(); this.createTime = date; this.updateTime = date; } public void set(long projectCode, String name,
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-dao/src/main/java/org/apache/dolphinscheduler/dao/entity/ProcessDefinition.java
String description, String globalParams, String locations, int timeout, int tenantId) { this.projectCode = projectCode; this.name = name; this.description = description; this.globalParams = globalParams; this.locations = locations; this.timeout = timeout; this.tenantId = tenantId; this.flag = Flag.YES; } public void setGlobalParams(String globalParams) { this.globalParamList = JSONUtils.toList(globalParams, Property.class); if (this.globalParamList == null) { this.globalParamList = new ArrayList<>(); } this.globalParams = globalParams; } public Map<String, String> getGlobalParamMap() { if (globalParamMap == null && !Strings.isNullOrEmpty(globalParams)) { List<Property> propList = JSONUtils.toList(globalParams, Property.class); globalParamMap = propList.stream().collect(Collectors.toMap(Property::getProp, Property::getValue)); } return globalParamMap; } }
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
/* * Lcensed to the Apache Software Foundaton (ASF) under one or more * contrbutor lcense agreements. See the NOTICE fle dstrbuted wth * ths work for addtonal nformaton regardng copyrght ownershp. * The ASF lcenses ths fle to You under the Apache Lcense, Verson 2.0 * (the "Lcense"); you may not use ths fle except n complance wth * the Lcense. You may obtan a copy of the Lcense at * * http://www.apache.org/lcenses/LICENSE-2.0 * * Unless requred by applcable law or agreed to n wrtng, software * dstrbuted under the Lcense s dstrbuted on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, ether express or mpled. * See the Lcense for the specfc language governng permssons and * lmtatons under the Lcense.
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
*/ package org.apache.dolphnscheduler.server.master.runner; mport statc org.apache.dolphnscheduler.common.Constants.CMDPARAM_COMPLEMENT_DATA_END_DATE; mport statc org.apache.dolphnscheduler.common.Constants.CMDPARAM_COMPLEMENT_DATA_SCHEDULE_DATE_LIST; mport statc org.apache.dolphnscheduler.common.Constants.CMDPARAM_COMPLEMENT_DATA_START_DATE; mport statc org.apache.dolphnscheduler.common.Constants.CMD_PARAM_RECOVERY_START_NODE_STRING; mport statc org.apache.dolphnscheduler.common.Constants.CMD_PARAM_RECOVER_PROCESS_ID_STRING; mport statc org.apache.dolphnscheduler.common.Constants.CMD_PARAM_START_NODES; mport statc org.apache.dolphnscheduler.common.Constants.COMMA; mport statc org.apache.dolphnscheduler.common.Constants.DEFAULT_WORKER_GROUP; mport statc org.apache.dolphnscheduler.common.Constants.YYYY_MM_DD_HH_MM_SS; mport statc org.apache.dolphnscheduler.plugn.task.ap.TaskConstants.TASK_TYPE_BLOCKING; mport statc org.apache.dolphnscheduler.plugn.task.ap.enums.DataType.VARCHAR; mport statc org.apache.dolphnscheduler.plugn.task.ap.enums.Drect.IN; mport org.apache.dolphnscheduler.common.Constants; mport org.apache.dolphnscheduler.common.enums.CommandType; mport org.apache.dolphnscheduler.common.enums.FalureStrategy; mport org.apache.dolphnscheduler.common.enums.Flag; mport org.apache.dolphnscheduler.common.enums.Prorty; mport org.apache.dolphnscheduler.common.enums.StateEventType; mport org.apache.dolphnscheduler.common.enums.TaskDependType; mport org.apache.dolphnscheduler.common.enums.TaskGroupQueueStatus; mport org.apache.dolphnscheduler.common.enums.WorkflowExecutonStatus; mport org.apache.dolphnscheduler.common.graph.DAG; mport org.apache.dolphnscheduler.common.model.TaskNode; mport org.apache.dolphnscheduler.common.model.TaskNodeRelaton; mport org.apache.dolphnscheduler.common.process.ProcessDag; mport org.apache.dolphnscheduler.common.thread.ThreadUtls; mport org.apache.dolphnscheduler.common.utls.DateUtls; mport org.apache.dolphnscheduler.common.utls.JSONUtls;
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
mport org.apache.dolphnscheduler.common.utls.LoggerUtls; mport org.apache.dolphnscheduler.common.utls.NetUtls; mport org.apache.dolphnscheduler.dao.entty.Command; mport org.apache.dolphnscheduler.dao.entty.Envronment; mport org.apache.dolphnscheduler.dao.entty.ProcessDefnton; mport org.apache.dolphnscheduler.dao.entty.ProcessInstance; mport org.apache.dolphnscheduler.dao.entty.ProcessTaskRelaton; mport org.apache.dolphnscheduler.dao.entty.ProjectUser; mport org.apache.dolphnscheduler.dao.entty.Schedule; mport org.apache.dolphnscheduler.dao.entty.TaskDefntonLog; mport org.apache.dolphnscheduler.dao.entty.TaskGroupQueue; mport org.apache.dolphnscheduler.dao.entty.TaskInstance; mport org.apache.dolphnscheduler.dao.repostory.ProcessInstanceDao; mport org.apache.dolphnscheduler.dao.utls.DagHelper; mport org.apache.dolphnscheduler.plugn.task.ap.enums.DependResult; mport org.apache.dolphnscheduler.plugn.task.ap.enums.Drect; mport org.apache.dolphnscheduler.plugn.task.ap.enums.TaskExecutonStatus; mport org.apache.dolphnscheduler.plugn.task.ap.model.Property; mport org.apache.dolphnscheduler.remote.command.HostUpdateCommand; mport org.apache.dolphnscheduler.remote.utls.Host; mport org.apache.dolphnscheduler.server.master.confg.MasterConfg; mport org.apache.dolphnscheduler.server.master.dspatch.executor.NettyExecutorManager; mport org.apache.dolphnscheduler.server.master.event.StateEvent; mport org.apache.dolphnscheduler.server.master.event.StateEventHandleError; mport org.apache.dolphnscheduler.server.master.event.StateEventHandleExcepton; mport org.apache.dolphnscheduler.server.master.event.StateEventHandler; mport org.apache.dolphnscheduler.server.master.event.StateEventHandlerManager; mport org.apache.dolphnscheduler.server.master.event.TaskStateEvent; mport org.apache.dolphnscheduler.server.master.event.WorkflowStateEvent; mport org.apache.dolphnscheduler.server.master.metrcs.TaskMetrcs;
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
mport org.apache.dolphnscheduler.server.master.runner.task.ITaskProcessor; mport org.apache.dolphnscheduler.server.master.runner.task.TaskActon; mport org.apache.dolphnscheduler.server.master.runner.task.TaskProcessorFactory; mport org.apache.dolphnscheduler.servce.alert.ProcessAlertManager; mport org.apache.dolphnscheduler.servce.cron.CronUtls; mport org.apache.dolphnscheduler.servce.exceptons.CronParseExcepton; mport org.apache.dolphnscheduler.servce.expand.CurngParamsServce; mport org.apache.dolphnscheduler.servce.process.ProcessServce; mport org.apache.dolphnscheduler.servce.queue.PeerTaskInstancePrortyQueue; mport org.apache.commons.collectons.CollectonUtls; mport org.apache.commons.lang3.StrngUtls; mport org.apache.commons.lang3.math.NumberUtls; mport java.utl.ArrayLst; mport java.utl.Arrays; mport java.utl.Collecton; mport java.utl.Collectons; mport java.utl.Date; mport java.utl.HashMap; mport java.utl.HashSet; mport java.utl.Iterator; mport java.utl.Lst; mport java.utl.Map; mport java.utl.Objects; mport java.utl.Optonal; mport java.utl.Set; mport java.utl.concurrent.Callable; mport java.utl.concurrent.ConcurrentHashMap; mport java.utl.concurrent.ConcurrentLnkedQueue; mport java.utl.concurrent.atomc.AtomcBoolean; mport java.utl.stream.Collectors;
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
mport lombok.NonNull; mport org.slf4j.Logger; mport org.slf4j.LoggerFactory; mport org.sprngframework.beans.BeanUtls; mport com.google.common.collect.Lsts; mport com.google.common.collect.Sets; /** * Workflow execute task, used to execute a workflow nstance. */ publc class WorkflowExecuteRunnable mplements Callable<WorkflowSubmtStatue> { prvate statc fnal Logger logger = LoggerFactory.getLogger(WorkflowExecuteRunnable.class); prvate fnal ProcessServce processServce; prvate ProcessInstanceDao processInstanceDao; prvate fnal ProcessAlertManager processAlertManager; prvate fnal NettyExecutorManager nettyExecutorManager; prvate fnal ProcessInstance processInstance; prvate ProcessDefnton processDefnton; prvate DAG<Strng, TaskNode, TaskNodeRelaton> dag; /** * unque key of workflow */ prvate Strng key; prvate WorkflowRunnableStatus workflowRunnableStatus = WorkflowRunnableStatus.CREATED; /** * submt falure nodes */ prvate boolean taskFaledSubmt = false; /** * task nstance hash map, taskId as key */
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
prvate fnal Map<Integer, TaskInstance> taskInstanceMap = new ConcurrentHashMap<>(); /** * runnng taskProcessor, taskCode as key, taskProcessor as value * only on taskProcessor per taskCode */ prvate fnal Map<Long, ITaskProcessor> actveTaskProcessorMaps = new ConcurrentHashMap<>(); /** * vald task map, taskCode as key, taskId as value * n a DAG, only one taskInstance per taskCode s vald */ prvate fnal Map<Long, Integer> valdTaskMap = new ConcurrentHashMap<>(); /** * error task map, taskCode as key, taskInstanceId as value * n a DAG, only one taskInstance per taskCode s vald */ prvate fnal Map<Long, Integer> errorTaskMap = new ConcurrentHashMap<>(); /** * complete task map, taskCode as key, taskInstanceId as value * n a DAG, only one taskInstance per taskCode s vald */ prvate fnal Map<Long, Integer> completeTaskMap = new ConcurrentHashMap<>(); /** * depend faled task set */ prvate fnal Set<Long> dependFaledTaskSet = Sets.newConcurrentHashSet(); /** * forbdden task map, code as key */ prvate fnal Map<Long, TaskNode> forbddenTaskMap = new ConcurrentHashMap<>(); /**
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
* skp task map, code as key */ prvate fnal Map<Strng, TaskNode> skpTaskNodeMap = new ConcurrentHashMap<>(); /** * complement date lst */ prvate Lst<Date> complementLstDate = Lsts.newLnkedLst(); /** * state event queue */ prvate fnal ConcurrentLnkedQueue<StateEvent> stateEvents = new ConcurrentLnkedQueue<>(); /** * The StandBy task lst, wll be executed, need to know, the taskInstance n ths queue may doesn't have d. */ prvate fnal PeerTaskInstancePrortyQueue readyToSubmtTaskQueue = new PeerTaskInstancePrortyQueue(); /** * wat to retry taskInstance map, taskCode as key, taskInstance as value * before retry, the taskInstance d s 0 */ prvate fnal Map<Long, TaskInstance> watToRetryTaskInstanceMap = new ConcurrentHashMap<>(); prvate fnal StateWheelExecuteThread stateWheelExecuteThread; prvate fnal CurngParamsServce curngParamsServce; prvate fnal Strng masterAddress; /** * @param processInstance processInstance * @param processServce processServce * @param processInstanceDao processInstanceDao * @param nettyExecutorManager nettyExecutorManager * @param processAlertManager processAlertManager * @param masterConfg masterConfg
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
* @param stateWheelExecuteThread stateWheelExecuteThread */ publc WorkflowExecuteRunnable( @NonNull ProcessInstance processInstance, @NonNull ProcessServce processServce, @NonNull ProcessInstanceDao processInstanceDao, @NonNull NettyExecutorManager nettyExecutorManager, @NonNull ProcessAlertManager processAlertManager, @NonNull MasterConfg masterConfg, @NonNull StateWheelExecuteThread stateWheelExecuteThread, @NonNull CurngParamsServce curngParamsServce) { ths.processServce = processServce; ths.processInstanceDao = processInstanceDao; ths.processInstance = processInstance; ths.nettyExecutorManager = nettyExecutorManager; ths.processAlertManager = processAlertManager; ths.stateWheelExecuteThread = stateWheelExecuteThread; ths.curngParamsServce = curngParamsServce; ths.masterAddress = NetUtls.getAddr(masterConfg.getLstenPort()); TaskMetrcs.regsterTaskPrepared(readyToSubmtTaskQueue::sze); } /** * the process start nodes are submtted completely. */ publc boolean sStart() { return WorkflowRunnableStatus.STARTED == workflowRunnableStatus; } /** * handle event */
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
publc vod handleEvents() { f (!sStart()) { logger.nfo( "The workflow nstance s not started, wll not handle ts state event, current state event sze: {}", stateEvents); return; } StateEvent stateEvent = null; whle (!ths.stateEvents.sEmpty()) { try { stateEvent = ths.stateEvents.peek(); LoggerUtls.setWorkflowAndTaskInstanceIDMDC(stateEvent.getProcessInstanceId(), stateEvent.getTaskInstanceId()); checkProcessInstance(stateEvent); StateEventHandler stateEventHandler = StateEventHandlerManager.getStateEventHandler(stateEvent.getType()) .orElseThrow(() -> new StateEventHandleError( "Cannot fnd handler for the gven state event")); logger.nfo("Begn to handle state event, {}", stateEvent); f (stateEventHandler.handleStateEvent(ths, stateEvent)) { ths.stateEvents.remove(stateEvent); } } catch (StateEventHandleError stateEventHandleError) { logger.error("State event handle error, wll remove ths event: {}", stateEvent, stateEventHandleError); ths.stateEvents.remove(stateEvent); ThreadUtls.sleep(Constants.SLEEP_TIME_MILLIS); } catch (StateEventHandleExcepton stateEventHandleExcepton) { logger.error("State event handle error, wll retry ths event: {}",
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
stateEvent, stateEventHandleExcepton); ThreadUtls.sleep(Constants.SLEEP_TIME_MILLIS); } catch (Excepton e) { logger.error("State event handle error, get a unknown excepton, wll retry ths event: {}", stateEvent, e); ThreadUtls.sleep(Constants.SLEEP_TIME_MILLIS); } fnally { LoggerUtls.removeWorkflowAndTaskInstanceIdMDC(); } } } publc Strng getKey() { f (StrngUtls.sNotEmpty(key) || ths.processDefnton == null) { return key; } key = Strng.format("%d_%d_%d", ths.processDefnton.getCode(), ths.processDefnton.getVerson(), ths.processInstance.getId()); return key; } publc boolean addStateEvent(StateEvent stateEvent) { f (processInstance.getId() != stateEvent.getProcessInstanceId()) { logger.nfo("state event would be abounded :{}", stateEvent); return false; }
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
ths.stateEvents.add(stateEvent); return true; } publc nt eventSze() { return ths.stateEvents.sze(); } publc ProcessInstance getProcessInstance() { return ths.processInstance; } publc boolean checkForceStartAndWakeUp(StateEvent stateEvent) { TaskGroupQueue taskGroupQueue = ths.processServce.loadTaskGroupQueue(stateEvent.getTaskInstanceId()); f (taskGroupQueue.getForceStart() == Flag.YES.getCode()) { TaskInstance taskInstance = ths.processServce.fndTaskInstanceById(stateEvent.getTaskInstanceId()); ITaskProcessor taskProcessor = actveTaskProcessorMaps.get(taskInstance.getTaskCode()); taskProcessor.acton(TaskActon.DISPATCH); ths.processServce.updateTaskGroupQueueStatus(taskGroupQueue.getTaskId(), TaskGroupQueueStatus.ACQUIRE_SUCCESS.getCode()); return true; } f (taskGroupQueue.getInQueue() == Flag.YES.getCode()) { boolean acqureTaskGroup = processServce.robTaskGroupResource(taskGroupQueue); f (acqureTaskGroup) { TaskInstance taskInstance = ths.processServce.fndTaskInstanceById(stateEvent.getTaskInstanceId()); ITaskProcessor taskProcessor = actveTaskProcessorMaps.get(taskInstance.getTaskCode()); taskProcessor.acton(TaskActon.DISPATCH); return true; } } return false; }
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
publc vod processTmeout() { ProjectUser projectUser = processServce.queryProjectWthUserByProcessInstanceId(processInstance.getId()); ths.processAlertManager.sendProcessTmeoutAlert(ths.processInstance, projectUser); } publc vod taskTmeout(TaskInstance taskInstance) { ProjectUser projectUser = processServce.queryProjectWthUserByProcessInstanceId(processInstance.getId()); processAlertManager.sendTaskTmeoutAlert(processInstance, taskInstance, projectUser); } publc vod taskFnshed(TaskInstance taskInstance) throws StateEventHandleExcepton { logger.nfo("TaskInstance fnshed task code:{} state:{}", taskInstance.getTaskCode(), taskInstance.getState()); try { actveTaskProcessorMaps.remove(taskInstance.getTaskCode()); stateWheelExecuteThread.removeTask4TmeoutCheck(processInstance, taskInstance); stateWheelExecuteThread.removeTask4RetryCheck(processInstance, taskInstance); stateWheelExecuteThread.removeTask4StateCheck(processInstance, taskInstance); f (taskInstance.getState().sSuccess()) { completeTaskMap.put(taskInstance.getTaskCode(), taskInstance.getId()); processInstance.setVarPool(taskInstance.getVarPool()); processInstanceDao.upsertProcessInstance(processInstance); f (!processInstance.sBlocked()) { submtPostNode(Long.toStrng(taskInstance.getTaskCode())); } } else f (taskInstance.taskCanRetry() && !processInstance.getState().sReadyStop()) { logger.nfo("Retry taskInstance taskInstance state: {}", taskInstance.getState()); retryTaskInstance(taskInstance); } else f (taskInstance.getState().sFalure()) { completeTaskMap.put(taskInstance.getTaskCode(), taskInstance.getId());
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
f (processInstance.getFalureStrategy() == FalureStrategy.CONTINUE && DagHelper.haveAllNodeAfterNode( Long.toStrng(taskInstance.getTaskCode()), dag)) { submtPostNode(Long.toStrng(taskInstance.getTaskCode())); } else { errorTaskMap.put(taskInstance.getTaskCode(), taskInstance.getId()); f (processInstance.getFalureStrategy() == FalureStrategy.END) { kllAllTasks(); } } } else f (taskInstance.getState().sFnshed()) { completeTaskMap.put(taskInstance.getTaskCode(), taskInstance.getId()); } logger.nfo("TaskInstance fnshed wll try to update the workflow nstance state, task code:{} state:{}", taskInstance.getTaskCode(), taskInstance.getState()); ths.updateProcessInstanceState(); } catch (Excepton ex) { logger.error("Task fnsh faled, get a excepton, wll remove ths taskInstance from completeTaskMap", ex); completeTaskMap.remove(taskInstance.getTaskCode()); throw ex; } } /** * release task group * * @param taskInstance */
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
publc vod releaseTaskGroup(TaskInstance taskInstance) { logger.nfo("Release task group"); f (taskInstance.getTaskGroupId() > 0) { TaskInstance nextTaskInstance = ths.processServce.releaseTaskGroup(taskInstance); f (nextTaskInstance != null) { f (nextTaskInstance.getProcessInstanceId() == taskInstance.getProcessInstanceId()) { TaskStateEvent nextEvent = TaskStateEvent.bulder() .processInstanceId(processInstance.getId()) .taskInstanceId(nextTaskInstance.getId()) .type(StateEventType.WAIT_TASK_GROUP) .buld(); ths.stateEvents.add(nextEvent); } else { ProcessInstance processInstance = ths.processServce.fndProcessInstanceById(nextTaskInstance.getProcessInstanceId()); ths.processServce.sendStartTask2Master(processInstance, nextTaskInstance.getId(), org.apache.dolphnscheduler.remote.command.CommandType.TASK_WAKEUP_EVENT_REQUEST); } } } } /** * crate new task nstance to retry, dfferent objects from the orgnal * * @param taskInstance */ prvate vod retryTaskInstance(TaskInstance taskInstance) throws StateEventHandleExcepton { f (!taskInstance.taskCanRetry()) { return; }
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
TaskInstance newTaskInstance = cloneRetryTaskInstance(taskInstance); f (newTaskInstance == null) { logger.error("retry fal, new taskInstance s null, task code:{}, task d:{}", taskInstance.getTaskCode(), taskInstance.getId()); return; } watToRetryTaskInstanceMap.put(newTaskInstance.getTaskCode(), newTaskInstance); f (!taskInstance.retryTaskIntervalOverTme()) { logger.nfo( "falure task wll be submtted: process d: {}, task nstance code: {} state:{} retry tmes:{} / {}, nterval:{}", processInstance.getId(), newTaskInstance.getTaskCode(), newTaskInstance.getState(), newTaskInstance.getRetryTmes(), newTaskInstance.getMaxRetryTmes(), newTaskInstance.getRetryInterval()); stateWheelExecuteThread.addTask4TmeoutCheck(processInstance, newTaskInstance); stateWheelExecuteThread.addTask4RetryCheck(processInstance, newTaskInstance); } else { addTaskToStandByLst(newTaskInstance); submtStandByTask(); watToRetryTaskInstanceMap.remove(newTaskInstance.getTaskCode()); } } /** * update process nstance */ publc vod refreshProcessInstance(nt processInstanceId) { logger.nfo("process nstance update: {}", processInstanceId); ProcessInstance newProcessInstance = processServce.fndProcessInstanceById(processInstanceId); BeanUtls.copyPropertes(newProcessInstance, processInstance);
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
processDefnton = processServce.fndProcessDefnton(processInstance.getProcessDefntonCode(), processInstance.getProcessDefntonVerson()); processInstance.setProcessDefnton(processDefnton); } /** * update task nstance */ publc vod refreshTaskInstance(nt taskInstanceId) { logger.nfo("task nstance update: {} ", taskInstanceId); TaskInstance taskInstance = processServce.fndTaskInstanceById(taskInstanceId); f (taskInstance == null) { logger.error("can not fnd task nstance, d:{}", taskInstanceId); return; } processServce.packageTaskInstance(taskInstance, processInstance); taskInstanceMap.put(taskInstance.getId(), taskInstance); valdTaskMap.remove(taskInstance.getTaskCode()); f (Flag.YES == taskInstance.getFlag()) { valdTaskMap.put(taskInstance.getTaskCode(), taskInstance.getId()); } } /** * check process nstance by state event */ publc vod checkProcessInstance(StateEvent stateEvent) throws StateEventHandleError { f (ths.processInstance.getId() != stateEvent.getProcessInstanceId()) { throw new StateEventHandleError("The event doesn't contans process nstance d"); } } /**
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
* check f task nstance exst by state event */ publc vod checkTaskInstanceByStateEvent(TaskStateEvent stateEvent) throws StateEventHandleError { f (stateEvent.getTaskInstanceId() == 0) { throw new StateEventHandleError("The taskInstanceId s 0"); } f (!taskInstanceMap.contansKey(stateEvent.getTaskInstanceId())) { throw new StateEventHandleError("Cannot fnd the taskInstance from taskInstanceMap"); } } /** * check f task nstance exst by d */ publc boolean checkTaskInstanceById(nt taskInstanceId) { f (taskInstanceMap.sEmpty()) { return false; } return taskInstanceMap.contansKey(taskInstanceId); } /** * get task nstance from memory */ publc Optonal<TaskInstance> getTaskInstance(nt taskInstanceId) { f (taskInstanceMap.contansKey(taskInstanceId)) { return Optonal.ofNullable(taskInstanceMap.get(taskInstanceId)); } return Optonal.empty(); } publc Optonal<TaskInstance> getTaskInstance(long taskCode) { f (taskInstanceMap.sEmpty()) {
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
return Optonal.empty(); } for (TaskInstance taskInstance : taskInstanceMap.values()) { f (taskInstance.getTaskCode() == taskCode) { return Optonal.of(taskInstance); } } return Optonal.empty(); } publc Optonal<TaskInstance> getActveTaskInstanceByTaskCode(long taskCode) { Integer taskInstanceId = valdTaskMap.get(taskCode); f (taskInstanceId != null) { return Optonal.ofNullable(taskInstanceMap.get(taskInstanceId)); } return Optonal.empty(); } publc Optonal<TaskInstance> getRetryTaskInstanceByTaskCode(long taskCode) { f (watToRetryTaskInstanceMap.contansKey(taskCode)) { return Optonal.ofNullable(watToRetryTaskInstanceMap.get(taskCode)); } return Optonal.empty(); } publc vod processBlock() { ProjectUser projectUser = processServce.queryProjectWthUserByProcessInstanceId(processInstance.getId()); processAlertManager.sendProcessBlockngAlert(processInstance, projectUser); logger.nfo("processInstance {} block alert send successful!", processInstance.getId()); } publc boolean processComplementData() { f (!needComplementProcess()) { return false;
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
} f (processInstance.getState().sReadyStop() || !processInstance.getState().sFnshed()) { return false; } Date scheduleDate = processInstance.getScheduleTme(); f (scheduleDate == null) { scheduleDate = complementLstDate.get(0); } else f (processInstance.getState().sFnshed()) { endProcess(); f (complementLstDate.sEmpty()) { logger.nfo("process complement end. process d:{}", processInstance.getId()); return true; } nt ndex = complementLstDate.ndexOf(scheduleDate); f (ndex >= complementLstDate.sze() - 1 || !processInstance.getState().sSuccess()) { logger.nfo("process complement end. process d:{}", processInstance.getId()); return true; } logger.nfo("process complement contnue. process d:{}, schedule tme:{} complementLstDate:{}", processInstance.getId(), processInstance.getScheduleTme(), complementLstDate); scheduleDate = complementLstDate.get(ndex + 1); } nt create = ths.createComplementDataCommand(scheduleDate); f (create > 0) { logger.nfo("create complement data command successfully."); }
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
return true; } prvate nt createComplementDataCommand(Date scheduleDate) { Command command = new Command(); command.setScheduleTme(scheduleDate); command.setCommandType(CommandType.COMPLEMENT_DATA); command.setProcessDefntonCode(processInstance.getProcessDefntonCode()); Map<Strng, Strng> cmdParam = JSONUtls.toMap(processInstance.getCommandParam()); f (cmdParam.contansKey(Constants.CMD_PARAM_RECOVERY_START_NODE_STRING)) { cmdParam.remove(Constants.CMD_PARAM_RECOVERY_START_NODE_STRING); } f (cmdParam.contansKey(CMDPARAM_COMPLEMENT_DATA_SCHEDULE_DATE_LIST)) { cmdParam.replace(CMDPARAM_COMPLEMENT_DATA_SCHEDULE_DATE_LIST, cmdParam.get(CMDPARAM_COMPLEMENT_DATA_SCHEDULE_DATE_LIST) .substrng(cmdParam.get(CMDPARAM_COMPLEMENT_DATA_SCHEDULE_DATE_LIST).ndexOf(COMMA) + 1)); } f (cmdParam.contansKey(CMDPARAM_COMPLEMENT_DATA_START_DATE)) { cmdParam.replace(CMDPARAM_COMPLEMENT_DATA_START_DATE, DateUtls.format(scheduleDate, YYYY_MM_DD_HH_MM_SS, null)); } command.setCommandParam(JSONUtls.toJsonStrng(cmdParam)); command.setTaskDependType(processInstance.getTaskDependType()); command.setFalureStrategy(processInstance.getFalureStrategy()); command.setWarnngType(processInstance.getWarnngType()); command.setWarnngGroupId(processInstance.getWarnngGroupId()); command.setStartTme(new Date()); command.setExecutorId(processInstance.getExecutorId()); command.setUpdateTme(new Date()); command.setProcessInstanceProrty(processInstance.getProcessInstanceProrty()); command.setWorkerGroup(processInstance.getWorkerGroup());
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
command.setEnvronmentCode(processInstance.getEnvronmentCode()); command.setDryRun(processInstance.getDryRun()); command.setProcessInstanceId(0); command.setProcessDefntonVerson(processInstance.getProcessDefntonVerson()); command.setTestFlag(processInstance.getTestFlag()); return processServce.createCommand(command); } prvate boolean needComplementProcess() { f (processInstance.sComplementData() && Flag.NO == processInstance.getIsSubProcess()) { return true; } return false; } /** * ProcessInstance start entrypont. */ @Overrde publc WorkflowSubmtStatue call() { f (sStart()) { logger.warn("[WorkflowInstance-{}] The workflow has already been started", processInstance.getId()); return WorkflowSubmtStatue.DUPLICATED_SUBMITTED; } try { LoggerUtls.setWorkflowInstanceIdMDC(processInstance.getId()); f (workflowRunnableStatus == WorkflowRunnableStatus.CREATED) { buldFlowDag(); workflowRunnableStatus = WorkflowRunnableStatus.INITIALIZE_DAG; logger.nfo("workflowStatue changed to :{}", workflowRunnableStatus); }
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
f (workflowRunnableStatus == WorkflowRunnableStatus.INITIALIZE_DAG) { ntTaskQueue(); workflowRunnableStatus = WorkflowRunnableStatus.INITIALIZE_QUEUE; logger.nfo("workflowStatue changed to :{}", workflowRunnableStatus); } f (workflowRunnableStatus == WorkflowRunnableStatus.INITIALIZE_QUEUE) { submtPostNode(null); workflowRunnableStatus = WorkflowRunnableStatus.STARTED; logger.nfo("workflowStatue changed to :{}", workflowRunnableStatus); } return WorkflowSubmtStatue.SUCCESS; } catch (Excepton e) { logger.error("Start workflow error", e); return WorkflowSubmtStatue.FAILED; } fnally { LoggerUtls.removeWorkflowInstanceIdMDC(); } } /** * process end handle */ publc vod endProcess() { ths.stateEvents.clear(); f (processDefnton.getExecutonType().typeIsSeralWat() || processDefnton.getExecutonType() .typeIsSeralProrty()) { checkSeralProcess(processDefnton); } ProjectUser projectUser = processServce.queryProjectWthUserByProcessInstanceId(processInstance.getId()); f (processAlertManager.sNeedToSendWarnng(processInstance)) { processAlertManager.sendAlertProcessInstance(processInstance, getValdTaskLst(), projectUser);
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
} f (processInstance.getState().sSuccess()) { processAlertManager.closeAlert(processInstance); } f (checkTaskQueue()) { processServce.releaseAllTaskGroup(processInstance.getId()); } } publc vod checkSeralProcess(ProcessDefnton processDefnton) { nt nextInstanceId = processInstance.getNextProcessInstanceId(); f (nextInstanceId == 0) { ProcessInstance nextProcessInstance = ths.processServce.loadNextProcess4Seral(processInstance.getProcessDefnton().getCode(), WorkflowExecutonStatus.SERIAL_WAIT.getCode(), processInstance.getId()); f (nextProcessInstance == null) { return; } ProcessInstance nextReadyStopProcessInstance = ths.processServce.loadNextProcess4Seral(processInstance.getProcessDefnton().getCode(), WorkflowExecutonStatus.READY_STOP.getCode(), processInstance.getId()); f (processDefnton.getExecutonType().typeIsSeralProrty() && nextReadyStopProcessInstance != null) { return; } nextInstanceId = nextProcessInstance.getId(); } ProcessInstance nextProcessInstance = ths.processServce.fndProcessInstanceById(nextInstanceId); f (nextProcessInstance.getState().sFnshed() || nextProcessInstance.getState().sRunnng()) { return; }
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
Map<Strng, Object> cmdParam = new HashMap<>(); cmdParam.put(CMD_PARAM_RECOVER_PROCESS_ID_STRING, nextInstanceId); Command command = new Command(); command.setCommandType(CommandType.RECOVER_SERIAL_WAIT); command.setProcessInstanceId(nextProcessInstance.getId()); command.setProcessDefntonCode(processDefnton.getCode()); command.setProcessDefntonVerson(processDefnton.getVerson()); command.setCommandParam(JSONUtls.toJsonStrng(cmdParam)); processServce.createCommand(command); } /** * Generate process dag * * @throws Excepton excepton */ prvate vod buldFlowDag() throws Excepton { processDefnton = processServce.fndProcessDefnton(processInstance.getProcessDefntonCode(), processInstance.getProcessDefntonVerson()); processInstance.setProcessDefnton(processDefnton); Lst<TaskInstance> recoverNodeLst = getRecoverTaskInstanceLst(processInstance.getCommandParam()); Lst<ProcessTaskRelaton> processTaskRelatons = processServce.fndRelatonByCode(processDefnton.getCode(), processDefnton.getVerson()); Lst<TaskDefntonLog> taskDefntonLogs = processServce.getTaskDefneLogLstByRelaton(processTaskRelatons); Lst<TaskNode> taskNodeLst = processServce.transformTask(processTaskRelatons, taskDefntonLogs); forbddenTaskMap.clear(); taskNodeLst.forEach(taskNode -> { f (taskNode.sForbdden()) { forbddenTaskMap.put(taskNode.getCode(), taskNode); }
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
}); Lst<Strng> recoveryNodeCodeLst = getRecoveryNodeCodeLst(recoverNodeLst); Lst<Strng> startNodeNameLst = parseStartNodeName(processInstance.getCommandParam()); ProcessDag processDag = generateFlowDag(taskNodeLst, startNodeNameLst, recoveryNodeCodeLst, processInstance.getTaskDependType()); f (processDag == null) { logger.error("processDag s null"); return; } dag = DagHelper.buldDagGraph(processDag); logger.nfo("Buld dag success, dag: {}", dag); } /** * nt task queue */ prvate vod ntTaskQueue() throws StateEventHandleExcepton, CronParseExcepton { taskFaledSubmt = false; actveTaskProcessorMaps.clear(); dependFaledTaskSet.clear(); completeTaskMap.clear(); errorTaskMap.clear(); f (!sNewProcessInstance()) { logger.nfo("The workflowInstance s not a newly runnng nstance, runtmes: {}, recover flag: {}", processInstance.getRunTmes(), processInstance.getRecovery()); Lst<TaskInstance> valdTaskInstanceLst = processServce.fndValdTaskLstByProcessId(processInstance.getId(), processInstance.getTestFlag()); for (TaskInstance task : valdTaskInstanceLst) {
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
try { LoggerUtls.setWorkflowAndTaskInstanceIDMDC(task.getProcessInstanceId(), task.getId()); logger.nfo( "Check the taskInstance from a exst workflowInstance, exstTaskInstanceCode: {}, taskInstanceStatus: {}", task.getTaskCode(), task.getState()); f (valdTaskMap.contansKey(task.getTaskCode())) { nt oldTaskInstanceId = valdTaskMap.get(task.getTaskCode()); TaskInstance oldTaskInstance = taskInstanceMap.get(oldTaskInstanceId); f (!oldTaskInstance.getState().sFnshed() && task.getState().sFnshed()) { task.setFlag(Flag.NO); processServce.updateTaskInstance(task); contnue; } logger.warn("have same taskCode taskInstance when nt task queue, taskCode:{}", task.getTaskCode()); } valdTaskMap.put(task.getTaskCode(), task.getId()); taskInstanceMap.put(task.getId(), task); f (task.sTaskComplete()) { completeTaskMap.put(task.getTaskCode(), task.getId()); contnue; } f (task.sCondtonsTask() || DagHelper.haveCondtonsAfterNode(Long.toStrng(task.getTaskCode()), dag)) { contnue; } f (task.taskCanRetry()) { f (task.getState().sNeedFaultTolerance()) { task.setFlag(Flag.NO);
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
processServce.updateTaskInstance(task); TaskInstance tolerantTaskInstance = cloneTolerantTaskInstance(task); addTaskToStandByLst(tolerantTaskInstance); } else { retryTaskInstance(task); } contnue; } f (task.getState().sFalure()) { errorTaskMap.put(task.getTaskCode(), task.getId()); } } fnally { LoggerUtls.removeWorkflowAndTaskInstanceIdMDC(); } } } else { logger.nfo("The current workflowInstance s a newly runnng workflowInstance"); } f (processInstance.sComplementData() && complementLstDate.sEmpty()) { Map<Strng, Strng> cmdParam = JSONUtls.toMap(processInstance.getCommandParam()); f (cmdParam != null) { setGlobalParamIfCommanded(processDefnton, cmdParam); Date start = null; Date end = null; f (cmdParam.contansKey(CMDPARAM_COMPLEMENT_DATA_START_DATE) && cmdParam.contansKey(CMDPARAM_COMPLEMENT_DATA_END_DATE)) { start = DateUtls.strngToDate(cmdParam.get(CMDPARAM_COMPLEMENT_DATA_START_DATE)); end = DateUtls.strngToDate(cmdParam.get(CMDPARAM_COMPLEMENT_DATA_END_DATE));
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
} f (complementLstDate.sEmpty() && needComplementProcess()) { f (start != null && end != null) { Lst<Schedule> schedules = processServce.queryReleaseSchedulerLstByProcessDefntonCode( processInstance.getProcessDefntonCode()); complementLstDate = CronUtls.getSelfFreDateLst(start, end, schedules); } f (cmdParam.contansKey(CMDPARAM_COMPLEMENT_DATA_SCHEDULE_DATE_LIST)) { complementLstDate = CronUtls.getSelfScheduleDateLst(cmdParam); } logger.nfo(" process defnton code:{} complement data: {}", processInstance.getProcessDefntonCode(), complementLstDate); f (!complementLstDate.sEmpty() && Flag.NO == processInstance.getIsSubProcess()) { processInstance.setScheduleTme(complementLstDate.get(0)); Strng globalParams = curngParamsServce.curngGlobalParams(processInstance.getId(), processDefnton.getGlobalParamMap(), processDefnton.getGlobalParamLst(), CommandType.COMPLEMENT_DATA, processInstance.getScheduleTme(), cmdParam.get(Constants.SCHEDULE_TIMEZONE)); processInstance.setGlobalParams(globalParams); processInstanceDao.updateProcessInstance(processInstance); } } } } logger.nfo("Intalze task queue, dependFaledTaskSet: {}, completeTaskMap: {}, errorTaskMap: {}", dependFaledTaskSet, completeTaskMap, errorTaskMap);
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
} /** * submt task to execute * * @param taskInstance task nstance * @return TaskInstance */ prvate Optonal<TaskInstance> submtTaskExec(TaskInstance taskInstance) { try { processServce.packageTaskInstance(taskInstance, processInstance); ITaskProcessor taskProcessor = TaskProcessorFactory.getTaskProcessor(taskInstance.getTaskType()); taskProcessor.nt(taskInstance, processInstance); f (taskInstance.getState().sRunnng() && taskProcessor.getType().equalsIgnoreCase(Constants.COMMON_TASK_TYPE)) { notfyProcessHostUpdate(taskInstance); } boolean submt = taskProcessor.acton(TaskActon.SUBMIT); f (!submt) { logger.error("process d:{} name:{} submt standby task d:{} name:{} faled!", processInstance.getId(), processInstance.getName(), taskInstance.getId(), taskInstance.getName()); return Optonal.empty(); } f (valdTaskMap.contansKey(taskInstance.getTaskCode())) { nt oldTaskInstanceId = valdTaskMap.get(taskInstance.getTaskCode()); f (taskInstance.getId() != oldTaskInstanceId) {
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
TaskInstance oldTaskInstance = taskInstanceMap.get(oldTaskInstanceId); oldTaskInstance.setFlag(Flag.NO); processServce.updateTaskInstance(oldTaskInstance); valdTaskMap.remove(taskInstance.getTaskCode()); actveTaskProcessorMaps.remove(taskInstance.getTaskCode()); } } valdTaskMap.put(taskInstance.getTaskCode(), taskInstance.getId()); taskInstanceMap.put(taskInstance.getId(), taskInstance); actveTaskProcessorMaps.put(taskInstance.getTaskCode(), taskProcessor); nt taskGroupId = taskInstance.getTaskGroupId(); f (taskGroupId > 0) { boolean acqureTaskGroup = processServce.acqureTaskGroup(taskInstance.getId(), taskInstance.getName(), taskGroupId, taskInstance.getProcessInstanceId(), taskInstance.getTaskGroupProrty()); f (!acqureTaskGroup) { logger.nfo("submt task name :{}, but the frst tme to try to acqure task group faled", taskInstance.getName()); return Optonal.of(taskInstance); } } boolean dspatchSuccess = taskProcessor.acton(TaskActon.DISPATCH); f (!dspatchSuccess) { logger.error("process d:{} name:{} dspatch standby task d:{} name:{} faled!", processInstance.getId(),
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
processInstance.getName(), taskInstance.getId(), taskInstance.getName()); return Optonal.empty(); } taskProcessor.acton(TaskActon.RUN); stateWheelExecuteThread.addTask4TmeoutCheck(processInstance, taskInstance); stateWheelExecuteThread.addTask4StateCheck(processInstance, taskInstance); f (taskProcessor.taskInstance().getState().sFnshed()) { f (processInstance.sBlocked()) { TaskStateEvent processBlockEvent = TaskStateEvent.bulder() .processInstanceId(processInstance.getId()) .taskInstanceId(taskInstance.getId()) .status(taskProcessor.taskInstance().getState()) .type(StateEventType.PROCESS_BLOCKED) .buld(); ths.stateEvents.add(processBlockEvent); } TaskStateEvent taskStateChangeEvent = TaskStateEvent.bulder() .processInstanceId(processInstance.getId()) .taskInstanceId(taskInstance.getId()) .status(taskProcessor.taskInstance().getState()) .type(StateEventType.TASK_STATE_CHANGE) .buld(); ths.stateEvents.add(taskStateChangeEvent); } return Optonal.of(taskInstance); } catch (Excepton e) { logger.error("submt standby task error, taskCode: {}, taskInstanceId: {}", taskInstance.getTaskCode(),
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
taskInstance.getId(), e); return Optonal.empty(); } } prvate vod notfyProcessHostUpdate(TaskInstance taskInstance) { f (StrngUtls.sEmpty(taskInstance.getHost())) { return; } try { HostUpdateCommand hostUpdateCommand = new HostUpdateCommand(); hostUpdateCommand.setProcessHost(masterAddress); hostUpdateCommand.setTaskInstanceId(taskInstance.getId()); Host host = new Host(taskInstance.getHost()); nettyExecutorManager.doExecute(host, hostUpdateCommand.convert2Command()); } catch (Excepton e) { logger.error("notfy process host update", e); } } /** * fnd task nstance n db. * n case submt more than one same name task n the same tme. * * @param taskCode task code * @param taskVerson task verson * @return TaskInstance */ prvate TaskInstance fndTaskIfExsts(Long taskCode, nt taskVerson) { Lst<TaskInstance> valdTaskInstanceLst = getValdTaskLst();
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
for (TaskInstance taskInstance : valdTaskInstanceLst) { f (taskInstance.getTaskCode() == taskCode && taskInstance.getTaskDefntonVerson() == taskVerson) { return taskInstance; } } return null; } /** * encapsulaton task, ths method wll only create a new task nstance, the return task nstance wll not contan d. * * @param processInstance process nstance * @param taskNode taskNode * @return TaskInstance */ prvate TaskInstance createTaskInstance(ProcessInstance processInstance, TaskNode taskNode) { TaskInstance taskInstance = fndTaskIfExsts(taskNode.getCode(), taskNode.getVerson()); f (taskInstance != null) { return taskInstance; } return newTaskInstance(processInstance, taskNode); } /** * clone a new taskInstance for retry and reset some logc felds * * @return */ publc TaskInstance cloneRetryTaskInstance(TaskInstance taskInstance) { TaskNode taskNode = dag.getNode(Long.toStrng(taskInstance.getTaskCode())); f (taskNode == null) { logger.error("taskNode s null, code:{}", taskInstance.getTaskCode());
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
return null; } TaskInstance newTaskInstance = newTaskInstance(processInstance, taskNode); newTaskInstance.setTaskDefne(taskInstance.getTaskDefne()); newTaskInstance.setProcessDefne(taskInstance.getProcessDefne()); newTaskInstance.setProcessInstance(processInstance); newTaskInstance.setRetryTmes(taskInstance.getRetryTmes() + 1); newTaskInstance.setState(taskInstance.getState()); newTaskInstance.setEndTme(taskInstance.getEndTme()); f (taskInstance.getState() == TaskExecutonStatus.NEED_FAULT_TOLERANCE) { newTaskInstance.setAppLnk(taskInstance.getAppLnk()); } return newTaskInstance; } /** * clone a new taskInstance for tolerant and reset some logc felds * * @return */ publc TaskInstance cloneTolerantTaskInstance(TaskInstance taskInstance) { TaskNode taskNode = dag.getNode(Long.toStrng(taskInstance.getTaskCode())); f (taskNode == null) { logger.error("taskNode s null, code:{}", taskInstance.getTaskCode()); return null; } TaskInstance newTaskInstance = newTaskInstance(processInstance, taskNode); newTaskInstance.setTaskDefne(taskInstance.getTaskDefne()); newTaskInstance.setProcessDefne(taskInstance.getProcessDefne()); newTaskInstance.setProcessInstance(processInstance);
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
newTaskInstance.setRetryTmes(taskInstance.getRetryTmes()); newTaskInstance.setState(taskInstance.getState()); newTaskInstance.setAppLnk(taskInstance.getAppLnk()); return newTaskInstance; } /** * new a taskInstance * * @param processInstance * @param taskNode * @return */ publc TaskInstance newTaskInstance(ProcessInstance processInstance, TaskNode taskNode) { TaskInstance taskInstance = new TaskInstance(); taskInstance.setTaskCode(taskNode.getCode()); taskInstance.setTaskDefntonVerson(taskNode.getVerson()); taskInstance.setName(taskNode.getName()); taskInstance.setState(TaskExecutonStatus.SUBMITTED_SUCCESS); taskInstance.setProcessInstanceId(processInstance.getId()); taskInstance.setTaskType(taskNode.getType().toUpperCase()); taskInstance.setAlertFlag(Flag.NO); taskInstance.setStartTme(null); taskInstance.setTestFlag(processInstance.getTestFlag());
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
taskInstance.setFlag(Flag.YES); taskInstance.setDryRun(processInstance.getDryRun()); taskInstance.setRetryTmes(0); taskInstance.setMaxRetryTmes(taskNode.getMaxRetryTmes()); taskInstance.setRetryInterval(taskNode.getRetryInterval()); taskInstance.setTaskParams(taskNode.getTaskParams()); taskInstance.setTaskGroupId(taskNode.getTaskGroupId()); taskInstance.setTaskGroupProrty(taskNode.getTaskGroupProrty()); taskInstance.setCpuQuota(taskNode.getCpuQuota()); taskInstance.setMemoryMax(taskNode.getMemoryMax()); f (taskNode.getTaskInstanceProrty() == null) { taskInstance.setTaskInstanceProrty(Prorty.MEDIUM); } else { taskInstance.setTaskInstanceProrty(taskNode.getTaskInstanceProrty()); } Strng processWorkerGroup = processInstance.getWorkerGroup(); processWorkerGroup = StrngUtls.sBlank(processWorkerGroup) ? DEFAULT_WORKER_GROUP : processWorkerGroup; Strng taskWorkerGroup = StrngUtls.sBlank(taskNode.getWorkerGroup()) ? processWorkerGroup : taskNode.getWorkerGroup(); Long processEnvronmentCode = Objects.sNull(processInstance.getEnvronmentCode()) ? -1 : processInstance.getEnvronmentCode();
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
Long taskEnvronmentCode = Objects.sNull(taskNode.getEnvronmentCode()) ? processEnvronmentCode : taskNode.getEnvronmentCode(); f (!processWorkerGroup.equals(DEFAULT_WORKER_GROUP) && taskWorkerGroup.equals(DEFAULT_WORKER_GROUP)) { taskInstance.setWorkerGroup(processWorkerGroup); taskInstance.setEnvronmentCode(processEnvronmentCode); } else { taskInstance.setWorkerGroup(taskWorkerGroup); taskInstance.setEnvronmentCode(taskEnvronmentCode); } f (!taskInstance.getEnvronmentCode().equals(-1L)) { Envronment envronment = processServce.fndEnvronmentByCode(taskInstance.getEnvronmentCode()); f (Objects.nonNull(envronment) && StrngUtls.sNotEmpty(envronment.getConfg())) { taskInstance.setEnvronmentConfg(envronment.getConfg()); } } taskInstance.setDelayTme(taskNode.getDelayTme()); taskInstance.setTaskExecuteType(taskNode.getTaskExecuteType()); return taskInstance; } publc vod getPreVarPool(TaskInstance taskInstance, Set<Strng> preTask) { Map<Strng, Property> allProperty = new HashMap<>(); Map<Strng, TaskInstance> allTaskInstance = new HashMap<>(); f (CollectonUtls.sNotEmpty(preTask)) { for (Strng preTaskCode : preTask) { Integer taskId = completeTaskMap.get(Long.parseLong(preTaskCode)); f (taskId == null) { contnue; } TaskInstance preTaskInstance = taskInstanceMap.get(taskId);
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
f (preTaskInstance == null) { contnue; } Strng preVarPool = preTaskInstance.getVarPool(); f (StrngUtls.sNotEmpty(preVarPool)) { Lst<Property> propertes = JSONUtls.toLst(preVarPool, Property.class); for (Property nfo : propertes) { setVarPoolValue(allProperty, allTaskInstance, preTaskInstance, nfo); } } } f (allProperty.sze() > 0) { taskInstance.setVarPool(JSONUtls.toJsonStrng(allProperty.values())); } } else { f (StrngUtls.sNotEmpty(processInstance.getVarPool())) { taskInstance.setVarPool(processInstance.getVarPool()); } } } publc Collecton<TaskInstance> getAllTaskInstances() { return taskInstanceMap.values(); } prvate vod setVarPoolValue(Map<Strng, Property> allProperty, Map<Strng, TaskInstance> allTaskInstance, TaskInstance preTaskInstance, Property thsProperty) { thsProperty.setDrect(Drect.IN); Strng proName = thsProperty.getProp();
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
f (allProperty.contansKey(proName)) { Property otherPro = allProperty.get(proName); f (StrngUtls.sEmpty(thsProperty.getValue())) { allProperty.put(proName, otherPro); } else f (StrngUtls.sNotEmpty(otherPro.getValue())) { TaskInstance otherTask = allTaskInstance.get(proName); f (otherTask.getEndTme().getTme() > preTaskInstance.getEndTme().getTme()) { allProperty.put(proName, thsProperty); allTaskInstance.put(proName, preTaskInstance); } else { allProperty.put(proName, otherPro); } } else { allProperty.put(proName, thsProperty); allTaskInstance.put(proName, preTaskInstance); } } else { allProperty.put(proName, thsProperty); allTaskInstance.put(proName, preTaskInstance); } } /** * get complete task nstance map, taskCode as key */ prvate Map<Strng, TaskInstance> getCompleteTaskInstanceMap() { Map<Strng, TaskInstance> completeTaskInstanceMap = new HashMap<>(); for (Map.Entry<Long, Integer> entry : completeTaskMap.entrySet()) {
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
Long taskConde = entry.getKey(); Integer taskInstanceId = entry.getValue(); TaskInstance taskInstance = taskInstanceMap.get(taskInstanceId); f (taskInstance == null) { logger.warn("Cannot fnd the taskInstance from taskInstanceMap, taskInstanceId: {}, taskConde: {}", taskInstanceId, taskConde); contnue; } completeTaskInstanceMap.put(Long.toStrng(taskInstance.getTaskCode()), taskInstance); } return completeTaskInstanceMap; } /** * get vald task lst */ prvate Lst<TaskInstance> getValdTaskLst() { Lst<TaskInstance> valdTaskInstanceLst = new ArrayLst<>(); for (Integer taskInstanceId : valdTaskMap.values()) { valdTaskInstanceLst.add(taskInstanceMap.get(taskInstanceId)); } return valdTaskInstanceLst; } prvate vod submtPostNode(Strng parentNodeCode) throws StateEventHandleExcepton { Set<Strng> submtTaskNodeLst = DagHelper.parsePostNodes(parentNodeCode, skpTaskNodeMap, dag, getCompleteTaskInstanceMap()); Lst<TaskInstance> taskInstances = new ArrayLst<>(); for (Strng taskNode : submtTaskNodeLst) { TaskNode taskNodeObject = dag.getNode(taskNode);
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
Optonal<TaskInstance> exstTaskInstanceOptonal = getTaskInstance(taskNodeObject.getCode()); f (exstTaskInstanceOptonal.sPresent()) { taskInstances.add(exstTaskInstanceOptonal.get()); contnue; } TaskInstance task = createTaskInstance(processInstance, taskNodeObject); taskInstances.add(task); } f (StrngUtls.sNotEmpty(parentNodeCode) && dag.getEndNode().contans(parentNodeCode)) { TaskInstance endTaskInstance = taskInstanceMap.get(completeTaskMap.get(NumberUtls.toLong(parentNodeCode))); Strng taskInstanceVarPool = endTaskInstance.getVarPool(); f (StrngUtls.sNotEmpty(taskInstanceVarPool)) { Set<Property> taskPropertes = new HashSet<>(JSONUtls.toLst(taskInstanceVarPool, Property.class)); Strng processInstanceVarPool = processInstance.getVarPool(); f (StrngUtls.sNotEmpty(processInstanceVarPool)) { Set<Property> propertes = new HashSet<>(JSONUtls.toLst(processInstanceVarPool, Property.class)); propertes.addAll(taskPropertes); processInstance.setVarPool(JSONUtls.toJsonStrng(propertes)); } else { processInstance.setVarPool(JSONUtls.toJsonStrng(taskPropertes)); } } } for (TaskInstance task : taskInstances) { f (readyToSubmtTaskQueue.contans(task)) { logger.warn("Task s already at submt queue, taskInstanceId: {}", task.getId()); contnue; }
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
f (task.getId() != null && completeTaskMap.contansKey(task.getTaskCode())) { logger.nfo("task {} has already run success", task.getName()); contnue; } f (task.getState().sKll()) { logger.nfo("task {} stopped, the state s {}", task.getName(), task.getState()); contnue; } addTaskToStandByLst(task); } submtStandByTask(); updateProcessInstanceState(); } /** * determne whether the dependences of the task node are complete * * @return DependResult */ prvate DependResult sTaskDepsComplete(Strng taskCode) { Collecton<Strng> startNodes = dag.getBegnNode(); f (startNodes.contans(taskCode)) { return DependResult.SUCCESS; } TaskNode taskNode = dag.getNode(taskCode); Lst<Strng> ndrectDepCodeLst = new ArrayLst<>(); setIndrectDepLst(taskCode, ndrectDepCodeLst); for (Strng depsNode : ndrectDepCodeLst) { f (dag.contansNode(depsNode) && !skpTaskNodeMap.contansKey(depsNode)) {
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
Long despNodeTaskCode = Long.parseLong(depsNode); f (!completeTaskMap.contansKey(despNodeTaskCode)) { return DependResult.WAITING; } Integer depsTaskId = completeTaskMap.get(despNodeTaskCode); TaskExecutonStatus depTaskState = taskInstanceMap.get(depsTaskId).getState(); f (depTaskState.sKll()) { return DependResult.NON_EXEC; } f (taskNode.sBlockngTask()) { contnue; } f (taskNode.sCondtonsTask()) { contnue; } f (!dependTaskSuccess(depsNode, taskCode)) { return DependResult.FAILED; } } } logger.nfo("taskCode: {} completeDependTaskLst: {}", taskCode, Arrays.toStrng(completeTaskMap.keySet().toArray())); return DependResult.SUCCESS; } /** * Ths functon s specally used to handle the dependency stuaton where the parent node s a prohbted node. * When the parent node s a forbdden node, the dependency relatonshp should contnue to be traced *
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
* @param taskCode taskCode * @param ndrectDepCodeLst All ndrectly dependent nodes */ prvate vod setIndrectDepLst(Strng taskCode, Lst<Strng> ndrectDepCodeLst) { TaskNode taskNode = dag.getNode(taskCode); Lst<Strng> depCodeLst = taskNode.getDepLst(); for (Strng depsNode : depCodeLst) { f (forbddenTaskMap.contansKey(Long.parseLong(depsNode))) { setIndrectDepLst(depsNode, ndrectDepCodeLst); } else { ndrectDepCodeLst.add(depsNode); } } } /** * depend node s completed, but here need check the condton task branch s the next node */ prvate boolean dependTaskSuccess(Strng dependNodeName, Strng nextNodeName) { f (dag.getNode(dependNodeName).sCondtonsTask()) { Lst<Strng> nextTaskLst = DagHelper.parseCondtonTask(dependNodeName, skpTaskNodeMap, dag, getCompleteTaskInstanceMap()); f (!nextTaskLst.contans(nextNodeName)) { return false; } } else { long taskCode = Long.parseLong(dependNodeName); Integer taskInstanceId = completeTaskMap.get(taskCode); TaskExecutonStatus depTaskState = taskInstanceMap.get(taskInstanceId).getState(); f (depTaskState.sFalure()) {
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
return false; } } return true; } /** * query task nstance by complete state * * @param state state * @return task nstance lst */ prvate Lst<TaskInstance> getCompleteTaskByState(TaskExecutonStatus state) { Lst<TaskInstance> resultLst = new ArrayLst<>(); for (Integer taskInstanceId : completeTaskMap.values()) { TaskInstance taskInstance = taskInstanceMap.get(taskInstanceId); f (taskInstance != null && taskInstance.getState() == state) { resultLst.add(taskInstance); } } return resultLst; } /** * where there are ongong tasks * * @param state state * @return ExecutonStatus */ prvate WorkflowExecutonStatus runnngState(WorkflowExecutonStatus state) { f (state == WorkflowExecutonStatus.READY_STOP || state == WorkflowExecutonStatus.READY_PAUSE || state == WorkflowExecutonStatus.READY_BLOCK ||
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
state == WorkflowExecutonStatus.DELAY_EXECUTION) { return state; } else { return WorkflowExecutonStatus.RUNNING_EXECUTION; } } /** * exsts falure task,contans submt falure、dependency falure,execute falure(retry after) * * @return Boolean whether has faled task */ prvate boolean hasFaledTask() { f (ths.taskFaledSubmt) { return true; } f (ths.errorTaskMap.sze() > 0) { return true; } return ths.dependFaledTaskSet.sze() > 0; } /** * process nstance falure * * @return Boolean whether process nstance faled */ prvate boolean processFaled() { f (hasFaledTask()) { logger.nfo("The current process has faled task, the current process faled"); f (processInstance.getFalureStrategy() == FalureStrategy.END) {
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
return true; } f (processInstance.getFalureStrategy() == FalureStrategy.CONTINUE) { return readyToSubmtTaskQueue.sze() == 0 && actveTaskProcessorMaps.sze() == 0 && watToRetryTaskInstanceMap.sze() == 0; } } return false; } /** * prepare for pause * 1,faled retry task n the preparaton queue , returns to falure drectly * 2,exsts pause task,complement not completed, pendng submsson of tasks, return to suspenson * 3,success * * @return ExecutonStatus */ prvate WorkflowExecutonStatus processReadyPause() { f (hasRetryTaskInStandBy()) { return WorkflowExecutonStatus.FAILURE; } Lst<TaskInstance> pauseLst = getCompleteTaskByState(TaskExecutonStatus.PAUSE); f (CollectonUtls.sNotEmpty(pauseLst) || processInstance.sBlocked() || !sComplementEnd() || readyToSubmtTaskQueue.sze() > 0) { return WorkflowExecutonStatus.PAUSE; } else { return WorkflowExecutonStatus.SUCCESS; } } /**
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
* prepare for block * f process has tasks stll runnng, pause them * f readyToSubmtTaskQueue s not empty, kll them * else return block status drectly * * @return ExecutonStatus */ prvate WorkflowExecutonStatus processReadyBlock() { f (actveTaskProcessorMaps.sze() > 0) { for (ITaskProcessor taskProcessor : actveTaskProcessorMaps.values()) { f (!TASK_TYPE_BLOCKING.equals(taskProcessor.getType())) { taskProcessor.acton(TaskActon.PAUSE); } } } f (readyToSubmtTaskQueue.sze() > 0) { for (Iterator<TaskInstance> ter = readyToSubmtTaskQueue.terator(); ter.hasNext();) { ter.next().setState(TaskExecutonStatus.PAUSE); } } return WorkflowExecutonStatus.BLOCK; } /** * generate the latest process nstance status by the tasks state * * @return process nstance executon status */ prvate WorkflowExecutonStatus getProcessInstanceState(ProcessInstance nstance) { WorkflowExecutonStatus state = nstance.getState(); f (actveTaskProcessorMaps.sze() > 0 || hasRetryTaskInStandBy()) {
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
// actve WorkflowExecutonStatus executonStatus = runnngState(state); logger.nfo("The workflowInstance has task runnng, the workflowInstance status s {}", executonStatus); return executonStatus; } // block f (state == WorkflowExecutonStatus.READY_BLOCK) { WorkflowExecutonStatus executonStatus = processReadyBlock(); logger.nfo("The workflowInstance s ready to block, the workflowInstance status s {}", executonStatus); return executonStatus; } // pause f (state == WorkflowExecutonStatus.READY_PAUSE) { WorkflowExecutonStatus executonStatus = processReadyPause(); logger.nfo("The workflowInstance s ready to pause, the workflow status s {}", executonStatus); return executonStatus; } // stop f (state == WorkflowExecutonStatus.READY_STOP) { Lst<TaskInstance> kllLst = getCompleteTaskByState(TaskExecutonStatus.KILL); Lst<TaskInstance> falLst = getCompleteTaskByState(TaskExecutonStatus.FAILURE); WorkflowExecutonStatus executonStatus; f (CollectonUtls.sNotEmpty(kllLst) || CollectonUtls.sNotEmpty(falLst) || !sComplementEnd()) { executonStatus = WorkflowExecutonStatus.STOP; } else { executonStatus = WorkflowExecutonStatus.SUCCESS; } logger.nfo("The workflowInstance s ready to stop, the workflow status s {}", executonStatus); return executonStatus; }
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
// process falure f (processFaled()) { logger.nfo("The workflowInstance s faled, the workflow status s {}", WorkflowExecutonStatus.FAILURE); return WorkflowExecutonStatus.FAILURE; } // success f (state == WorkflowExecutonStatus.RUNNING_EXECUTION) { Lst<TaskInstance> kllTasks = getCompleteTaskByState(TaskExecutonStatus.KILL); f (readyToSubmtTaskQueue.sze() > 0 || watToRetryTaskInstanceMap.sze() > 0) { // tasks c return WorkflowExecutonStatus.RUNNING_EXECUTION; } else f (CollectonUtls.sNotEmpty(kllTasks)) { // tasks m return WorkflowExecutonStatus.FAILURE; } else { // f the return WorkflowExecutonStatus.SUCCESS; } } return state; } /** * whether complement end * * @return Boolean whether s complement end */ prvate boolean sComplementEnd() { f (!processInstance.sComplementData()) { return true; }
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
Map<Strng, Strng> cmdParam = JSONUtls.toMap(processInstance.getCommandParam()); Date endTme = DateUtls.strngToDate(cmdParam.get(CMDPARAM_COMPLEMENT_DATA_END_DATE)); return processInstance.getScheduleTme().equals(endTme); } /** * updateProcessInstance process nstance state * after each batch of tasks s executed, of the process nstance s updated */ prvate vod updateProcessInstanceState() throws StateEventHandleExcepton { WorkflowExecutonStatus state = getProcessInstanceState(processInstance); f (processInstance.getState() != state) { logger.nfo("Update workflowInstance states, orgn state: {}, target state: {}", processInstance.getState(), state); updateWorkflowInstanceStatesToDB(state); WorkflowStateEvent stateEvent = WorkflowStateEvent.bulder() .processInstanceId(processInstance.getId()) .status(processInstance.getState()) .type(StateEventType.PROCESS_STATE_CHANGE) .buld(); // replace ths.stateEvents.add(stateEvent); } else { logger.nfo("There s no need to update the workflow nstance state, orgn state: {}, target state: {}", processInstance.getState(), state); } } /** * stateEvent's executon status as process nstance state
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
*/ publc vod updateProcessInstanceState(WorkflowStateEvent stateEvent) throws StateEventHandleExcepton { WorkflowExecutonStatus state = stateEvent.getStatus(); updateWorkflowInstanceStatesToDB(state); } prvate vod updateWorkflowInstanceStatesToDB(WorkflowExecutonStatus newStates) throws StateEventHandleExcepton { WorkflowExecutonStatus orgnStates = processInstance.getState(); f (orgnStates != newStates) { logger.nfo("Begn to update workflow nstance state , state wll change from {} to {}", orgnStates, newStates); processInstance.setStateWthDesc(newStates, "update by workflow executor"); f (newStates.sFnshed()) { processInstance.setEndTme(new Date()); } try { processInstanceDao.updateProcessInstance(processInstance); } catch (Excepton ex) { // recover processInstance.setStateWthDesc(orgnStates, "recover state by DB error"); processInstance.setEndTme(null); throw new StateEventHandleExcepton("Update process nstance status to DB error", ex); } } } /** * get task dependency result * * @param taskInstance task nstance * @return DependResult
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
*/ prvate DependResult getDependResultForTask(TaskInstance taskInstance) { return sTaskDepsComplete(Long.toStrng(taskInstance.getTaskCode())); } /** * add task to standby lst * * @param taskInstance task nstance */ publc vod addTaskToStandByLst(TaskInstance taskInstance) { f (readyToSubmtTaskQueue.contans(taskInstance)) { logger.warn("task was found n ready submt queue, task code:{}", taskInstance.getTaskCode()); return; } logger.nfo("add task to stand by lst, task name:{}, task d:{}, task code:{}", taskInstance.getName(), taskInstance.getId(), taskInstance.getTaskCode()); TaskMetrcs.ncTaskInstanceByState("submt"); readyToSubmtTaskQueue.put(taskInstance); } /** * remove task from stand by lst * * @param taskInstance task nstance */ prvate boolean removeTaskFromStandbyLst(TaskInstance taskInstance) { return readyToSubmtTaskQueue.remove(taskInstance); } /**
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
* has retry task n standby * * @return Boolean whether has retry task n standby */ prvate boolean hasRetryTaskInStandBy() { for (Iterator<TaskInstance> ter = readyToSubmtTaskQueue.terator(); ter.hasNext();) { f (ter.next().getState().sFalure()) { return true; } } return false; } /** * close the on gong tasks */ publc vod kllAllTasks() { logger.nfo("kll called on process nstance d: {}, num: {}", processInstance.getId(), actveTaskProcessorMaps.sze()); f (readyToSubmtTaskQueue.sze() > 0) { readyToSubmtTaskQueue.clear(); } for (long taskCode : actveTaskProcessorMaps.keySet()) { ITaskProcessor taskProcessor = actveTaskProcessorMaps.get(taskCode); Integer taskInstanceId = valdTaskMap.get(taskCode); f (taskInstanceId == null || taskInstanceId.equals(0)) { contnue; } TaskInstance taskInstance = processServce.fndTaskInstanceById(taskInstanceId); f (taskInstance == null || taskInstance.getState().sFnshed()) {
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
contnue; } taskProcessor.acton(TaskActon.STOP); f (taskProcessor.taskInstance().getState().sFnshed()) { TaskStateEvent taskStateEvent = TaskStateEvent.bulder() .processInstanceId(processInstance.getId()) .taskInstanceId(taskInstance.getId()) .status(taskProcessor.taskInstance().getState()) .type(StateEventType.TASK_STATE_CHANGE) .buld(); ths.addStateEvent(taskStateEvent); } } } publc boolean workFlowFnsh() { return ths.processInstance.getState().sFnshed(); } /** * handlng the lst of tasks to be submtted */ publc vod submtStandByTask() throws StateEventHandleExcepton { nt length = readyToSubmtTaskQueue.sze(); for (nt = 0; < length; ++) { TaskInstance task = readyToSubmtTaskQueue.peek(); f (task == null) { contnue; } // stop ta f (task.taskCanRetry()) { TaskInstance retryTask = processServce.fndTaskInstanceById(task.getId());
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
f (retryTask != null && retryTask.getState().sForceSuccess()) { task.setState(retryTask.getState()); logger.nfo("task: {} has been forced success, put t nto complete task lst and stop retryng", task.getName()); removeTaskFromStandbyLst(task); completeTaskMap.put(task.getTaskCode(), task.getId()); taskInstanceMap.put(task.getId(), task); submtPostNode(Long.toStrng(task.getTaskCode())); contnue; } } // nt va f (task.sFrstRun()) { // get pre Set<Strng> preTask = dag.getPrevousNodes(Long.toStrng(task.getTaskCode())); getPreVarPool(task, preTask); } DependResult dependResult = getDependResultForTask(task); f (DependResult.SUCCESS == dependResult) { Optonal<TaskInstance> taskInstanceOptonal = submtTaskExec(task); f (!taskInstanceOptonal.sPresent()) { ths.taskFaledSubmt = true; // Remove f (!removeTaskFromStandbyLst(task)) { logger.error( "Task submt faled, remove from standby lst faled, workflowInstanceId: {}, taskCode: {}", processInstance.getId(), task.getTaskCode()); } completeTaskMap.put(task.getTaskCode(), task.getId());
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
taskInstanceMap.put(task.getId(), task); errorTaskMap.put(task.getTaskCode(), task.getId()); actveTaskProcessorMaps.remove(task.getTaskCode()); logger.error("Task submtted faled, workflowInstanceId: {}, taskInstanceId: {}, taskCode: {}", task.getProcessInstanceId(), task.getId(), task.getTaskCode()); } else { removeTaskFromStandbyLst(task); } } else f (DependResult.FAILED == dependResult) { // f the dependFaledTaskSet.add(task.getTaskCode()); removeTaskFromStandbyLst(task); logger.nfo("Task dependent result s faled, taskInstanceId:{} depend result : {}", task.getId(), dependResult); } else f (DependResult.NON_EXEC == dependResult) { // for som removeTaskFromStandbyLst(task); logger.nfo("Remove task due to depend result not executed, taskInstanceId:{} depend result : {}", task.getId(), dependResult); } } } /** * Get start task nstance lst from recover * * @param cmdParam command param * @return task nstance lst */
closed
apache/dolphinscheduler
https://github.com/apache/dolphinscheduler
11,753
[Bug] [Alert Server] send alert error alert data id
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened when I want to test Email send when a task finish , I get a error : [INFO] 2022-09-02 08:00:11.268 +0000 org.apache.dolphinscheduler.alert.AlertRequestProcessor:[52] - Received command : AlertSendRequestCommand{groupId=0, title='sql_hive query result sets', content='[{"_c0":36816}]', warnType=1} [ERROR] 2022-09-02 08:00:11.270 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[148] - Alert GroupId 0 send error : not found alert instance [ERROR] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[244] - send alert error alert data id :57, java.lang.NullPointerException: User must not be null at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.dolphinscheduler.plugin.alert.email.MailSender.<init>(MailSender.java:109) at org.apache.dolphinscheduler.plugin.alert.email.EmailAlertChannel.process(EmailAlertChannel.java:41) at org.apache.dolphinscheduler.alert.AlertSenderService.alertResultHandler(AlertSenderService.java:232) at org.apache.dolphinscheduler.alert.AlertSenderService.send(AlertSenderService.java:105) at org.apache.dolphinscheduler.alert.AlertSenderService.run(AlertSenderService.java:76) [INFO] 2022-09-02 08:00:14.699 +0000 org.apache.dolphinscheduler.alert.AlertSenderService:[255] - Alert Plugin Email-Alert send error : User must not be null ### What you expected to happen I should got a Email when a task finish ### How to reproduce create a Email group , smtp then I create a test task , run It with a Email group ,then will get the same error ### Anything else dolphin 3.0 pseudo-cluster install ### Version 3.0.0 ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
https://github.com/apache/dolphinscheduler/issues/11753
https://github.com/apache/dolphinscheduler/pull/11774
57fafe42567b434d5a8ef4673ca5d9796cc4dd05
e27c79974d93d0d4181a0f5dbe45159084e224d3
2022-09-02T08:19:12Z
java
2022-09-29T07:34:40Z
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteRunnable.java
protected Lst<TaskInstance> getRecoverTaskInstanceLst(Strng cmdParam) { Map<Strng, Strng> paramMap = JSONUtls.toMap(cmdParam); // todo: Can we use a better way to set the recover taskInstanceId lst? rather then use the cmdParam f (paramMap != null && paramMap.contansKey(CMD_PARAM_RECOVERY_START_NODE_STRING)) { Lst<Integer> startTaskInstanceIds = Arrays.stream(paramMap.get(CMD_PARAM_RECOVERY_START_NODE_STRING) .splt(COMMA)) .flter(StrngUtls::sNotEmpty) .map(Integer::valueOf) .collect(Collectors.toLst()); f (CollectonUtls.sNotEmpty(startTaskInstanceIds)) { return processServce.fndTaskInstanceByIdLst(startTaskInstanceIds); } } return Collectons.emptyLst(); } /** * parse "StartNodeNameLst" from cmd param * * @param cmdParam command param * @return start node name lst */ prvate Lst<Strng> parseStartNodeName(Strng cmdParam) { Lst<Strng> startNodeNameLst = new ArrayLst<>(); Map<Strng, Strng> paramMap = JSONUtls.toMap(cmdParam); f (paramMap == null) { return startNodeNameLst; } f (paramMap.contansKey(CMD_PARAM_START_NODES)) { startNodeNameLst = Arrays.asLst(paramMap.get(CMD_PARAM_START_NODES).splt(Constants.COMMA)); }