qpid-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Davide Anastasia" <Davide.Anasta...@qualitycapital.com>
Subject RE: Update message content
Date Mon, 05 Mar 2012 10:00:29 GMT
Hi Gordon,
Thanks for your reply.

I did not explicitly created the queue using qpid-config, but I am using
this configuration string on the sender side (is it the same?):


then I am putting into every subject the name of the instrument, doing

qpid_message.setSubject( instr_name );  // set subject

where instr_name is an std::string holding the name of the instrument.

On the receiver side however I would like to receive updates only on a
certain subject (namely, a certain instrument).
I have tried different solution, but none works: I always get the ALL
set of instruments.

Currently I am using this address string on the receiver side:

ticker/instrument_name;{create:sender, mode:browse, node:{type:queue}}

What am I doing wrong?

Thanks a lot,

-----Original Message-----
From: Gordon Sim [mailto:gsim@redhat.com] 
Sent: 02 March 2012 18:09
To: users@qpid.apache.org
Subject: Re: Update message content

On 03/02/2012 05:57 PM, Gordon Sim wrote:
> On 03/02/2012 03:14 PM, Davide Anastasia wrote:
>> Hi Jakub,
>> Thanks a lot for your help: it really helped me a lot. However, I 
>> couldn't find a way to filter messages using their subject. For 
>> instance, I created my queue with the name "ticker" and then I sent 
>> messages using routing_key like "instr1", "instr2", and so on.
>> Unfortunately, on the receiver side I still receive all the messages.
> http://qpid.apache.org/books/trunk/AMQP-Messaging-Broker-CPP-Book/html
> /ch01s06.html is the correct link to use for anything since the Qpid 
> 0.10 release. The older content is now out of date and describes 
> deprecated behaviour.

And more specifically, did you configure your queue as an LVQ? You can't
(at present) key on the routing key itself, but if you are using the
qpid::messaging API (whether in c++ or python) then you can use
'qpid.subject' as a substitute.


qpid-config add queue ticker --argument

then e.g.

spout --content a1 ticker/instr1
spout --content a2 ticker/instr2
spout --content b1 ticker/instr1

etc, and the queue will hold the last values of each instrument. You can
set up browsers on the queue that will get the latest set and then any
further updates. E.g.

drain 'ticker; {mode: browse}'

Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:users-subscribe@qpid.apache.org

To unsubscribe, e-mail: users-unsubscribe@qpid.apache.org
For additional commands, e-mail: users-help@qpid.apache.org

View raw message