Return-Path: X-Original-To: apmail-qpid-users-archive@www.apache.org Delivered-To: apmail-qpid-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id E40E59221 for ; Sun, 1 Apr 2012 19:25:50 +0000 (UTC) Received: (qmail 43764 invoked by uid 500); 1 Apr 2012 19:25:50 -0000 Delivered-To: apmail-qpid-users-archive@qpid.apache.org Received: (qmail 43729 invoked by uid 500); 1 Apr 2012 19:25:50 -0000 Mailing-List: contact users-help@qpid.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@qpid.apache.org Delivered-To: mailing list users@qpid.apache.org Received: (qmail 43721 invoked by uid 99); 1 Apr 2012 19:25:50 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 01 Apr 2012 19:25:50 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of quezada.gaston@gmail.com designates 209.85.212.42 as permitted sender) Received: from [209.85.212.42] (HELO mail-vb0-f42.google.com) (209.85.212.42) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 01 Apr 2012 19:25:44 +0000 Received: by vbjk13 with SMTP id k13so1379473vbj.15 for ; Sun, 01 Apr 2012 12:25:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type; bh=TE3lhYUOZ5rcXVrVowfKiydk7oEzlG71RXgv4TDl+Oc=; b=ZItb5GnPQHzksCyCeFedAYRV2UUDbPWwwzp2u6BXpeAt6bVik6DHSBssBONmay3sVh s2RnQ92SYBO/1e8iZiYyh9GPk84jCPWpERSv/k8tABGz1x8wz371F0yMtbjoMvTX6jpI kAhE+exLxS/0Dt35vH40KS1dBdyuYsEBbx6DKO8/F3JVu1tq75uze/tpcxfntbQfEz3F vzOurHxMT/zNFLO8S+lVho1c2obqqbyYqOrS1aABRKaOvRV03olJxzsekb2K5WZBHC3d aseASkt64EelKvZ+oI0rGHhRmnCQ5gTwXG5YOYcxaNRN93NPYMSZXmjsuNZSh9lOhB6m Fwag== Received: by 10.220.154.203 with SMTP id p11mr2728428vcw.56.1333308323228; Sun, 01 Apr 2012 12:25:23 -0700 (PDT) MIME-Version: 1.0 Received: by 10.52.34.11 with HTTP; Sun, 1 Apr 2012 12:25:03 -0700 (PDT) In-Reply-To: References: From: Gaston Quezada Date: Sun, 1 Apr 2012 16:25:03 -0300 Message-ID: Subject: Re: Auto deleting a queue after timeout with Java qpid broker To: users@qpid.apache.org Content-Type: multipart/alternative; boundary=f46d043c80acfb6e2704bca308be --f46d043c80acfb6e2704bca308be Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Dear Eugene, I use it as folows in Java: String address =3D queueName + "; {create: always, node:{durable:" + new Boolean(SWProperties.getString("queue.durable", System.getProperty(type + "sw.properties"))).booleanValue() + ", exclusive:" + new Boolean(SWProperties.getString("queue.exclusive", System.getProperty(type + "sw.properties"))).booleanValue() + ", x-declare:{queue:'" + queueName + "',auto-delete:" + new Boolean(SWProperties.getString("queue.auto.delete", System.getProperty(type + "sw.properties"))). booleanValue() + ", arguments:{'qpid.auto_delete_timeout':" + SWProperties.getInt("queue.expired.time", System.getProperty(type + "sw.properties")) + "}}," + " x-bindings:[{exchange:'" + exchangeName + "', key:'" + routingkeyName + "'}]}}"; AMQDestination queue =3D new AMQAnyDestination(address); WHERE: queue.durable=3D true or false queue.exclusive=3D true or false queue.auto.delete=3D true or false queue.expired.time=3D time in seconds format (example: 30) Gast=F3n 2012/4/1 Eugene Prystupa > Is it possible to configure the queue to be deleted if no consumers are > bound to it for a configured period of time? Similar to how "x-expire" > option works in RabbitMQ (http://www.rabbitmq.com/extensions.html). I'm > looking to do this with Java qpid broker. > > -- > Thanks, > Eugene > --=20 Gast=F3n Quezada http://dooid.me/quezadagaston --f46d043c80acfb6e2704bca308be--