Return-Path: Delivered-To: apmail-activemq-dev-archive@www.apache.org Received: (qmail 36707 invoked from network); 6 Apr 2009 21:31:58 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 6 Apr 2009 21:31:58 -0000 Received: (qmail 36523 invoked by uid 500); 6 Apr 2009 21:31:58 -0000 Delivered-To: apmail-activemq-dev-archive@activemq.apache.org Received: (qmail 36460 invoked by uid 500); 6 Apr 2009 21:31:58 -0000 Mailing-List: contact dev-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@activemq.apache.org Delivered-To: mailing list dev@activemq.apache.org Received: (qmail 36450 invoked by uid 99); 6 Apr 2009 21:31:58 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 06 Apr 2009 21:31:58 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 06 Apr 2009 21:31:56 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id C5D80234C046 for ; Mon, 6 Apr 2009 14:31:34 -0700 (PDT) Message-ID: <1853780966.1239053494808.JavaMail.jira@brutus> Date: Mon, 6 Apr 2009 14:31:34 -0700 (PDT) From: "Santiago Urrizola (JIRA)" To: dev@activemq.apache.org Subject: [jira] Commented: (AMQ-1072) "TimeToLive" doesn't work on MessageListener MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: ae95407df07c98740808b2ef9da0087c X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/activemq/browse/AMQ-1072?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=51062#action_51062 ] Santiago Urrizola commented on AMQ-1072: ---------------------------------------- Context: 3 host, (linux debian) all with DEFERENTS dates (not synchronized) 1- start a broker on machine 1 2- start a producer on machine 2 3- producer send a couple of messages with a short timeToLive (2 or 3 seconds) 4- wait for 5 seconds (or more) 5- start a messageListener on machine 3 6- surprisingly messageListener recveibe all the messages sent by producer in step 3, when they should not (because of the timeToLive) The problem is the host where the listener (consumer) runs have a date two or three hours prior of the host for the consumer, and beacause off that the Expiration is always greater than the Listener (consumer) date. I think expiration should be managed entirelly in the broker not in clientes (ActiveMQQueueReceiver, etc) > "TimeToLive" doesn't work on MessageListener > -------------------------------------------- > > Key: AMQ-1072 > URL: https://issues.apache.org/activemq/browse/AMQ-1072 > Project: ActiveMQ > Issue Type: Bug > Components: JMS client > Affects Versions: 4.0.1 > Reporter: Joseph Leung > Assignee: Rob Davies > Fix For: 5.0.0 > > > When a queue message is consumed using MessageListener throught the setMessageListener method, > it could recieve the messages even if they are expired. (While using consumer.receive() will discard them). > Reproduce Steps: > 1. deliver a number of message to a queue with a short expire time. > 2. wait until the message should be expired. > 3. use MessageConsumer.receive() method to receive the messages, > -- You should not receive any messages, and through the monitor console, you should see some > messages are left and not discarded. > 4. stop the receive() method. > 5. add a MessageListener to the same queue, the messages which found left is received by the > onMessage() method. > ps. if step3 is skipped, likely you would receive all the expired message. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.