Return-Path: X-Original-To: apmail-activemq-users-archive@www.apache.org Delivered-To: apmail-activemq-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 7E73D7BC3 for ; Thu, 14 Jul 2011 12:21:01 +0000 (UTC) Received: (qmail 59311 invoked by uid 500); 14 Jul 2011 12:21:01 -0000 Delivered-To: apmail-activemq-users-archive@activemq.apache.org Received: (qmail 59170 invoked by uid 500); 14 Jul 2011 12:21:00 -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 59162 invoked by uid 99); 14 Jul 2011 12:20:59 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 14 Jul 2011 12:20:59 +0000 X-ASF-Spam-Status: No, hits=0.6 required=5.0 tests=FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS,T_TO_NO_BRKTS_FREEMAIL,URI_HEX X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of jasonwhaley@gmail.com designates 209.85.210.171 as permitted sender) Received: from [209.85.210.171] (HELO mail-iy0-f171.google.com) (209.85.210.171) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 14 Jul 2011 12:20:53 +0000 Received: by iyi12 with SMTP id 12so182572iyi.2 for ; Thu, 14 Jul 2011 05:20:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=content-type:mime-version:subject:from:in-reply-to:date :content-transfer-encoding:message-id:references:to:x-mailer; bh=iISFIyDcWY4WHxz8TNle7jYhrfqCH5BRIi0CoTMeulA=; b=wS1rVu/P206IIBgEh9Woo+Jt9ZTUAUtbYXGs+7v/K1YsQ6K1jnI5fh/cxYlKfaxCUj gnHSwMhr1Mld8EffgXrFzl0He6TC02dy9GRvT0ce1Klk33Bhv0qL3aXGP0e18mB9rOS5 atkBA4pNX+cbxnSb7td2MD8ymhRdlO03Kjspg= Received: by 10.42.28.3 with SMTP id l3mr2712569icc.14.1310646032949; Thu, 14 Jul 2011 05:20:32 -0700 (PDT) Received: from [192.168.1.7] (c-24-8-30-23.hsd1.co.comcast.net [24.8.30.23]) by mx.google.com with ESMTPS id y3sm138304ibc.54.2011.07.14.05.20.30 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 14 Jul 2011 05:20:31 -0700 (PDT) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Apple Message framework v1084) Subject: Re: Slow and fast messages From: Jason Whaley In-Reply-To: <1310424910948-3661071.post@n4.nabble.com> Date: Thu, 14 Jul 2011 06:20:29 -0600 Content-Transfer-Encoding: quoted-printable Message-Id: <11BB63E1-8816-4856-B727-90B2741F5691@gmail.com> References: <1310406621311-3660295.post@n4.nabble.com> <1310424910948-3661071.post@n4.nabble.com> To: users@activemq.apache.org X-Mailer: Apple Mail (2.1084) Two questions/suggestions regarding your AMQ setup: 1) What is the average size (or range of sizes) of the actual message = being sent from your producer? If you are dealing with larger messages = you may wish to consider sending Blob Messages instead of putting the = entire payload inside of the message itself - see = http://activemq.apache.org/blob-messages.html for more detail. = Determining what a "large" message is may vary, but once you start = approaching 1MB you should definitely consider Blob Messages. 2) What is the network latency between your producer and your broker? = If it is substantial enough to affect the speed at which you can produce = a message and receive acknowledgement from the broker, you could use a = Network of Brokers between your producer and consumer such that one AMQ = instance lives on the same host or at least on the same subnet as your = producer and that instance is responsible for forwarding messages to = another AMQ instance that your consumer consumes from. See = http://activemq.apache.org/networks-of-brokers.html for more. On Jul 11, 2011, at 4:55 PM, MaryAuaun wrote: > Boy, this forum is great for making me get my thoughts together and = answering > my own questions, but if anyone knows any more, please chime in! >=20 > For writing 1000 messages >=20 > Originally 1000 messages took 40 seconds. >=20 > Persistent vs. Non-Persistent didn't make much difference in speed >=20 > These settings made a little differenceoptions: > connectionFactory.setUseAsyncSend(true); // tbw to test > speed > connectionFactory.setAlwaysSyncSend(false); > connectionFactory.setSendAcksAsync(true); > connectionFactory.setProducerWindowSize(100); > (some of these settings are poorly document or not documented at = all!) > Now 1000 messages takes 27 seconds!=20 >=20 > I removed the "transacted" and commits, that made it much faster > 1000 messages take about 6 seconds, even with Persistent on. >=20 > That's nos 166 messages / sec, which is not bad. If there are other > improvements I can make, please let me know! >=20 >=20 > -- > View this message in context: = http://activemq.2283324.n4.nabble.com/Slow-and-fast-messages-tp3660295p366= 1071.html > Sent from the ActiveMQ - User mailing list archive at Nabble.com.