You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tez.apache.org by "Jianfeng (Jeff) Zhang" <jz...@hortonworks.com> on 2015/04/03 11:36:42 UTC

Why not failing vertex when task is killed ?

I notice that vertex will be killed when any task is failed, but won't been killed when task is killed (TaskCompletedTransition in VertexImpl)
Is it for the task that is killed when parallelism of vertex is changed ?  The logic here cause the completedTaskCount may be greater than succeededTaskCount.

But looking at the code of VertexImpl.checkVertexForCompletion, vertex should succeed only when completedTaskCount is equal to succeededTaskCount.


  if (vertex.completedTaskCount == vertex.tasks.size()) {

      //Only succeed if tasks complete successfully and no terminationCause is registered.

      if(vertex.succeededTaskCount == vertex.tasks.size() && vertex.terminationCause == null) {



Best Regard,
Jeff Zhang


Re: Why not failing vertex when task is killed ?

Posted by "Jianfeng (Jeff) Zhang" <jz...@hortonworks.com>.
I think I got it, because task should only been killed by vertex. Task killed means vertex has already trigger the killing,  so it is not necessary to trigger it again when task is killed.

Best Regard,
Jeff Zhang


From: Jianfeng Zhang <jz...@hortonworks.com>>
Date: Friday, April 3, 2015 at 5:36 PM
To: "dev@tez.apache.org<ma...@tez.apache.org>" <de...@tez.apache.org>>
Subject: Why not failing vertex when task is killed ?


I notice that vertex will be killed when any task is failed, but won't been killed when task is killed (TaskCompletedTransition in VertexImpl)
Is it for the task that is killed when parallelism of vertex is changed ?  The logic here cause the completedTaskCount may be greater than succeededTaskCount.

But looking at the code of VertexImpl.checkVertexForCompletion, vertex should succeed only when completedTaskCount is equal to succeededTaskCount.


  if (vertex.completedTaskCount == vertex.tasks.size()) {

      //Only succeed if tasks complete successfully and no terminationCause is registered.

      if(vertex.succeededTaskCount == vertex.tasks.size() && vertex.terminationCause == null) {



Best Regard,
Jeff Zhang