Return-Path: X-Original-To: apmail-phoenix-dev-archive@minotaur.apache.org Delivered-To: apmail-phoenix-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 7C25711B7A for ; Fri, 2 May 2014 04:58:47 +0000 (UTC) Received: (qmail 43618 invoked by uid 500); 2 May 2014 04:58:39 -0000 Delivered-To: apmail-phoenix-dev-archive@phoenix.apache.org Received: (qmail 43534 invoked by uid 500); 2 May 2014 04:58:37 -0000 Mailing-List: contact dev-help@phoenix.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@phoenix.incubator.apache.org Delivered-To: mailing list dev@phoenix.incubator.apache.org Received: (qmail 43285 invoked by uid 99); 2 May 2014 04:58:36 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 02 May 2014 04:58:36 +0000 X-ASF-Spam-Status: No, hits=-2000.7 required=5.0 tests=ALL_TRUSTED,RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.3] (HELO mail.apache.org) (140.211.11.3) by apache.org (qpsmtpd/0.29) with SMTP; Fri, 02 May 2014 04:58:35 +0000 Received: (qmail 39420 invoked by uid 99); 2 May 2014 04:58:15 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 02 May 2014 04:58:15 +0000 Date: Fri, 2 May 2014 04:58:15 +0000 (UTC) From: "James Taylor (JIRA)" To: dev@phoenix.incubator.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Resolved] (PHOENIX-624) Changes metadata caches to be LRU MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/PHOENIX-624?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] James Taylor resolved PHOENIX-624. ---------------------------------- Resolution: Fixed Fix Version/s: 5.0.0 4.0.0 3.0.0 > Changes metadata caches to be LRU > --------------------------------- > > Key: PHOENIX-624 > URL: https://issues.apache.org/jira/browse/PHOENIX-624 > Project: Phoenix > Issue Type: Task > Affects Versions: 3.0-Release > Reporter: elevine > Assignee: James Taylor > Fix For: 3.0.0, 4.0.0, 5.0.0 > > > From @jamestaylor: There are two metadata caches in the system: one on the server side maintained by MetaDataEndpointImpl, the other on the client side maintained by PMetaDataImpl. In this multi tenant scheme, we'll need to change those to be LRU caches, as they're currently allowed to grow unbounded. The server side cache will scan the SYSTEM.TABLE on a cache miss and the client side will ask the server for a PTable it doesn't find, so making them be an LRU cache should not be too difficult. To switch to an LRU cache on the server-side, just change the GlobalCache metaDataCacheMap member variable from ConcurrentHashMap to a Guava Cache. To change on the client-side, change the PMetaDataImpl metaData member variable from a Map to a Cache. In both cases create a new config property that will drive a size-based eviction policy. -- This message was sent by Atlassian JIRA (v6.2#6252)