This is an automated email from the ASF dual-hosted git repository.

gian pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/druid.git


The following commit(s) were added to refs/heads/master by this push:
     new 6f5c1434b8 fix get task may be null (#12100)
6f5c1434b8 is described below

commit 6f5c1434b8cb1ce9e48efca465a81bed2741cada
Author: 刘小辉 <[email protected]>
AuthorDate: Thu Aug 4 00:23:48 2022 +0800

    fix get task may be null (#12100)
---
 .../org/apache/druid/indexing/overlord/hrtr/HttpRemoteTaskRunner.java   | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/indexing-service/src/main/java/org/apache/druid/indexing/overlord/hrtr/HttpRemoteTaskRunner.java
 
b/indexing-service/src/main/java/org/apache/druid/indexing/overlord/hrtr/HttpRemoteTaskRunner.java
index aa377cb247..19279af327 100644
--- 
a/indexing-service/src/main/java/org/apache/druid/indexing/overlord/hrtr/HttpRemoteTaskRunner.java
+++ 
b/indexing-service/src/main/java/org/apache/druid/indexing/overlord/hrtr/HttpRemoteTaskRunner.java
@@ -591,7 +591,7 @@ public class HttpRemoteTaskRunner implements 
WorkerTaskRunner, TaskLogStreamer
           for (Map.Entry<String, HttpRemoteTaskRunnerWorkItem> e : 
tasks.entrySet()) {
             if (e.getValue().getState() == 
HttpRemoteTaskRunnerWorkItem.State.RUNNING) {
               Worker w = e.getValue().getWorker();
-              if (w != null && w.getHost().equals(worker.getHost())) {
+              if (w != null && w.getHost().equals(worker.getHost()) && 
e.getValue().getTask() != null) {
                 expectedAnnouncements.add(
                     TaskAnnouncement.create(
                         e.getValue().getTask(),


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to