Return-Path: Delivered-To: apmail-activemq-users-archive@www.apache.org Received: (qmail 455 invoked from network); 19 Feb 2008 12:06:34 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 19 Feb 2008 12:06:34 -0000 Received: (qmail 74481 invoked by uid 500); 19 Feb 2008 12:06:28 -0000 Delivered-To: apmail-activemq-users-archive@activemq.apache.org Received: (qmail 74451 invoked by uid 500); 19 Feb 2008 12:06:28 -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 74442 invoked by uid 99); 19 Feb 2008 12:06:27 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 19 Feb 2008 04:06:27 -0800 X-ASF-Spam-Status: No, hits=4.0 required=10.0 tests=DNS_FROM_OPENWHOIS,FORGED_YAHOO_RCVD,SPF_HELO_PASS,SPF_PASS,WHOIS_MYPRIVREG X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of lists@nabble.com designates 216.139.236.158 as permitted sender) Received: from [216.139.236.158] (HELO kuber.nabble.com) (216.139.236.158) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 19 Feb 2008 12:05:41 +0000 Received: from isper.nabble.com ([192.168.236.156]) by kuber.nabble.com with esmtp (Exim 4.63) (envelope-from ) id 1JRREX-00042v-IC for users@activemq.apache.org; Tue, 19 Feb 2008 04:06:01 -0800 Message-ID: <15560569.post@talk.nabble.com> Date: Tue, 19 Feb 2008 04:06:01 -0800 (PST) From: LukeH To: users@activemq.apache.org Subject: Sending a message from a BrokerFilter. MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Nabble-From: lukeh_ro@yahoo.com X-Virus-Checked: Checked by ClamAV on apache.org I created a BrokerFilter implementation that gathers some data when messages are passed around. Now that data I want to send to each new consummer added if the destination matches some criteria. So after calling super.addConsumer() i want to build a ActiveMQBytesMessage and send it to that consummer. First of all is this a good aproach? Other sugestions? I have an hard time trying to set the parameters to that message (connectionId, producerId, messageId). How shoud i set them based on the context and info from the method signature? And what shoud I use message.writeBytes or message.setContent? I had a working version with setContent but it started to fail when I tryed to use vm connector. -- View this message in context: http://www.nabble.com/Sending-a-message-from-a-BrokerFilter.-tp15560569s2354p15560569.html Sent from the ActiveMQ - User mailing list archive at Nabble.com.