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 5905910C3A for ; Wed, 26 Nov 2014 06:11:13 +0000 (UTC) Received: (qmail 16465 invoked by uid 500); 26 Nov 2014 06:11:12 -0000 Delivered-To: apmail-cassandra-commits-archive@cassandra.apache.org Received: (qmail 16368 invoked by uid 500); 26 Nov 2014 06:11:12 -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 16084 invoked by uid 99); 26 Nov 2014 06:11:12 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 26 Nov 2014 06:11:12 +0000 Date: Wed, 26 Nov 2014 06:11:12 +0000 (UTC) From: "Jonathan Ellis (JIRA)" To: commits@cassandra.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (CASSANDRA-8368) Consider not using hints for batchlog replay, in any capacity 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-8368?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14225811#comment-14225811 ] Jonathan Ellis commented on CASSANDRA-8368: ------------------------------------------- I'm not sure that this is worth spending time on: # CL behavior is really between client and coordinator. If we're replaying the batch, then coordinator failed so it doesn't matter anymore. # Coordinator failure mid-batch is rare enough that just using hints is fine from a performance standpoint as well. > Consider not using hints for batchlog replay, in any capacity > ------------------------------------------------------------- > > Key: CASSANDRA-8368 > URL: https://issues.apache.org/jira/browse/CASSANDRA-8368 > Project: Cassandra > Issue Type: Bug > Reporter: Aleksey Yeschenko > Fix For: 3.0 > > > Currently, when replaying a batch, if a request times out, we simply write a hint for it and call it a day. > It's simple, but it does tie us to hints, which some people prefer to disable altogether (and some still will even after CASSANDRA-6230). > It also potentially violates the consistency level of the original request. > As an alternative, once CASSANDRA-7237 is complete, I suggest we stop relying on hints at all, and do this instead: > 1. Store the consistency level as batch metadata > 2. On replay, hint in case of a timeout, but not if the node is down as per FD > 3. If CL is met, consider the batch replayed and discard it, but not account the hints towards CL (as per usual write patch), unless CL.ANY is being used > 4. If CL is *not* met, write a new batch with contents of the current one, but with timeuuid set in the future, for later replay (delayed by fixed configurable time or exponentially backed off). With that new batch store the list of nodes we've delivered the hint to, so that next time we replay it we don't waste writes. -- This message was sent by Atlassian JIRA (v6.3.4#6332)