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 4DC91200BFB for ; Wed, 7 Dec 2016 06:03:00 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 4C8B8160B1B; Wed, 7 Dec 2016 05:03:00 +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 C7FDC160B2D for ; Wed, 7 Dec 2016 06:02:59 +0100 (CET) Received: (qmail 92262 invoked by uid 500); 7 Dec 2016 05:02:58 -0000 Mailing-List: contact issues-help@hbase.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list issues@hbase.apache.org Received: (qmail 92035 invoked by uid 99); 7 Dec 2016 05:02:58 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 07 Dec 2016 05:02:58 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 70C2D2C03E1 for ; Wed, 7 Dec 2016 05:02:58 +0000 (UTC) Date: Wed, 7 Dec 2016 05:02:58 +0000 (UTC) From: "Duo Zhang (JIRA)" To: issues@hbase.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (HBASE-17251) Add a timeout parameter when locating region MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Wed, 07 Dec 2016 05:03:00 -0000 [ https://issues.apache.org/jira/browse/HBASE-17251?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Duo Zhang updated HBASE-17251: ------------------------------ Attachment: HBASE-17251.patch > Add a timeout parameter when locating region > -------------------------------------------- > > Key: HBASE-17251 > URL: https://issues.apache.org/jira/browse/HBASE-17251 > Project: HBase > Issue Type: Sub-task > Components: asyncclient, Client > Affects Versions: 2.0.0 > Reporter: Duo Zhang > Fix For: 2.0.0 > > Attachments: HBASE-17251.patch > > > Now we always use the default timeout configured for zk and meta. > I think it is reasonable to always use the same timeout when accessing zk and meta as the result will be shared by lots of threads. If we could do a successful fetching then the result will be in cache so it does not make sense to set the timeout to a very small value when fetching. > But I think it is also important to let the user request finish in time even if the user can only get a timeout exception. We should not block a user request longer than operation timeout. > So I think we could add a timeout parameter to the region locate method, and if the location can not be fetched in time, we will just finished the returned CompletableFuture with a timeout exception, but the actual fetching operation can still go on and use its own timeout config. -- This message was sent by Atlassian JIRA (v6.3.4#6332)