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 6D142200B67 for ; Mon, 1 Aug 2016 15:46:22 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 6BD1A160AAE; Mon, 1 Aug 2016 13:46:22 +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 D8B27160A6C for ; Mon, 1 Aug 2016 15:46:21 +0200 (CEST) Received: (qmail 20454 invoked by uid 500); 1 Aug 2016 13:46:21 -0000 Mailing-List: contact oak-issues-help@jackrabbit.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: oak-dev@jackrabbit.apache.org Delivered-To: mailing list oak-issues@jackrabbit.apache.org Received: (qmail 20290 invoked by uid 99); 1 Aug 2016 13:46:21 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 01 Aug 2016 13:46:21 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id C07252C0D62 for ; Mon, 1 Aug 2016 13:46:20 +0000 (UTC) Date: Mon, 1 Aug 2016 13:46:20 +0000 (UTC) From: "Andrei Dulceanu (JIRA)" To: oak-issues@jackrabbit.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (OAK-4579) Improve FileStore.size calculation MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Mon, 01 Aug 2016 13:46:22 -0000 [ https://issues.apache.org/jira/browse/OAK-4579?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Andrei Dulceanu updated OAK-4579: --------------------------------- Attachment: (was: OAK-4579-01.patch) > Improve FileStore.size calculation > ---------------------------------- > > Key: OAK-4579 > URL: https://issues.apache.org/jira/browse/OAK-4579 > Project: Jackrabbit Oak > Issue Type: Task > Components: segment-tar > Reporter: Andrei Dulceanu > Assignee: Andrei Dulceanu > Priority: Minor > Labels: resilience > Fix For: Segment Tar 1.0.0 > > Attachments: OAK-4579-01.patch > > > A new approach for calculating {{FileStore::size}} is needed because this method is prone to lock contention and should not be called too often. > The steps to implement the approach are: > # reduce the lock surface of the size() method. This should be simple enough by creating a copy of the readers / writer inside the lock and do the actual size calculation on that snapshot but outside of the lock. > # lower size() visibility to package to avoid misuse (from monitoring tools) > # remove {{approximateSize}} and associated logic and replace it with {{size()}}. -- This message was sent by Atlassian JIRA (v6.3.4#6332)