You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Aaron Morton (JIRA)" <ji...@apache.org> on 2011/02/16 12:40:57 UTC
[jira] Commented: (CASSANDRA-2008) CLI help incorrect in places
[ https://issues.apache.org/jira/browse/CASSANDRA-2008?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12995259#comment-12995259 ]
Aaron Morton commented on CASSANDRA-2008:
-----------------------------------------
I'm working on changing the cli help to be driven from a yaml file (in the jar) to make it easier to be updated. I've ported over the existing help and am in the process of re-writing the help to match cassandra.yaml and the wiki.
Below is a (first draft) example, if anyone has feedback on the style let me know. I'm trying to keep the text < 80 chars wide. I can also add simple pagination through the ConsoleReader we use if people think it would be handy.
{noformat}
[default@unknown] help create keyspace;
create keyspace <keyspace>;
create keyspace <keyspace> with <att1>=<value1>;
create keyspace <keyspace> with <att1>=<value1> and <att2>=<value2> ...;
Create a new keyspace with the specified values for the given set of
attributes.
Parameters:
- keyspace: Requried name of the new keyspace, "system" is reserved for
Cassandra internals. Names must only contain letters, numbers and
underscores.
Attributes:
- replication_factor: Required number of replicas of each row. Applies
to SimpleStrategy and OldNetworkTopologyStrategy placement strategys,
the NetworkTopologyStrrategy uses additonal configuration.
- placement_strategy: Required class that determines how replicas
are distributed among nodes. Contains both the class as well as
configuration information. Must extend AbstractReplicationStrategy.
Out of the box, Cassandra provides
- org.apache.cassandra.locator.SimpleStrategy
- org.apache.cassandra.locator.NetworkTopologyStrategy
- org.apache.cassandra.locator.OldNetworkTopologyStrategy
SimpleStrategy merely places the first replica at the node whose
token is closest to the key (as determined by the Partitioner), and
additional replicas on subsequent nodes along the ring in increasing
Token order.
With NetworkTopologyStrategy, for each datacenter, you can specify
how many replicas you want on a per-keyspace basis. Replicas are
placed on different racks within each DC, if possible.
OldNetworkToplogyStrategy [formerly RackAwareStrategy]
places one replica in each of two datacenters, and the third on a
different rack in in the first. Additional datacenters are not
guaranteed to get a replica. Additional replicas after three are
placed in ring order after the third without regard to rack or
datacenter.
- strategy_options: Optional additional options for placement_strategy.
Applies only to NetworkTopologyStrategy.
Examples:
create keyspace foo with
placement_strategy = 'org.apache.cassandra.locator.SimpleStrategy'
and replication_factor = 3;
create keyspace foo with
placement_strategy = 'org.apache.cassandra.locator.NetworkTopologyStrategy'
and strategy_options=[{DC1:2, DC2:2}];
{noformat}
> CLI help incorrect in places
> ----------------------------
>
> Key: CASSANDRA-2008
> URL: https://issues.apache.org/jira/browse/CASSANDRA-2008
> Project: Cassandra
> Issue Type: Improvement
> Components: Core
> Affects Versions: 0.7.0
> Reporter: Aaron Morton
> Assignee: Aaron Morton
> Priority: Trivial
> Fix For: 0.7.2
>
>
> Found some errors in the CLI help, such as these for create column family.
> - memtable_operations: Flush memtables after this many operations
> - memtable_throughput: ... or after this many bytes have been written
> - memtable_flush_after: ... or after this many seconds
> Should be millions of ops, MB's written and minutes not seconds. Have confirmed thats how the values are used. Will check all the help.
--
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira