Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io 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 600AC166BC3 for ; Tue, 25 Jul 2017 18:41:08 +0200 (CEST) Received: (qmail 18714 invoked by uid 500); 25 Jul 2017 16:41:07 -0000 Mailing-List: contact users-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@activemq.apache.org Delivered-To: mailing list users@activemq.apache.org Received: (qmail 18679 invoked by uid 99); 25 Jul 2017 16:41:05 -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; Tue, 25 Jul 2017 16:41:05 +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 23511C004A for ; Tue, 25 Jul 2017 16:41:05 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 3.487 X-Spam-Level: *** X-Spam-Status: No, score=3.487 tagged_above=-999 required=6.31 tests=[DKIM_ADSP_CUSTOM_MED=0.001, NML_ADSP_CUSTOM_MED=1.2, RCVD_IN_DNSWL_NONE=-0.0001, SPF_SOFTFAIL=0.972, URI_HEX=1.313, URI_TRY_3LD=0.001] autolearn=disabled 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 Fn-KVBtmmHUr for ; Tue, 25 Jul 2017 16:41:04 +0000 (UTC) Received: from mwork.nabble.com (mwork.nabble.com [162.253.133.43]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTP id 06A055F2AA for ; Tue, 25 Jul 2017 16:41:04 +0000 (UTC) Received: from mjoe.nabble.com (unknown [162.253.133.57]) by mwork.nabble.com (Postfix) with ESMTP id 5F6B75610D8E9 for ; Tue, 25 Jul 2017 09:41:03 -0700 (MST) Date: Tue, 25 Jul 2017 09:20:42 -0700 (PDT) From: Daniel To: users@activemq.apache.org Message-ID: <1500999642208-4728882.post@n4.nabble.com> In-Reply-To: References: <1500407998854-4728648.post@n4.nabble.com> Subject: Re: Performance. Single producer and consumer is slow - 2 producers and 2 consumers is fast. MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Thanks for the responses Tim. I was getting emails to my spam so I didn't see them. After some digging it appears I know the reason for the different performance we see. ActiveMQ has a threadpool of 1 thread persisting messages received to a queue to disk. In the situation where we have multiple producers and multiple consumers ActiveMQ will deliver messages which are still queued to consumers. This means that with multiple producers and consumers we see higher performance because we skip the disk write. With 1 producer only one message is ever sent at a time and so the threadpool of 1 is never full and receives never get messages directly from the queue before they are persisted to disk. Does this assessment make sense to you? -- View this message in context: http://activemq.2283324.n4.nabble.com/Performance-Single-producer-and-consumer-is-slow-2-producers-and-2-consumers-is-fast-tp4728648p4728882.html Sent from the ActiveMQ - User mailing list archive at Nabble.com.