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 A84E82009DC for ; Tue, 2 May 2017 21:23:07 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id A6EE0160BAC; Tue, 2 May 2017 19:23:07 +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 EE371160B9D for ; Tue, 2 May 2017 21:23:06 +0200 (CEST) Received: (qmail 90371 invoked by uid 500); 2 May 2017 19:23:06 -0000 Mailing-List: contact dev-help@phoenix.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@phoenix.apache.org Delivered-To: mailing list dev@phoenix.apache.org Received: (qmail 90358 invoked by uid 99); 2 May 2017 19:23:06 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd2-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 02 May 2017 19:23:06 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd2-us-west.apache.org (ASF Mail Server at spamd2-us-west.apache.org) with ESMTP id A401B1A02E9 for ; Tue, 2 May 2017 19:23:05 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd2-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -99.202 X-Spam-Level: X-Spam-Status: No, score=-99.202 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, RP_MATCHES_RCVD=-0.001, SPF_PASS=-0.001, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd2-us-west.apache.org [10.40.0.9]) (amavisd-new, port 10024) with ESMTP id qlx_hMhholM8 for ; Tue, 2 May 2017 19:23:05 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTP id C2B675F283 for ; Tue, 2 May 2017 19:23:04 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 653BAE01A8 for ; Tue, 2 May 2017 19:23:04 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id 222DE21B53 for ; Tue, 2 May 2017 19:23:04 +0000 (UTC) Date: Tue, 2 May 2017 19:23:04 +0000 (UTC) From: "Maddineni Sukumar (JIRA)" To: dev@phoenix.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (PHOENIX-3823) Force cache update on MetaDataEntityNotFoundException MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Tue, 02 May 2017 19:23:07 -0000 [ https://issues.apache.org/jira/browse/PHOENIX-3823?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15993556#comment-15993556 ] Maddineni Sukumar commented on PHOENIX-3823: -------------------------------------------- Sure James, I cant expect more detailed info with steps, classes to use than this :) . Thanks for making my job smooth during my first patch to Phoenix. Will work on unit test today and patch today. > Force cache update on MetaDataEntityNotFoundException > ------------------------------------------------------ > > Key: PHOENIX-3823 > URL: https://issues.apache.org/jira/browse/PHOENIX-3823 > Project: Phoenix > Issue Type: Sub-task > Reporter: James Taylor > Assignee: Maddineni Sukumar > > When UPDATE_CACHE_FREQUENCY is used, clients will cache metadata for a period of time which may cause the schema being used to become stale. If another client adds a column or a new table or view, other clients won't see it. As a result, the client will get a MetaDataEntityNotFoundException. Instead of bubbling this up, we should retry after forcing a cache update on the tables involved in the query. > The above works well for references to entities that don't yet exist. However, we cannot detect when some entities are referred to which no longer exists until the cache expires. An exception is if a physical table is dropped which would be detected immediately, however we would allow queries and updates to columns which have been dropped until the cache entry expires (which seems like a reasonable tradeoff IMHO. In addition, we won't start using indexes on tables until the cache expires. -- This message was sent by Atlassian JIRA (v6.3.15#6346)