Return-Path: X-Original-To: apmail-activemq-dev-archive@www.apache.org Delivered-To: apmail-activemq-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 8FCADEA08 for ; Mon, 25 Feb 2013 13:08:15 +0000 (UTC) Received: (qmail 83182 invoked by uid 500); 25 Feb 2013 13:08:15 -0000 Delivered-To: apmail-activemq-dev-archive@activemq.apache.org Received: (qmail 83045 invoked by uid 500); 25 Feb 2013 13:08:15 -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 82857 invoked by uid 99); 25 Feb 2013 13:08:13 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 25 Feb 2013 13:08:13 +0000 Date: Mon, 25 Feb 2013 13:08:13 +0000 (UTC) From: "st.h (JIRA)" To: dev@activemq.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (AMQ-4122) Lease Database Locker failover broken MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/AMQ-4122?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13585841#comment-13585841 ] st.h commented on AMQ-4122: --------------------------- Gary, I can confirm expected behavior when applying your changes. Thanks. However, I would suggest the following changes: - modify the documentation to show the correct configuration. currently it shows {{lockKeepAlivePeriod="10000" lockAcquireSleepInterval="5000"}}, which has been the config I used for the tests. - in case lockAcquireSleepInterval < lockKeepAlivePeriod, at least log a warning. > Lease Database Locker failover broken > ------------------------------------- > > Key: AMQ-4122 > URL: https://issues.apache.org/jira/browse/AMQ-4122 > Project: ActiveMQ > Issue Type: Bug > Affects Versions: 5.7.0 > Environment: Java 7u9, SUSE 11, Mysql > Reporter: st.h > Assignee: Gary Tully > Fix For: 5.8.0 > > Attachments: activemq-kyle.xml, activemq.xml, activemq.xml, AMQ4122.patch, mysql.log > > > We are using ActiveMQ 5.7.0 together with a mysql database and could not observe correct failover behavior with lease database locker. > It seems that there is a race condition, which prevents the correct failover procedure. > We noticed that when starting up two instances, both instance are becoming master. > We did several test, including the following and could not observe intended functionality: > - shutdown all instances > - manipulate database lock that one node has lock and set expiry time in distance future > - start up both instances. both instances are unable to acquire lock, as the lock hasn't expired, which should be correct behavior. > - update the expiry time in database, so that the lock is expired. > - first instance notices expired lock and becomes master > - when second instance checks for lock, it also updates the database and becomes master. > To my understanding the second instance should not be able to update the lock, as it is held by the first instance and should not be able to become master. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira