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 628E917CD7 for ; Thu, 5 Mar 2015 16:51:39 +0000 (UTC) Received: (qmail 49931 invoked by uid 500); 5 Mar 2015 16:51:39 -0000 Delivered-To: apmail-cassandra-commits-archive@cassandra.apache.org Received: (qmail 49897 invoked by uid 500); 5 Mar 2015 16:51:39 -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 49886 invoked by uid 99); 5 Mar 2015 16:51:39 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 05 Mar 2015 16:51:39 +0000 Date: Thu, 5 Mar 2015 16:51:39 +0000 (UTC) From: "Sam Tunnicliffe (JIRA)" To: commits@cassandra.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (CASSANDRA-8850) clean up options syntax for create/alter role 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-8850?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14349067#comment-14349067 ] Sam Tunnicliffe commented on CASSANDRA-8850: -------------------------------------------- Right, and this is the approach that I've taken. Where it's messy is when we have a statement like {{GRANT ON TO }} If {{}} is a Role, then we should enforce that {{ROLE}} is a literal. But if {{}} is a data resource, we'll need to accept {{}} as either an identifier or a literal so we don't break compatibility (as previously, it would have represented a user). For now, I'm doing this by duplication in the grammar itself. This complexity will increase as we add further resource types (CASSANDRA-7557), but not significantly. It isn't really a big deal, it just makes the grammar & tests slightly more complicated though probably not enough to be a problem. If we're prepared to actually deprecate and remove the user concept in some future version, all the better. Is there precedent for removing syntax from CQL3? > clean up options syntax for create/alter role > ---------------------------------------------- > > Key: CASSANDRA-8850 > URL: https://issues.apache.org/jira/browse/CASSANDRA-8850 > Project: Cassandra > Issue Type: Improvement > Reporter: Sam Tunnicliffe > Assignee: Sam Tunnicliffe > Priority: Minor > Fix For: 3.0 > > Attachments: 8850-v2.txt, 8850.txt > > > {{CREATE/ALTER ROLE}} syntax would be improved by using {{WITH}} and {{AND}} in a way more consistent with other statements. > e.g. {{CREATE ROLE foo WITH LOGIN AND SUPERUSER AND PASSWORD 'password'}} -- This message was sent by Atlassian JIRA (v6.3.4#6332)