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 876577548 for ; Fri, 30 Sep 2011 22:22:07 +0000 (UTC) Received: (qmail 24911 invoked by uid 500); 30 Sep 2011 22:22:07 -0000 Delivered-To: apmail-cassandra-commits-archive@cassandra.apache.org Received: (qmail 24888 invoked by uid 500); 30 Sep 2011 22:22:07 -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 24880 invoked by uid 99); 30 Sep 2011 22:22:07 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 30 Sep 2011 22:22:07 +0000 X-ASF-Spam-Status: No, hits=-2000.5 required=5.0 tests=ALL_TRUSTED,RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 30 Sep 2011 22:22:06 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id B029A2A3F9A for ; Fri, 30 Sep 2011 22:21:45 +0000 (UTC) Date: Fri, 30 Sep 2011 22:21:45 +0000 (UTC) From: "Jonathan Ellis (Commented) (JIRA)" To: commits@cassandra.apache.org Message-ID: <2146791355.13697.1317421305723.JavaMail.tomcat@hel.zones.apache.org> In-Reply-To: <477749823.13665.1317420825790.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Commented] (CASSANDRA-3288) CfDef can default to an invalid id and fail during system_add_column_family 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-3288?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13118512#comment-13118512 ] Jonathan Ellis commented on CASSANDRA-3288: ------------------------------------------- first reported on http://www.mail-archive.com/user@cassandra.apache.org/msg17649.html > CfDef can default to an invalid id and fail during system_add_column_family > --------------------------------------------------------------------------- > > Key: CASSANDRA-3288 > URL: https://issues.apache.org/jira/browse/CASSANDRA-3288 > Project: Cassandra > Issue Type: Bug > Components: API > Affects Versions: 1.0.0 > Reporter: Nate McCall > Assignee: Jonathan Ellis > Priority: Critical > Fix For: 1.0.0 > > Attachments: 3288.txt > > > The line from this commit: > https://github.com/apache/cassandra/commit/38e3e85b121ba6308ba3ceb26312d12ed0d609ec#L1R683 > Introduced an issue in that some clients, particularly Hector, will send a CfDef with an ID having been set to 0. Done via the CfDef#setId, the isSetId bit is flipped to true, causing error if schemaId of 0 already exists, which given the use case, is likely. > Since we know the context of a system_create_column_family, this can be sidestepped by just stepping on whatever ID is there (irrelevant on a create anyway) with the value returned from: Schema.instance.nextCFId() -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira