<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
<title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
Hi Sylvain -<br>
<br>
Thanks for your response.<br>
<br>
In my case, I am publishing the messages with the mandatory flag set to
true and I am registering a ReturnListener with the channel. However, I
do not see any messages being returned. For what it's worth, I do see
messages returned if I set the immediate flag to true and do not have a
consumer running, but that's a different scenario.<br>
<br>
Jesse<br>
<br>
On 5/29/10 1:12 AM, Sylvain Hellegouarch wrote:
<blockquote
cite="mid:AANLkTinUQLFClPoFHa_xquHIRPEC0vsaqD8lUauLLdRB@mail.gmail.com"
type="cite">Hi Jesse,<br>
<br>
<br>
<div class="gmail_quote">
<blockquote class="gmail_quote"
style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">I
understand that publishing a message is asynchronous, but surely there<br>
must be a way to discover that message was not successfully published.
What<br>
am I missing?<br>
<br>
<br>
</blockquote>
</div>
<br>
<div class="gmail_quote">
<div><br>
The protocol (I assume 0-8 here) suggests that you set the "mandatory"
flag to 1 for each message. If a message cannot be routed from an
exchange to at least one queue, it'll be returned to the publisher with
a "312 unroutable" error code. You must define a handler for those
errors on the publisher side [1] and decide what to do with the
returned message. Personally I just keep trying publishing it with
after a small period of time. This means my publisher becomes
responsible for not losing messages in that specific use case.<br>
<br>
</div>
</div>
-- <br>
- Sylvain<br>
<a moz-do-not-send="true" href="http://www.defuze.org/"
target="_blank">http://www.defuze.org</a><br>
<br>
[1] <a moz-do-not-send="true"
href="http://www.rabbitmq.com/api-guide.html#returning" target="_blank">http://www.rabbitmq.com/api-guide.html#returning</a><br
clear="all">
<br>
</blockquote>
</body>
</html>