mirror of https://github.com/apache/cassandra
Merge branch 'cassandra-1.1' into trunk
This commit is contained in:
commit
2edeeeba2d
|
|
@ -1770,7 +1770,7 @@ class Shell(cmd.Cmd):
|
|||
return names
|
||||
|
||||
def columnize(self, slist, *a, **kw):
|
||||
return cmd.Cmd.columnize(self, [u.upper() for u in slist], *a, **kw)
|
||||
return cmd.Cmd.columnize(self, sorted([u.upper() for u in slist]), *a, **kw)
|
||||
|
||||
def do_help(self, parsed):
|
||||
"""
|
||||
|
|
|
|||
|
|
@ -498,7 +498,10 @@ def create_ks_opt_completer(ctxt, cass):
|
|||
return ['strategy_class =']
|
||||
vals = ctxt.get_binding('optval')
|
||||
stratclass = dequote_value(vals[stratopt])
|
||||
if stratclass in ('SimpleStrategy', 'OldNetworkTopologyStrategy'):
|
||||
if stratclass in ('SimpleStrategy',
|
||||
'org.apache.cassandra.locator.SimpleStrategy',
|
||||
'OldNetworkTopologyStrategy',
|
||||
'org.apache.cassandra.locator.OldNetworkTopologyStrategy'):
|
||||
return ['strategy_options:replication_factor =']
|
||||
return [Hint('<strategy_option_name>')]
|
||||
|
||||
|
|
|
|||
|
|
@ -260,7 +260,9 @@ class CqlParsingRuleSet(pylexotron.ParsingRuleSet):
|
|||
candidates = newcandidates
|
||||
|
||||
# append a space for single, complete identifiers
|
||||
if len(candidates) == 1 and candidates[0][-1].isalnum():
|
||||
if len(candidates) == 1 and candidates[0][-1].isalnum() \
|
||||
and lasttype != 'unclosedString' \
|
||||
and lasttype != 'unclosedName':
|
||||
candidates[0] += ' '
|
||||
return candidates, hints
|
||||
|
||||
|
|
@ -734,7 +736,10 @@ def create_ks_opt_completer(ctxt, cass):
|
|||
return ['strategy_class =']
|
||||
vals = ctxt.get_binding('optval')
|
||||
stratclass = dequote_value(vals[stratopt])
|
||||
if stratclass in ('SimpleStrategy', 'OldNetworkTopologyStrategy'):
|
||||
if stratclass in ('SimpleStrategy',
|
||||
'org.apache.cassandra.locator.SimpleStrategy',
|
||||
'OldNetworkTopologyStrategy',
|
||||
'org.apache.cassandra.locator.OldNetworkTopologyStrategy'):
|
||||
return ['strategy_options:replication_factor =']
|
||||
return [Hint('<strategy_option_name>')]
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue