You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@cassandra.apache.org by Saurabh Sethi <Sa...@symantec.com> on 2015/05/01 20:15:11 UTC

Keyspace name length

Apache’s Cassandra code validates the keyspace name length for max 48 characters whereas Datastax’s documentation says keyspace name should be 32 or fewer characters.

Which of these is correct?

Thanks,
Saurabh

Re: Keyspace name length

Posted by Robert Coli <rc...@eventbrite.com>.
(docs AT datastax.com added to the bcc: for their information.)

On Fri, May 1, 2015 at 11:15 AM, Saurabh Sethi <Sa...@symantec.com>
wrote:

> Apache’s Cassandra code validates the keyspace name length for max 48
> characters whereas Datastax’s documentation says keyspace name should be 32
> or fewer characters.
>
> Which of these is correct?
>

Apache Cassandra is open-source, questions like this can trivially be
answered by reading the source code.

src/java/org/apache/cassandra/config/KSMetaData.java:            throw new
ConfigurationException(String.format("Keyspace name must not be empty, more
than %s characters long, or contain non-alphanumeric-underscore characters
(got \"%s\")", Schema.NAME_LENGTH, name));

src/java/org/apache/cassandra/config/Schema.java:    public static final
int NAME_LENGTH = 48;

=Rob