<div dir="ltr">Yes, I got it. the basicConsume() method returns the consumer tag corresponding to the queue. So I can call the basicCancel(consumertag) to unsubscribe from that queue alone.<div>
<p class="p1">String consumerTag1 = <span class="s1"><i>channel</i></span>.basicConsume(<span class="s2">"queue1"</span>, consumer);</p><p class="p1">String consumerTag2= <span class="s1"><i>channel</i></span>.basicConsume(<span class="s2">"queue3"</span>, consumer);</p><p class="p1">
</p><p class="p1"><span class="s1"><i>channel</i></span>.basicCancel(consumerTag2);</p>Thank you.</div><div>Subshiri</div><div><br>On Monday, April 28, 2014 1:35:36 PM UTC+5:30, Alvaro Videla wrote:<blockquote class="gmail_quote" style="margin: 0;margin-left: 0.8ex;border-left: 1px #ccc solid;padding-left: 1ex;">Hi,
<br>
<br>Yes, you can use basicCancel for a specific consumer. See here:
<br><a href="https://www.rabbitmq.com/amqp-0-9-1-quickref.html" target="_blank" onmousedown="this.href='https://www.google.com/url?q\75https%3A%2F%2Fwww.rabbitmq.com%2Famqp-0-9-1-quickref.html\46sa\75D\46sntz\0751\46usg\75AFQjCNE4swnoGI5mPi8Nqm-TnCvEjMwAAg';return true;" onclick="this.href='https://www.google.com/url?q\75https%3A%2F%2Fwww.rabbitmq.com%2Famqp-0-9-1-quickref.html\46sa\75D\46sntz\0751\46usg\75AFQjCNE4swnoGI5mPi8Nqm-TnCvEjMwAAg';return true;">https://www.rabbitmq.com/amqp-<wbr>0-9-1-quickref.html</a>
<br>
<br>Regards,
<br>
<br>Alvaro
<br>
<br>On Mon, Apr 28, 2014 at 9:30 AM, Subshiri S <<a href="javascript:" target="_blank" gdf-obfuscated-mailto="tTBf1ri3tX0J" onmousedown="this.href='javascript:';return true;" onclick="this.href='javascript:';return true;">subs...@gmail.com</a>> wrote:
<br>>
<br>>>
<br>>> QueueingConsumer consumer = new QueueingConsumer(channel);
<br>>> channel.basicConsume("queue1", consumer);
<br>>> channel.basicConsume("queue3", consumer);
<br>>
<br>>
<br>> Is it possible to stop consuming the messages from the queue "queue3" alone
<br>> dynamically?
<br>>
<br>> ______________________________<wbr>_________________
<br>> rabbitmq-discuss mailing list
<br>> <a href="javascript:" target="_blank" gdf-obfuscated-mailto="tTBf1ri3tX0J" onmousedown="this.href='javascript:';return true;" onclick="this.href='javascript:';return true;">rabbitmq...@lists.<wbr>rabbitmq.com</a>
<br>> <a href="https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss" target="_blank" onmousedown="this.href='https://www.google.com/url?q\75https%3A%2F%2Flists.rabbitmq.com%2Fcgi-bin%2Fmailman%2Flistinfo%2Frabbitmq-discuss\46sa\75D\46sntz\0751\46usg\75AFQjCNEa7MyKsA1XPSVZIhQM5kBuKmKiKg';return true;" onclick="this.href='https://www.google.com/url?q\75https%3A%2F%2Flists.rabbitmq.com%2Fcgi-bin%2Fmailman%2Flistinfo%2Frabbitmq-discuss\46sa\75D\46sntz\0751\46usg\75AFQjCNEa7MyKsA1XPSVZIhQM5kBuKmKiKg';return true;">https://lists.rabbitmq.com/<wbr>cgi-bin/mailman/listinfo/<wbr>rabbitmq-discuss</a>
<br>>
<br></blockquote></div></div>