I am trying out a last value queue and I always seem to get just one value
when I am actually sending two values (both with different values having
the same header).
It looks like I am not using it properly. The example in the manual is for
python so its not really helping me

Here is my code for the sender in C#

            Connection connection = new Connection("localhost:5672");
            connection.Open();
            Session sess = connection.CreateSession();
            Sender sender = sess.CreateSender("prices;{create:always,
node:{type:queue,x-declare:{arguments:{'qpid.last_value_queue_key':ticker}}}}");

            Message msga = new Message();
            msga.Properties["ticker"] = "NYSE";
            msga.SetContent("50");

            Message msgb = new Message();
            msgb.Properties["ticker"] = "TTSE";
            msgb.SetContent("100");

            sender.Send(msga);
            sender.Send(msgb);

     *Now the code for my receiver is *
     Receiver receiver = sess.CreateReceiver("prices;{mode:browse}");
      while (receiver.Fetch(ref msg, timeout))
            {
                String a = msg.GetContent();
            }//end while

My question is why am i just receiving one value only even though I have
two different values attached to the same key (i.e) NYSE and TTSE ?
Am i doing something wrong here ? or will I have to create a separate LV
queue for each symbol ?

Reply via email to