Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 825C7200AE4 for ; Fri, 24 Jun 2016 17:31:18 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 80FD9160A2E; Fri, 24 Jun 2016 15:31:18 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id CB08C160A5A for ; Fri, 24 Jun 2016 17:31:17 +0200 (CEST) Received: (qmail 91924 invoked by uid 500); 24 Jun 2016 15:31:16 -0000 Mailing-List: contact dev-help@reef.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@reef.apache.org Delivered-To: mailing list dev@reef.apache.org Received: (qmail 91439 invoked by uid 99); 24 Jun 2016 15:31:16 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 24 Jun 2016 15:31:16 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 3746A2C1F64 for ; Fri, 24 Jun 2016 15:31:16 +0000 (UTC) Date: Fri, 24 Jun 2016 15:31:16 +0000 (UTC) From: "Markus Weimer (JIRA)" To: dev@reef.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (REEF-1466) Cancel the blocking message reading and close the task properly MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Fri, 24 Jun 2016 15:31:18 -0000 [ https://issues.apache.org/jira/browse/REEF-1466?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15348429#comment-15348429 ] Markus Weimer commented on REEF-1466: ------------------------------------- I don't know :) Which APIs do you intend to expand with the optional parameter? > Cancel the blocking message reading and close the task properly > --------------------------------------------------------------- > > Key: REEF-1466 > URL: https://issues.apache.org/jira/browse/REEF-1466 > Project: REEF > Issue Type: Task > Reporter: Julia > Labels: FT > > Currently when driver sends an event to kill a task, in IMRU task close handler, we set a flag for the Call() method to return from next iteration. If the Call() method stuck in reading messages, we throw IMRUTaskSystemException so that for the IMRU driver to receive IFailedTask. After the drive killed all the tasks, the drive will resubmit tasks if the system is recoverable. > In REEF-1447, the proposed solution for exceptions throw from task close handler is to fail the Evaluator. With the current IMRU task close handler, this would make all evaluators fail after the tasks are killed by driver. If we want to treat the exception in close handler as FailedEvaluator, we must gracefully handle the task close event instead of throw an exception. > I would like to re-propose the cancellation token solution we discussed before. Pass a cancellation token from task all the way to the NodeStruct.GetData(). When the task close handler is called, cancel the cancellation token for the task to return properly. > This will involve some GC/Network method signature changes, some are internal some are public. > Let me know if you have any concerns about this solution. -- This message was sent by Atlassian JIRA (v6.3.4#6332)