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 BDD60200C7F for ; Wed, 10 May 2017 02:58:11 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id BC54B160BC3; Wed, 10 May 2017 00:58:11 +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 0F3B3160BB6 for ; Wed, 10 May 2017 02:58:10 +0200 (CEST) Received: (qmail 20314 invoked by uid 500); 10 May 2017 00:58:10 -0000 Mailing-List: contact dev-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@activemq.apache.org Delivered-To: mailing list dev@activemq.apache.org Received: (qmail 20302 invoked by uid 99); 10 May 2017 00:58:09 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 10 May 2017 00:58:09 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id 77051C0922 for ; Wed, 10 May 2017 00:58:09 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -0.396 X-Spam-Level: X-Spam-Status: No, score=-0.396 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=2, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-2.796, RCVD_IN_SORBS_SPAM=0.5, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=disabled Authentication-Results: spamd4-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id dVMpixgvgzud for ; Wed, 10 May 2017 00:58:08 +0000 (UTC) Received: from mail-wr0-f178.google.com (mail-wr0-f178.google.com [209.85.128.178]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTPS id E3B455F4EE for ; Wed, 10 May 2017 00:58:07 +0000 (UTC) Received: by mail-wr0-f178.google.com with SMTP id l9so22010058wre.1 for ; Tue, 09 May 2017 17:58:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=/dkfRk+fcA50OIaOjofwH8FP+i8bnlt3y1ehRXK/Fug=; b=lt/BEIK9+wRpysJhfml6+caLazlLex4vZfIwxS6KtDc0mWbj6/9xxFl1kzzE6yQ8c0 haOQmrOQfBRy4kKCxaqfAJn4umrDvQV0ipgDc2BwSbkmkgqZp8F2Ld77DAiZ0r1AYgdd 02NBkeShsqksi5sxLeq9vInWnNq1Rr8/713QVPRv9xcJ/hE+IZ8B+TdycooQ0ez8gbeN E9fIaqgmnMDrm4nUK+BqQrMr4c+ife7z0Gj44H+r79HgHXkii0odLFDP5SWv5INe83PX TiYNrLEORRgKODT+cRvHtxlaVq20WH0iJQv6lWOBEJxKln+nnzYK0yX9s6rtC1cqc+bD y47g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=/dkfRk+fcA50OIaOjofwH8FP+i8bnlt3y1ehRXK/Fug=; b=Zqkj1eXZZyIIcuXBxqlmmQReG64veP2e2MVtweLOVBZogs8RoshHm9mjfD0NKNPlHT OUT9jl3B0U1RWG/eUUtOTl6amnj2NrGiJzJ2cYOFmbRITSA51rvcb72cgYdEfTuLTGkY 8DBOflFufSy65Z/O5WUUU1I9/2nGbsvTgCgq/NUZcBvvvD9VezX1ITlkenZjjPeCPZp3 a7XCVj+oAWpWuIFdwmGpiBisfe5uzwhO4i3mrmkRRGXfNlkbcweYKDWc3/RJ+JhVGJFb 0Ud8RbgwW9Dmenv3q2rg7dBYRTZlAVfpcvrjYhJgx5urRaPsoahvvFoCn+ipdnPFEZHz 4j+g== X-Gm-Message-State: AODbwcBB4AtrHzsPXHzsPO8U0xZ5FAB+oboOe9xXACzbxjmXQrPRFDhR DDrCD/tzahaq9bPSLiedTUW3Vxqolu9X X-Received: by 10.28.216.129 with SMTP id p123mr2766269wmg.55.1494377887500; Tue, 09 May 2017 17:58:07 -0700 (PDT) MIME-Version: 1.0 References: <7E4A1357-DCC3-470E-96D2-2D6131FCCA22@me.com> In-Reply-To: <7E4A1357-DCC3-470E-96D2-2D6131FCCA22@me.com> From: Clebert Suconic Date: Wed, 10 May 2017 00:57:56 +0000 Message-ID: Subject: Re: CopyMessageBuffer To: dev@activemq.apache.org Content-Type: multipart/alternative; boundary="001a11468e1c250cc5054f20f74f" archived-at: Wed, 10 May 2017 00:58:11 -0000 --001a11468e1c250cc5054f20f74f Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable from what I remember it's where the message body gets created. The packet impl buffer should be pooked while the message not (at least not yet) I want to do another major improvement next release where I use ref counts on messages and also keep them pooked. But paging was a bit issue now. I can take a look tomorrow. I'm saying all this from memory. I will need to review the code if there is any duplication not necessary now. Using the iPhone. Clebert On Tue, May 9, 2017 at 8:04 PM Michael Andr=C3=A9 Pearce < michael.andre.pearce@me.com> wrote: > Hi > > During some testing we decided to turn on a jvm profiler to see what > allocations were occurring under load causing gc pressure. > > We see approx 25% (it varies obv over time) is an on heap byte[] caused b= y > copyMessageBuffer method in PacketImpl. > > Is there a reason why we create a new buffer and copy the data causing a > new on heap byte[] > > Cheers > Mike > > Sent from my iPhone --=20 Clebert Suconic --001a11468e1c250cc5054f20f74f--