<html dir="ltr">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<style type="text/css" id="owaParaStyle"></style>
</head>
<body fpstyle="1" ocsi="0">
<div style="direction: ltr;font-family: Tahoma;color: #000000;font-size: 10pt;">Hi all:
<div> I have met the problem too. I know how to change my client code to fix it. </div>
<div> And I have a question, problem or skill like this can only be found in the mail-list, but there is no document describe them full-scale. In my opinion, this is a big difficulty for all the developers on Rabbit-MQ.</div>
<div><br>
</div>
<div>Regards,</div>
<div>David<br>
<div style="font-family: Times New Roman; color: #000000; font-size: 16px">
<hr tabindex="-1">
<div id="divRpF343083" style="direction: ltr; "><font face="Tahoma" size="2" color="#000000"><b>发件人:</b> rabbitmq-discuss-bounces@lists.rabbitmq.com [rabbitmq-discuss-bounces@lists.rabbitmq.com] 代表 Simone Busoli [simone.busoli@gmail.com]<br>
<b>发送时间:</b> 2012年2月22日 5:18<br>
<b>到:</b> Steve Powell<br>
<b>Cc:</b> rabbitmq-discuss@lists.rabbitmq.com<br>
<b>主题:</b> Re: [rabbitmq-discuss] Passive queue declaration and channel closure<br>
</font><br>
</div>
<div></div>
<div>
<p>Thanks Steve, that's pretty much what Simon had already clarified, and I agreed that changing this behavior is not practical.</p>
<div class="gmail_quote">On Feb 21, 2012 2:24 PM, "Steve Powell" <<a href="mailto:steve@rabbitmq.com" target="_blank">steve@rabbitmq.com</a>> wrote:<br type="attribution">
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex; border-left:1px #ccc solid; padding-left:1ex">
Simone,<br>
<br>
Replies in-line below..<br>
<br>
I don't think this is likely to change in the near future, since it<br>
would be disruptive to most clients that use this.<br>
<br>
Steve Powell (a happy bunny)<br>
----------some more definitions from the SPD----------<br>
vermin (v.) Treating the dachshund for roundworm.<br>
chinchilla (n.) Cooling device for the lower jaw.<br>
socialcast (n.) Someone to whom everyone is speaking but nobody likes.<br>
<br>
On 16 Feb 2012, at 17:10, Busoli, Simone wrote:<br>
<br>
> Without relying on the management plugin I think the only way to do that is to<br>
> declare the queue as passive. At least with the .NET client and apparently the<br>
> Java client too, when the queue does not exist, besides throwing an exception,<br>
> the channel is closed as well. From the spec:<br>
><br>
> If set, the server will reply with Declare-Ok if the queue already exists with<br>
> the same name, and raise an error if not. The client can use this to check<br>
> whether a queue exists without modifying the server state.<br>
<br>
The spec goes on to say:<br>
<br>
The client MAY ask the server to assert that a queue exists without creating<br>
the queue if not. If the queue does not exist, the server treats this as a<br>
failure. Error code: not-found<br>
<br>
> There is no mention of channel closure, while the last sentence implies that<br>
> using the passive bit is indeed a way for a client to check queue existence, so<br>
> closing the channel when it doesn’t is a bit unexpected. That said, it’s not a<br>
> big deal to recreate the channel in such cases, but I’d appreciate your opinion.<br>
> Any chance this behavior can be changed in the client libraries?<br>
<br>
This is the mention of channel-closure -- an 'error' raised on the channel will<br>
close it.<br>
<br>
_______________________________________________<br>
rabbitmq-discuss mailing list<br>
<a href="mailto:rabbitmq-discuss@lists.rabbitmq.com" target="_blank">rabbitmq-discuss@lists.rabbitmq.com</a><br>
<a href="https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss" target="_blank">https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss</a><br>
</blockquote>
</div>
</div>
</div>
</div>
</div>
</body>
</html>