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 227B9200BAA for ; Thu, 13 Oct 2016 04:27:22 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 20FBD160AFA; Thu, 13 Oct 2016 02:27: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 8F777160ACA for ; Thu, 13 Oct 2016 04:27:21 +0200 (CEST) Received: (qmail 80654 invoked by uid 500); 13 Oct 2016 02:27:20 -0000 Mailing-List: contact dev-help@curator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@curator.apache.org Delivered-To: mailing list dev@curator.apache.org Received: (qmail 80626 invoked by uid 99); 13 Oct 2016 02:27:20 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 13 Oct 2016 02:27:20 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id A5E472C0086 for ; Thu, 13 Oct 2016 02:27:20 +0000 (UTC) Date: Thu, 13 Oct 2016 02:27:20 +0000 (UTC) From: "Cameron McKenzie (JIRA)" To: dev@curator.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Resolved] (CURATOR-354) GzipCompressionProvider leaks native memory MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Thu, 13 Oct 2016 02:27:22 -0000 [ https://issues.apache.org/jira/browse/CURATOR-354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Cameron McKenzie resolved CURATOR-354. -------------------------------------- Resolution: Fixed Fix Version/s: 2.11.1 3.2.1 > GzipCompressionProvider leaks native memory > ------------------------------------------- > > Key: CURATOR-354 > URL: https://issues.apache.org/jira/browse/CURATOR-354 > Project: Apache Curator > Issue Type: Bug > Affects Versions: 2.11.0 > Reporter: Evan Pollan > Assignee: Jordan Zimmerman > Fix For: 3.2.1, 2.11.1 > > Attachments: RSS before and after fix.png > > > Both compress and decompress instantiate GZIP streams, use them, and don't close them. The java util deflate/inflate streams use JNI to leverage zlib, including the allocation of a native, off-heap buffer. > These JNI buffer handles are released when the containing stream is closed. They're also released by the finalize() method on java.util.zip.Inflater/Deflater, _but_ it looks as if the native memory can pile up quickly enough in certain use cases where the JVM is OOM killed before the finalizer does its thing. > Fix is to explicitly close these streams after they're used. > This was discovered in version 2.11.0, but it looks like the problem affects all versions for which {{GzipCompressionProvider}} existed. -- This message was sent by Atlassian JIRA (v6.3.4#6332)