<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Tahoma
}
--></style></head>
<body class='hmmessage'><div dir='ltr'>
Matthias,<br> Setting the "ttl" on the publisher queue does work fine when the consumer also declares the queue with 'ttl' (using Java client tested)<br><br><div align="left">Is it necessary for declaring the consumer queue to hold the configuration of ttl? My requirement is to drop the published messages which are older than X secs. Is there are way to achieve this using a Java publisher and C++ consumer? Appreciate your response.<br></div><br>Thnx,<br>Maurya<br><br><div><div id="SkyDrivePlaceholder"></div>> Date: Thu, 5 Jul 2012 09:34:45 +0100<br>> From: matthias@rabbitmq.com<br>> To: rabbitmq-discuss@lists.rabbitmq.com<br>> Subject: Re: [rabbitmq-discuss] Auto delete messages in Queue after queue size reaches a certain number<br>> <br>> On 05/07/12 09:06, alvinRMQ wrote:<br>> > Is there a way for the rabbitMQ broker to automatically throw away messages<br>> > in a Queue if the number of messages is above a certain number?<br>> <br>> The closest RabbitMQ has to that is per-queue message ttl. See <br>> http://www.rabbitmq.com/extensions.html#queue-ttl. That is based on time <br>> rather than a count, which is arguably more useful - i.e. one can <br>> imagine that an app may not care about messages older than n seconds, <br>> whereas it is hard to conceive of an app that doesn't care about <br>> messages thrown away from the front (or back?) of the queue based on a <br>> count.<br>> <br>> > It is possible that a consumer may not be able to keep up with the<br>> > publisher, and cause the Rabbit Broker to slowly run out of disk space.<br>> <br>> ...at which point rabbit will block the producers until the consumers <br>> have drained enough messages to clear the disk alarm.<br>> <br>> Regards,<br>> <br>> Matthias.<br>> _______________________________________________<br>> rabbitmq-discuss mailing list<br>> rabbitmq-discuss@lists.rabbitmq.com<br>> https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss<br></div>                                            </div></body>
</html>