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 72BD9200AC8 for ; Tue, 24 May 2016 01:07:14 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 713AF160A2B; Mon, 23 May 2016 23:07:14 +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 E7642160A0E for ; Tue, 24 May 2016 01:07:13 +0200 (CEST) Received: (qmail 95375 invoked by uid 500); 23 May 2016 23:07:13 -0000 Mailing-List: contact dev-help@arrow.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@arrow.apache.org Delivered-To: mailing list dev@arrow.apache.org Received: (qmail 95321 invoked by uid 99); 23 May 2016 23:07:13 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 23 May 2016 23:07:13 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id E4E5C2C033A for ; Mon, 23 May 2016 23:07:12 +0000 (UTC) Date: Mon, 23 May 2016 23:07:12 +0000 (UTC) From: "Venki Korukanti (JIRA)" To: dev@arrow.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Created] (ARROW-207) Extend BufferAllocator interface to allow decorators around BufferAllocator MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Mon, 23 May 2016 23:07:14 -0000 Venki Korukanti created ARROW-207: ------------------------------------- Summary: Extend BufferAllocator interface to allow decorators around BufferAllocator Key: ARROW-207 URL: https://issues.apache.org/jira/browse/ARROW-207 Project: Apache Arrow Issue Type: Improvement Components: Java - Memory Reporter: Venki Korukanti Priority: Minor Currently AllocationManager needs BufferAllocator instance reference for accounting purposes. Having a decorator around the BufferAllocator distrubs the accounting in AllocationManager. Add an unwrap method to allow getting the reference to inner BufferAllocator instance and use this method in AllocationManager to get the actual BufferAllocator. {code:java} /** * Unwrap the class so that exposes the provided interface, if possible. Otherwise, throw Exception. * @param c * The class or interface that you want this class to implement/extend. * @return The instance of that class related to 'this' */ T unwrap(Class c); {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)