Return-Path: X-Original-To: apmail-cassandra-commits-archive@www.apache.org Delivered-To: apmail-cassandra-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 68166108C4 for ; Sat, 17 Jan 2015 01:10:33 +0000 (UTC) Received: (qmail 24073 invoked by uid 500); 17 Jan 2015 01:10:35 -0000 Delivered-To: apmail-cassandra-commits-archive@cassandra.apache.org Received: (qmail 23966 invoked by uid 500); 17 Jan 2015 01:10:35 -0000 Mailing-List: contact commits-help@cassandra.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cassandra.apache.org Delivered-To: mailing list commits@cassandra.apache.org Received: (qmail 23740 invoked by uid 99); 17 Jan 2015 01:10:35 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 17 Jan 2015 01:10:35 +0000 Date: Sat, 17 Jan 2015 01:10:34 +0000 (UTC) From: "Aleksey Yeschenko (JIRA)" To: commits@cassandra.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (CASSANDRA-8640) Paxos requires all nodes for CAS 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/CASSANDRA-8640?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14281091#comment-14281091 ] Aleksey Yeschenko commented on CASSANDRA-8640: ---------------------------------------------- Already ninja-fixed in a follow-up commit. > Paxos requires all nodes for CAS > -------------------------------- > > Key: CASSANDRA-8640 > URL: https://issues.apache.org/jira/browse/CASSANDRA-8640 > Project: Cassandra > Issue Type: Bug > Components: Core > Reporter: Anthony Cozzie > Assignee: Anthony Cozzie > Fix For: 2.0.12, 2.1.3 > > Attachments: 0001-Fix-parentheses-bug-in-Paxos.patch, 0001-Fix-quorum-required-nodes-calculation-for-Paxos.patch > > > In C* 2.1, > {code} > int requiredParticipants = participants + 1 / 2; // See CASSANDRA-833 > {code} > Will always return participants because of operator precedence. I am not sure just adding parentheses will fix the problem, though, as the original code differentiated between pending and natural endpoints. > {code} > int requiredParticipants = pendingEndpoints.size() + 1 + naturalEndpoints.size() / 2; // See CASSANDRA-833 > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)