code: void kill() {
      assert (this.dag.getStatus() == Status.KILLING);
      if (this.status == Status.READY || this.status == Status.BLOCKED) {
        // If the node is disabled, keep the status as disabled.
        changeStatus(Status.CANCELED);
      } else if (this.status == Status.RUNNING) {
        changeStatus(Status.KILLING);
      }
      // If the node has finished, leave the status intact.
    }
docs: Kills a node.
  
  <p>A node is not designed to be killed individually. This method expects {@link Dag#kill()}
  method to kill all nodes. Thus this method itself doesn't need to propagate the kill signal to
  the node's children nodes.