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 72B0C200BC2 for ; Thu, 17 Nov 2016 18:37:49 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 72882160B0B; Thu, 17 Nov 2016 17:37:49 +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 BD03A160AD8 for ; Thu, 17 Nov 2016 18:37:48 +0100 (CET) Received: (qmail 74049 invoked by uid 500); 17 Nov 2016 17:37:48 -0000 Mailing-List: contact commits-help@helix.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@helix.apache.org Delivered-To: mailing list commits@helix.apache.org Received: (qmail 74040 invoked by uid 99); 17 Nov 2016 17:37:47 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 17 Nov 2016 17:37:47 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id 618B3C0674 for ; Thu, 17 Nov 2016 17:37:47 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -7.019 X-Spam-Level: X-Spam-Status: No, score=-7.019 tagged_above=-999 required=6.31 tests=[KAM_LAZY_DOMAIN_SECURITY=1, RCVD_IN_DNSWL_HI=-5, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RP_MATCHES_RCVD=-2.999] autolearn=disabled Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id dR8_ZTxR19JG for ; Thu, 17 Nov 2016 17:37:46 +0000 (UTC) Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with SMTP id 6710F5FCF0 for ; Thu, 17 Nov 2016 17:37:46 +0000 (UTC) Received: (qmail 72076 invoked by uid 99); 17 Nov 2016 17:36:58 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 17 Nov 2016 17:36:58 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 90F182C4C73 for ; Thu, 17 Nov 2016 17:36:58 +0000 (UTC) Date: Thu, 17 Nov 2016 17:36:58 +0000 (UTC) From: "Lei Xia (JIRA)" To: commits@helix.incubator.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Assigned] (HELIX-56) Delayed state transition MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Thu, 17 Nov 2016 17:37:49 -0000 [ https://issues.apache.org/jira/browse/HELIX-56?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Lei Xia reassigned HELIX-56: ---------------------------- Assignee: Lei Xia > Delayed state transition > ------------------------ > > Key: HELIX-56 > URL: https://issues.apache.org/jira/browse/HELIX-56 > Project: Apache Helix > Issue Type: Task > Affects Versions: 0.6.0-incubating > Reporter: kishore gopalakrishna > Assignee: Lei Xia > > The requirement from Puneet > I wanted to know how to implement a specific state machine requirement in Helix. > Lets say a partition is in the state S2. > 1. On an instance hosting it going down, the partition moves to state > S3 (but stays on the same instance). > 2. If the instance comes back up before a timeout expires, the > partition moves to state S1 (stays on the same instance). > 3. If the instance does not come back up before the timeout expiry, > the partition moves to state S0 (the initial state, on a different > instance picked up by the controller). > I have a few questions. > 1. I believe in order to implement Requirement 1, I have to use the > CUSTOM rebalancing feature (as otherwise the partitions will get > assigned to a new node). > The wiki page says the following about the CUSTOM mode. > "Applications will have to implement an interface that Helix will > invoke when the cluster state changes. Within this callback, the > application can recompute the partition assignment mapping" > Which interface does one have to implement ? I am assuming the > callbacks are triggered inside the controller. > 2. The transition from S2 -> S3 should not issue a callback on the > participant (instance) holding that partition. This is because the > participant is unavailable and so cannot execute the callback. Is this > doable ? > 3. One way the time-out (Requirement 3) can be implemented is to > occasionally trigger IdealState calculation after a time-out and not > only on liveness changes. Does that sound doable ? -- This message was sent by Atlassian JIRA (v6.3.4#6332)