cassandra git commit: Rename nodetool --with-port to --print-port to disambiguate from --port

2018-04-19 Thread aweisberg
Repository: cassandra
Updated Branches:
  refs/heads/trunk cb67bfc16 -> a8be43e45


Rename nodetool --with-port to --print-port to disambiguate from --port

Patch by Ariel Weisberg; Reviewed by Stefan Podkowinski for CASSANDRA-14392


Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/a8be43e4
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/a8be43e4
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/a8be43e4

Branch: refs/heads/trunk
Commit: a8be43e45424950abaabed4e450d125e91ecaab2
Parents: cb67bfc
Author: Ariel Weisberg 
Authored: Tue Apr 17 12:35:38 2018 -0400
Committer: Ariel Weisberg 
Committed: Thu Apr 19 18:20:15 2018 -0400

--
 CHANGES.txt   |  1 +
 src/java/org/apache/cassandra/tools/NodeTool.java |  4 ++--
 .../cassandra/tools/nodetool/DescribeCluster.java |  2 +-
 .../cassandra/tools/nodetool/DescribeRing.java|  2 +-
 .../tools/nodetool/FailureDetectorInfo.java   |  2 +-
 .../cassandra/tools/nodetool/GetEndpoints.java|  2 +-
 .../cassandra/tools/nodetool/GossipInfo.java  |  2 +-
 .../apache/cassandra/tools/nodetool/NetStats.java |  8 
 .../cassandra/tools/nodetool/RemoveNode.java  |  4 ++--
 .../org/apache/cassandra/tools/nodetool/Ring.java |  4 ++--
 .../apache/cassandra/tools/nodetool/Status.java   | 18 +-
 11 files changed, 25 insertions(+), 24 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/cassandra/blob/a8be43e4/CHANGES.txt
--
diff --git a/CHANGES.txt b/CHANGES.txt
index a8dbbba..7d9769c 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -1,4 +1,5 @@
 4.0
+ * Rename nodetool --with-port to --print-port to disambiguate from --port 
(CASSANDRA-14392)
  * Client TOPOLOGY_CHANGE messages have wrong port. (CASSANDRA-14398)
  * Add ability to load new SSTables from a separate directory (CASSANDRA-6719)
  * Eliminate background repair and probablistic read_repair_chance table 
options

http://git-wip-us.apache.org/repos/asf/cassandra/blob/a8be43e4/src/java/org/apache/cassandra/tools/NodeTool.java
--
diff --git a/src/java/org/apache/cassandra/tools/NodeTool.java 
b/src/java/org/apache/cassandra/tools/NodeTool.java
index d4cc291..fb9204c 100644
--- a/src/java/org/apache/cassandra/tools/NodeTool.java
+++ b/src/java/org/apache/cassandra/tools/NodeTool.java
@@ -253,8 +253,8 @@ public class NodeTool
 @Option(type = OptionType.GLOBAL, name = {"-pwf", "--password-file"}, 
description = "Path to the JMX password file")
 private String passwordFilePath = EMPTY;
 
-@Option(type = OptionType.GLOBAL, name = { "-wp", "--with-port"}, 
description = "Operate in 4.0 mode with hosts disambiguated by port number", 
arity = 0)
-protected boolean withPort = false;
+@Option(type = OptionType.GLOBAL, name = { "-pp", "--print-port"}, 
description = "Operate in 4.0 mode with hosts disambiguated by port number", 
arity = 0)
+protected boolean printPort = false;
 
 @Override
 public void run()

http://git-wip-us.apache.org/repos/asf/cassandra/blob/a8be43e4/src/java/org/apache/cassandra/tools/nodetool/DescribeCluster.java
--
diff --git a/src/java/org/apache/cassandra/tools/nodetool/DescribeCluster.java 
b/src/java/org/apache/cassandra/tools/nodetool/DescribeCluster.java
index da02db6..fe33551 100644
--- a/src/java/org/apache/cassandra/tools/nodetool/DescribeCluster.java
+++ b/src/java/org/apache/cassandra/tools/nodetool/DescribeCluster.java
@@ -59,7 +59,7 @@ public class DescribeCluster extends NodeToolCmd
 
 // display schema version for each node
 System.out.println("\tSchema versions:");
-Map schemaVersions = withPort ? 
probe.getSpProxy().getSchemaVersionsWithPort() : 
probe.getSpProxy().getSchemaVersions();
+Map schemaVersions = printPort ? 
probe.getSpProxy().getSchemaVersionsWithPort() : 
probe.getSpProxy().getSchemaVersions();
 for (String version : schemaVersions.keySet())
 {
 System.out.println(format("\t\t%s: %s%n", version, 
schemaVersions.get(version)));

http://git-wip-us.apache.org/repos/asf/cassandra/blob/a8be43e4/src/java/org/apache/cassandra/tools/nodetool/DescribeRing.java
--
diff --git a/src/java/org/apache/cassandra/tools/nodetool/DescribeRing.java 
b/src/java/org/apache/cassandra/tools/nodetool/DescribeRing.java
index c57e54d..ef8c97e 100644
--- a/src/java/org/apache/cassandra/tools/nodetool/DescribeRing.java
+++ 

cassandra git commit: Rename copy.py to copyutil.py in cqlshlib

2015-12-11 Thread slebresne
Repository: cassandra
Updated Branches:
  refs/heads/cassandra-2.1 9135340a1 -> 95dab2730


Rename copy.py to copyutil.py in cqlshlib

explanation

patch by Stefania; reviewed by pauloricardomg for CASSANDRA-10799


Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/95dab273
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/95dab273
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/95dab273

Branch: refs/heads/cassandra-2.1
Commit: 95dab2730da5a046ffdd550e72c66d1847cf9d8f
Parents: 9135340
Author: Stefania Alborghetti 
Authored: Fri Dec 4 13:21:35 2015 +0100
Committer: Sylvain Lebresne 
Committed: Fri Dec 11 11:48:15 2015 +0100

--
 bin/cqlsh  |  14 +-
 pylib/cqlshlib/copy.py | 644 
 pylib/cqlshlib/copyutil.py | 644 
 3 files changed, 651 insertions(+), 651 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/cassandra/blob/95dab273/bin/cqlsh
--
diff --git a/bin/cqlsh b/bin/cqlsh
index 3e830b5..e72624a 100755
--- a/bin/cqlsh
+++ b/bin/cqlsh
@@ -121,7 +121,7 @@ cqlshlibdir = os.path.join(CASSANDRA_PATH, 'pylib')
 if os.path.isdir(cqlshlibdir):
 sys.path.insert(0, cqlshlibdir)
 
-from cqlshlib import cql3handling, cqlhandling, pylexotron, sslhandling, copy
+from cqlshlib import cql3handling, cqlhandling, copyutil, pylexotron, 
sslhandling
 from cqlshlib.displaying import (ANSI_RESET, BLUE, COLUMN_NAME_COLORS, CYAN,
  RED, FormattedValue, colorme)
 from cqlshlib.formatting import (format_by_type, format_value_utype,
@@ -1569,7 +1569,7 @@ class Shell(cmd.Cmd):
 print "\n%d rows %s in %s." % (rows, verb, describe_interval(timeend - 
timestart))
 
 def perform_csv_import(self, ks, cf, columns, fname, opts):
-csv_options, dialect_options, unrecognized_options = 
copy.parse_options(self, opts)
+csv_options, dialect_options, unrecognized_options = 
copyutil.parse_options(self, opts)
 if unrecognized_options:
 self.printerr('Unrecognized COPY FROM options: %s'
   % ', '.join(unrecognized_options.keys()))
@@ -1595,7 +1595,7 @@ class Shell(cmd.Cmd):
 linesource.next()
 reader = csv.reader(linesource, **dialect_options)
 
-num_processes = copy.get_num_processes(cap=4)
+num_processes = copyutil.get_num_processes(cap=4)
 
 for i in range(num_processes):
 parent_conn, child_conn = mp.Pipe()
@@ -1606,7 +1606,7 @@ class Shell(cmd.Cmd):
 for process in processes:
 process.start()
 
-meter = copy.RateMeter(1)
+meter = copyutil.RateMeter(1)
 for current_record, row in enumerate(reader, start=1):
 # write to the child process
 pipes[current_record % num_processes].send((current_record, 
row))
@@ -1820,13 +1820,13 @@ class Shell(cmd.Cmd):
 new_cluster.shutdown()
 
 def perform_csv_export(self, ks, cf, columns, fname, opts):
-csv_options, dialect_options, unrecognized_options = 
copy.parse_options(self, opts)
+csv_options, dialect_options, unrecognized_options = 
copyutil.parse_options(self, opts)
 if unrecognized_options:
 self.printerr('Unrecognized COPY TO options: %s' % ', 
'.join(unrecognized_options.keys()))
 return 0
 
-return copy.ExportTask(self, ks, cf, columns, fname, csv_options, 
dialect_options,
-   DEFAULT_PROTOCOL_VERSION, CONFIG_FILE).run()
+return copyutil.ExportTask(self, ks, cf, columns, fname, csv_options, 
dialect_options,
+   DEFAULT_PROTOCOL_VERSION, CONFIG_FILE).run()
 
 def do_show(self, parsed):
 """

http://git-wip-us.apache.org/repos/asf/cassandra/blob/95dab273/pylib/cqlshlib/copy.py
--
diff --git a/pylib/cqlshlib/copy.py b/pylib/cqlshlib/copy.py
deleted file mode 100644
index 8534b98..000
--- a/pylib/cqlshlib/copy.py
+++ /dev/null
@@ -1,644 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by 

[1/4] cassandra git commit: Rename copy.py to copyutil.py in cqlshlib

2015-12-11 Thread slebresne
Repository: cassandra
Updated Branches:
  refs/heads/cassandra-3.0 37ca86b94 -> b55523e97


Rename copy.py to copyutil.py in cqlshlib

explanation

patch by Stefania; reviewed by pauloricardomg for CASSANDRA-10799


Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/95dab273
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/95dab273
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/95dab273

Branch: refs/heads/cassandra-3.0
Commit: 95dab2730da5a046ffdd550e72c66d1847cf9d8f
Parents: 9135340
Author: Stefania Alborghetti 
Authored: Fri Dec 4 13:21:35 2015 +0100
Committer: Sylvain Lebresne 
Committed: Fri Dec 11 11:48:15 2015 +0100

--
 bin/cqlsh  |  14 +-
 pylib/cqlshlib/copy.py | 644 
 pylib/cqlshlib/copyutil.py | 644 
 3 files changed, 651 insertions(+), 651 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/cassandra/blob/95dab273/bin/cqlsh
--
diff --git a/bin/cqlsh b/bin/cqlsh
index 3e830b5..e72624a 100755
--- a/bin/cqlsh
+++ b/bin/cqlsh
@@ -121,7 +121,7 @@ cqlshlibdir = os.path.join(CASSANDRA_PATH, 'pylib')
 if os.path.isdir(cqlshlibdir):
 sys.path.insert(0, cqlshlibdir)
 
-from cqlshlib import cql3handling, cqlhandling, pylexotron, sslhandling, copy
+from cqlshlib import cql3handling, cqlhandling, copyutil, pylexotron, 
sslhandling
 from cqlshlib.displaying import (ANSI_RESET, BLUE, COLUMN_NAME_COLORS, CYAN,
  RED, FormattedValue, colorme)
 from cqlshlib.formatting import (format_by_type, format_value_utype,
@@ -1569,7 +1569,7 @@ class Shell(cmd.Cmd):
 print "\n%d rows %s in %s." % (rows, verb, describe_interval(timeend - 
timestart))
 
 def perform_csv_import(self, ks, cf, columns, fname, opts):
-csv_options, dialect_options, unrecognized_options = 
copy.parse_options(self, opts)
+csv_options, dialect_options, unrecognized_options = 
copyutil.parse_options(self, opts)
 if unrecognized_options:
 self.printerr('Unrecognized COPY FROM options: %s'
   % ', '.join(unrecognized_options.keys()))
@@ -1595,7 +1595,7 @@ class Shell(cmd.Cmd):
 linesource.next()
 reader = csv.reader(linesource, **dialect_options)
 
-num_processes = copy.get_num_processes(cap=4)
+num_processes = copyutil.get_num_processes(cap=4)
 
 for i in range(num_processes):
 parent_conn, child_conn = mp.Pipe()
@@ -1606,7 +1606,7 @@ class Shell(cmd.Cmd):
 for process in processes:
 process.start()
 
-meter = copy.RateMeter(1)
+meter = copyutil.RateMeter(1)
 for current_record, row in enumerate(reader, start=1):
 # write to the child process
 pipes[current_record % num_processes].send((current_record, 
row))
@@ -1820,13 +1820,13 @@ class Shell(cmd.Cmd):
 new_cluster.shutdown()
 
 def perform_csv_export(self, ks, cf, columns, fname, opts):
-csv_options, dialect_options, unrecognized_options = 
copy.parse_options(self, opts)
+csv_options, dialect_options, unrecognized_options = 
copyutil.parse_options(self, opts)
 if unrecognized_options:
 self.printerr('Unrecognized COPY TO options: %s' % ', 
'.join(unrecognized_options.keys()))
 return 0
 
-return copy.ExportTask(self, ks, cf, columns, fname, csv_options, 
dialect_options,
-   DEFAULT_PROTOCOL_VERSION, CONFIG_FILE).run()
+return copyutil.ExportTask(self, ks, cf, columns, fname, csv_options, 
dialect_options,
+   DEFAULT_PROTOCOL_VERSION, CONFIG_FILE).run()
 
 def do_show(self, parsed):
 """

http://git-wip-us.apache.org/repos/asf/cassandra/blob/95dab273/pylib/cqlshlib/copy.py
--
diff --git a/pylib/cqlshlib/copy.py b/pylib/cqlshlib/copy.py
deleted file mode 100644
index 8534b98..000
--- a/pylib/cqlshlib/copy.py
+++ /dev/null
@@ -1,644 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by 

[1/3] cassandra git commit: Rename copy.py to copyutil.py in cqlshlib

2015-12-11 Thread slebresne
Repository: cassandra
Updated Branches:
  refs/heads/cassandra-2.2 b4d3ac40b -> 7dd6b7de2


Rename copy.py to copyutil.py in cqlshlib

explanation

patch by Stefania; reviewed by pauloricardomg for CASSANDRA-10799


Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/95dab273
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/95dab273
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/95dab273

Branch: refs/heads/cassandra-2.2
Commit: 95dab2730da5a046ffdd550e72c66d1847cf9d8f
Parents: 9135340
Author: Stefania Alborghetti 
Authored: Fri Dec 4 13:21:35 2015 +0100
Committer: Sylvain Lebresne 
Committed: Fri Dec 11 11:48:15 2015 +0100

--
 bin/cqlsh  |  14 +-
 pylib/cqlshlib/copy.py | 644 
 pylib/cqlshlib/copyutil.py | 644 
 3 files changed, 651 insertions(+), 651 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/cassandra/blob/95dab273/bin/cqlsh
--
diff --git a/bin/cqlsh b/bin/cqlsh
index 3e830b5..e72624a 100755
--- a/bin/cqlsh
+++ b/bin/cqlsh
@@ -121,7 +121,7 @@ cqlshlibdir = os.path.join(CASSANDRA_PATH, 'pylib')
 if os.path.isdir(cqlshlibdir):
 sys.path.insert(0, cqlshlibdir)
 
-from cqlshlib import cql3handling, cqlhandling, pylexotron, sslhandling, copy
+from cqlshlib import cql3handling, cqlhandling, copyutil, pylexotron, 
sslhandling
 from cqlshlib.displaying import (ANSI_RESET, BLUE, COLUMN_NAME_COLORS, CYAN,
  RED, FormattedValue, colorme)
 from cqlshlib.formatting import (format_by_type, format_value_utype,
@@ -1569,7 +1569,7 @@ class Shell(cmd.Cmd):
 print "\n%d rows %s in %s." % (rows, verb, describe_interval(timeend - 
timestart))
 
 def perform_csv_import(self, ks, cf, columns, fname, opts):
-csv_options, dialect_options, unrecognized_options = 
copy.parse_options(self, opts)
+csv_options, dialect_options, unrecognized_options = 
copyutil.parse_options(self, opts)
 if unrecognized_options:
 self.printerr('Unrecognized COPY FROM options: %s'
   % ', '.join(unrecognized_options.keys()))
@@ -1595,7 +1595,7 @@ class Shell(cmd.Cmd):
 linesource.next()
 reader = csv.reader(linesource, **dialect_options)
 
-num_processes = copy.get_num_processes(cap=4)
+num_processes = copyutil.get_num_processes(cap=4)
 
 for i in range(num_processes):
 parent_conn, child_conn = mp.Pipe()
@@ -1606,7 +1606,7 @@ class Shell(cmd.Cmd):
 for process in processes:
 process.start()
 
-meter = copy.RateMeter(1)
+meter = copyutil.RateMeter(1)
 for current_record, row in enumerate(reader, start=1):
 # write to the child process
 pipes[current_record % num_processes].send((current_record, 
row))
@@ -1820,13 +1820,13 @@ class Shell(cmd.Cmd):
 new_cluster.shutdown()
 
 def perform_csv_export(self, ks, cf, columns, fname, opts):
-csv_options, dialect_options, unrecognized_options = 
copy.parse_options(self, opts)
+csv_options, dialect_options, unrecognized_options = 
copyutil.parse_options(self, opts)
 if unrecognized_options:
 self.printerr('Unrecognized COPY TO options: %s' % ', 
'.join(unrecognized_options.keys()))
 return 0
 
-return copy.ExportTask(self, ks, cf, columns, fname, csv_options, 
dialect_options,
-   DEFAULT_PROTOCOL_VERSION, CONFIG_FILE).run()
+return copyutil.ExportTask(self, ks, cf, columns, fname, csv_options, 
dialect_options,
+   DEFAULT_PROTOCOL_VERSION, CONFIG_FILE).run()
 
 def do_show(self, parsed):
 """

http://git-wip-us.apache.org/repos/asf/cassandra/blob/95dab273/pylib/cqlshlib/copy.py
--
diff --git a/pylib/cqlshlib/copy.py b/pylib/cqlshlib/copy.py
deleted file mode 100644
index 8534b98..000
--- a/pylib/cqlshlib/copy.py
+++ /dev/null
@@ -1,644 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by 

[1/5] cassandra git commit: Rename copy.py to copyutil.py in cqlshlib

2015-12-11 Thread slebresne
Repository: cassandra
Updated Branches:
  refs/heads/trunk 4d6fdaae9 -> 105ccb3d2


Rename copy.py to copyutil.py in cqlshlib

explanation

patch by Stefania; reviewed by pauloricardomg for CASSANDRA-10799


Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/95dab273
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/95dab273
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/95dab273

Branch: refs/heads/trunk
Commit: 95dab2730da5a046ffdd550e72c66d1847cf9d8f
Parents: 9135340
Author: Stefania Alborghetti 
Authored: Fri Dec 4 13:21:35 2015 +0100
Committer: Sylvain Lebresne 
Committed: Fri Dec 11 11:48:15 2015 +0100

--
 bin/cqlsh  |  14 +-
 pylib/cqlshlib/copy.py | 644 
 pylib/cqlshlib/copyutil.py | 644 
 3 files changed, 651 insertions(+), 651 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/cassandra/blob/95dab273/bin/cqlsh
--
diff --git a/bin/cqlsh b/bin/cqlsh
index 3e830b5..e72624a 100755
--- a/bin/cqlsh
+++ b/bin/cqlsh
@@ -121,7 +121,7 @@ cqlshlibdir = os.path.join(CASSANDRA_PATH, 'pylib')
 if os.path.isdir(cqlshlibdir):
 sys.path.insert(0, cqlshlibdir)
 
-from cqlshlib import cql3handling, cqlhandling, pylexotron, sslhandling, copy
+from cqlshlib import cql3handling, cqlhandling, copyutil, pylexotron, 
sslhandling
 from cqlshlib.displaying import (ANSI_RESET, BLUE, COLUMN_NAME_COLORS, CYAN,
  RED, FormattedValue, colorme)
 from cqlshlib.formatting import (format_by_type, format_value_utype,
@@ -1569,7 +1569,7 @@ class Shell(cmd.Cmd):
 print "\n%d rows %s in %s." % (rows, verb, describe_interval(timeend - 
timestart))
 
 def perform_csv_import(self, ks, cf, columns, fname, opts):
-csv_options, dialect_options, unrecognized_options = 
copy.parse_options(self, opts)
+csv_options, dialect_options, unrecognized_options = 
copyutil.parse_options(self, opts)
 if unrecognized_options:
 self.printerr('Unrecognized COPY FROM options: %s'
   % ', '.join(unrecognized_options.keys()))
@@ -1595,7 +1595,7 @@ class Shell(cmd.Cmd):
 linesource.next()
 reader = csv.reader(linesource, **dialect_options)
 
-num_processes = copy.get_num_processes(cap=4)
+num_processes = copyutil.get_num_processes(cap=4)
 
 for i in range(num_processes):
 parent_conn, child_conn = mp.Pipe()
@@ -1606,7 +1606,7 @@ class Shell(cmd.Cmd):
 for process in processes:
 process.start()
 
-meter = copy.RateMeter(1)
+meter = copyutil.RateMeter(1)
 for current_record, row in enumerate(reader, start=1):
 # write to the child process
 pipes[current_record % num_processes].send((current_record, 
row))
@@ -1820,13 +1820,13 @@ class Shell(cmd.Cmd):
 new_cluster.shutdown()
 
 def perform_csv_export(self, ks, cf, columns, fname, opts):
-csv_options, dialect_options, unrecognized_options = 
copy.parse_options(self, opts)
+csv_options, dialect_options, unrecognized_options = 
copyutil.parse_options(self, opts)
 if unrecognized_options:
 self.printerr('Unrecognized COPY TO options: %s' % ', 
'.join(unrecognized_options.keys()))
 return 0
 
-return copy.ExportTask(self, ks, cf, columns, fname, csv_options, 
dialect_options,
-   DEFAULT_PROTOCOL_VERSION, CONFIG_FILE).run()
+return copyutil.ExportTask(self, ks, cf, columns, fname, csv_options, 
dialect_options,
+   DEFAULT_PROTOCOL_VERSION, CONFIG_FILE).run()
 
 def do_show(self, parsed):
 """

http://git-wip-us.apache.org/repos/asf/cassandra/blob/95dab273/pylib/cqlshlib/copy.py
--
diff --git a/pylib/cqlshlib/copy.py b/pylib/cqlshlib/copy.py
deleted file mode 100644
index 8534b98..000
--- a/pylib/cqlshlib/copy.py
+++ /dev/null
@@ -1,644 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or 

cassandra git commit: Rename DataOutputBuffer.getFilePointer() to position()

2015-09-15 Thread snazy
Repository: cassandra
Updated Branches:
  refs/heads/cassandra-3.0 a54589e12 -> 753a94332


Rename DataOutputBuffer.getFilePointer() to position()

patch by Robert Stupp; reviewed by Benedict for CASSANDRA-10349


Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/753a9433
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/753a9433
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/753a9433

Branch: refs/heads/cassandra-3.0
Commit: 753a9433228cb4579f0602b9292dd16944339607
Parents: a54589e
Author: Robert Stupp 
Authored: Wed Sep 16 00:43:11 2015 +0200
Committer: Robert Stupp 
Committed: Wed Sep 16 00:43:11 2015 +0200

--
 .../org/apache/cassandra/db/ColumnIndex.java|  6 +++---
 .../org/apache/cassandra/db/RowIndexEntry.java  |  6 +++---
 .../io/sstable/format/big/BigTableWriter.java   | 12 +--
 .../cassandra/io/util/DataOutputBuffer.java |  4 ++--
 .../cassandra/io/util/DataOutputPlus.java   | 21 
 .../cassandra/io/util/SequentialWriter.java |  6 +++---
 .../apache/cassandra/db/RowIndexEntryTest.java  |  4 ++--
 .../io/util/BufferedRandomAccessFileTest.java   | 10 +-
 .../compression/CompressedInputStreamTest.java  |  2 +-
 9 files changed, 42 insertions(+), 29 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/cassandra/blob/753a9433/src/java/org/apache/cassandra/db/ColumnIndex.java
--
diff --git a/src/java/org/apache/cassandra/db/ColumnIndex.java 
b/src/java/org/apache/cassandra/db/ColumnIndex.java
index 6b2ef59..add5fa7 100644
--- a/src/java/org/apache/cassandra/db/ColumnIndex.java
+++ b/src/java/org/apache/cassandra/db/ColumnIndex.java
@@ -91,7 +91,7 @@ public class ColumnIndex
 this.writer = writer;
 this.header = header;
 this.version = version;
-this.initialPosition = writer.getFilePointer();
+this.initialPosition = writer.position();
 }
 
 private void writePartitionHeader(UnfilteredRowIterator iterator) 
throws IOException
@@ -105,7 +105,7 @@ public class ColumnIndex
 public ColumnIndex build() throws IOException
 {
 writePartitionHeader(iterator);
-this.headerLength = writer.getFilePointer() - initialPosition;
+this.headerLength = writer.position() - initialPosition;
 
 while (iterator.hasNext())
 add(iterator.next());
@@ -115,7 +115,7 @@ public class ColumnIndex
 
 private long currentPosition()
 {
-return writer.getFilePointer() - initialPosition;
+return writer.position() - initialPosition;
 }
 
 private void addIndexBlock()

http://git-wip-us.apache.org/repos/asf/cassandra/blob/753a9433/src/java/org/apache/cassandra/db/RowIndexEntry.java
--
diff --git a/src/java/org/apache/cassandra/db/RowIndexEntry.java 
b/src/java/org/apache/cassandra/db/RowIndexEntry.java
index 6cd6542..43dc80c 100644
--- a/src/java/org/apache/cassandra/db/RowIndexEntry.java
+++ b/src/java/org/apache/cassandra/db/RowIndexEntry.java
@@ -142,15 +142,15 @@ public class RowIndexEntry implements IMeasurableMemory
 
 int[] offsets = new int[rie.columnsIndex().size()];
 
-if (out.hasFilePointer())
+if (out.hasPosition())
 {
 // Out is usually a SequentialWriter, so using the 
file-pointer is fine to generate the offsets.
 // A DataOutputBuffer also works.
-long start = out.getFilePointer();
+long start = out.position();
 int i = 0;
 for (IndexHelper.IndexInfo info : rie.columnsIndex())
 {
-offsets[i] = i == 0 ? 0 : (int)(out.getFilePointer() - 
start);
+offsets[i] = i == 0 ? 0 : (int)(out.position() - 
start);
 i++;
 idxSerializer.serialize(info, out);
 }

http://git-wip-us.apache.org/repos/asf/cassandra/blob/753a9433/src/java/org/apache/cassandra/io/sstable/format/big/BigTableWriter.java
--
diff --git 
a/src/java/org/apache/cassandra/io/sstable/format/big/BigTableWriter.java 
b/src/java/org/apache/cassandra/io/sstable/format/big/BigTableWriter.java
index 089ae6f..3d68a74 100644
--- a/src/java/org/apache/cassandra/io/sstable/format/big/BigTableWriter.java
+++ b/src/java/org/apache/cassandra/io/sstable/format/big/BigTableWriter.java
@@ -107,7 +107,7 @@ public class BigTableWriter extends 

[1/2] cassandra git commit: Rename DataOutputBuffer.getFilePointer() to position()

2015-09-15 Thread snazy
Repository: cassandra
Updated Branches:
  refs/heads/trunk 131e097a7 -> cdaba04d3


Rename DataOutputBuffer.getFilePointer() to position()

patch by Robert Stupp; reviewed by Benedict for CASSANDRA-10349


Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/753a9433
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/753a9433
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/753a9433

Branch: refs/heads/trunk
Commit: 753a9433228cb4579f0602b9292dd16944339607
Parents: a54589e
Author: Robert Stupp 
Authored: Wed Sep 16 00:43:11 2015 +0200
Committer: Robert Stupp 
Committed: Wed Sep 16 00:43:11 2015 +0200

--
 .../org/apache/cassandra/db/ColumnIndex.java|  6 +++---
 .../org/apache/cassandra/db/RowIndexEntry.java  |  6 +++---
 .../io/sstable/format/big/BigTableWriter.java   | 12 +--
 .../cassandra/io/util/DataOutputBuffer.java |  4 ++--
 .../cassandra/io/util/DataOutputPlus.java   | 21 
 .../cassandra/io/util/SequentialWriter.java |  6 +++---
 .../apache/cassandra/db/RowIndexEntryTest.java  |  4 ++--
 .../io/util/BufferedRandomAccessFileTest.java   | 10 +-
 .../compression/CompressedInputStreamTest.java  |  2 +-
 9 files changed, 42 insertions(+), 29 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/cassandra/blob/753a9433/src/java/org/apache/cassandra/db/ColumnIndex.java
--
diff --git a/src/java/org/apache/cassandra/db/ColumnIndex.java 
b/src/java/org/apache/cassandra/db/ColumnIndex.java
index 6b2ef59..add5fa7 100644
--- a/src/java/org/apache/cassandra/db/ColumnIndex.java
+++ b/src/java/org/apache/cassandra/db/ColumnIndex.java
@@ -91,7 +91,7 @@ public class ColumnIndex
 this.writer = writer;
 this.header = header;
 this.version = version;
-this.initialPosition = writer.getFilePointer();
+this.initialPosition = writer.position();
 }
 
 private void writePartitionHeader(UnfilteredRowIterator iterator) 
throws IOException
@@ -105,7 +105,7 @@ public class ColumnIndex
 public ColumnIndex build() throws IOException
 {
 writePartitionHeader(iterator);
-this.headerLength = writer.getFilePointer() - initialPosition;
+this.headerLength = writer.position() - initialPosition;
 
 while (iterator.hasNext())
 add(iterator.next());
@@ -115,7 +115,7 @@ public class ColumnIndex
 
 private long currentPosition()
 {
-return writer.getFilePointer() - initialPosition;
+return writer.position() - initialPosition;
 }
 
 private void addIndexBlock()

http://git-wip-us.apache.org/repos/asf/cassandra/blob/753a9433/src/java/org/apache/cassandra/db/RowIndexEntry.java
--
diff --git a/src/java/org/apache/cassandra/db/RowIndexEntry.java 
b/src/java/org/apache/cassandra/db/RowIndexEntry.java
index 6cd6542..43dc80c 100644
--- a/src/java/org/apache/cassandra/db/RowIndexEntry.java
+++ b/src/java/org/apache/cassandra/db/RowIndexEntry.java
@@ -142,15 +142,15 @@ public class RowIndexEntry implements IMeasurableMemory
 
 int[] offsets = new int[rie.columnsIndex().size()];
 
-if (out.hasFilePointer())
+if (out.hasPosition())
 {
 // Out is usually a SequentialWriter, so using the 
file-pointer is fine to generate the offsets.
 // A DataOutputBuffer also works.
-long start = out.getFilePointer();
+long start = out.position();
 int i = 0;
 for (IndexHelper.IndexInfo info : rie.columnsIndex())
 {
-offsets[i] = i == 0 ? 0 : (int)(out.getFilePointer() - 
start);
+offsets[i] = i == 0 ? 0 : (int)(out.position() - 
start);
 i++;
 idxSerializer.serialize(info, out);
 }

http://git-wip-us.apache.org/repos/asf/cassandra/blob/753a9433/src/java/org/apache/cassandra/io/sstable/format/big/BigTableWriter.java
--
diff --git 
a/src/java/org/apache/cassandra/io/sstable/format/big/BigTableWriter.java 
b/src/java/org/apache/cassandra/io/sstable/format/big/BigTableWriter.java
index 089ae6f..3d68a74 100644
--- a/src/java/org/apache/cassandra/io/sstable/format/big/BigTableWriter.java
+++ b/src/java/org/apache/cassandra/io/sstable/format/big/BigTableWriter.java
@@ -107,7 +107,7 @@ public class BigTableWriter extends SSTableWriter
 

[1/2] cassandra git commit: Rename ColumnDefinition.Kind.CLUSTERING_COLUMN to CLUSTERING

2015-07-17 Thread aleksey
Repository: cassandra
Updated Branches:
  refs/heads/trunk 87f197593 - dc8523819


Rename ColumnDefinition.Kind.CLUSTERING_COLUMN to CLUSTERING

patch by Aleksey Yeschenko; reviewed by Tyler Hobbs for CASSANDRA-6717


Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/8d7c608b
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/8d7c608b
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/8d7c608b

Branch: refs/heads/trunk
Commit: 8d7c608bac9440911f4803db04f306f0616f2a22
Parents: 87f1975
Author: Aleksey Yeschenko alek...@apache.org
Authored: Fri Jul 17 23:16:08 2015 +0300
Committer: Aleksey Yeschenko alek...@apache.org
Committed: Fri Jul 17 23:17:18 2015 +0300

--
 src/java/org/apache/cassandra/config/CFMetaData.java   |  6 +++---
 .../org/apache/cassandra/config/ColumnDefinition.java  | 13 ++---
 .../cassandra/cql3/statements/AlterTableStatement.java |  6 +++---
 .../cql3/statements/ModificationStatement.java |  6 +++---
 .../cassandra/cql3/statements/SelectStatement.java |  2 +-
 .../cassandra/cql3/statements/UpdateStatement.java |  2 +-
 src/java/org/apache/cassandra/db/filter/RowFilter.java |  2 +-
 .../index/AbstractSimplePerColumnSecondaryIndex.java   |  2 +-
 .../cassandra/db/index/composites/CompositesIndex.java |  2 +-
 .../composites/CompositesIndexOnClusteringKey.java |  2 +-
 .../apache/cassandra/schema/LegacySchemaMigrator.java  |  2 +-
 .../org/apache/cassandra/schema/SchemaKeyspace.java|  6 +++---
 .../cassandra/schema/LegacySchemaMigratorTest.java |  4 ++--
 13 files changed, 27 insertions(+), 28 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/cassandra/blob/8d7c608b/src/java/org/apache/cassandra/config/CFMetaData.java
--
diff --git a/src/java/org/apache/cassandra/config/CFMetaData.java 
b/src/java/org/apache/cassandra/config/CFMetaData.java
index ee1ed25..4505c6d 100644
--- a/src/java/org/apache/cassandra/config/CFMetaData.java
+++ b/src/java/org/apache/cassandra/config/CFMetaData.java
@@ -310,7 +310,7 @@ public final class CFMetaData
 case PARTITION_KEY:
 partitions.add(column);
 break;
-case CLUSTERING_COLUMN:
+case CLUSTERING:
 clusterings.add(column);
 break;
 default:
@@ -1159,7 +1159,7 @@ public final class CFMetaData
 ListAbstractType? keyTypes = 
extractTypes(partitionKeyColumns);
 keyValidator = keyTypes.size() == 1 ? keyTypes.get(0) : 
CompositeType.getInstance(keyTypes);
 break;
-case CLUSTERING_COLUMN:
+case CLUSTERING:
 clusteringColumns.set(def.position(), def);
 comparator = new 
ClusteringComparator(extractTypes(clusteringColumns));
 break;
@@ -1482,7 +1482,7 @@ public final class CFMetaData
 for (int i = 0; i  clusteringColumns.size(); i++)
 {
 PairColumnIdentifier, AbstractType p = 
clusteringColumns.get(i);
-clusterings.add(new ColumnDefinition(keyspace, table, p.left, 
p.right, i, ColumnDefinition.Kind.CLUSTERING_COLUMN));
+clusterings.add(new ColumnDefinition(keyspace, table, p.left, 
p.right, i, ColumnDefinition.Kind.CLUSTERING));
 }
 
 for (int i = 0; i  regularColumns.size(); i++)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/8d7c608b/src/java/org/apache/cassandra/config/ColumnDefinition.java
--
diff --git a/src/java/org/apache/cassandra/config/ColumnDefinition.java 
b/src/java/org/apache/cassandra/config/ColumnDefinition.java
index 8448ca6..432d5a8 100644
--- a/src/java/org/apache/cassandra/config/ColumnDefinition.java
+++ b/src/java/org/apache/cassandra/config/ColumnDefinition.java
@@ -30,14 +30,13 @@ import org.apache.cassandra.db.rows.*;
 import org.apache.cassandra.db.marshal.*;
 import org.apache.cassandra.serializers.MarshalException;
 import org.apache.cassandra.exceptions.*;
-import org.apache.cassandra.utils.ByteBufferUtil;
 
 public class ColumnDefinition extends ColumnSpecification implements 
ComparableColumnDefinition
 {
 /*
  * The type of CQL3 column this definition represents.
  * There is 4 main type of CQL3 columns: those parts of the partition key,
- * those parts of the clustering key and amongst the others, regular and
+ * those parts of the clustering columns and amongst the others, regular 
and
  * static ones.
  *
  * Note that thrift only knows about definitions of type REGULAR (and
@@ -46,13 +45,13 @@ public class ColumnDefinition extends 

[1/2] cassandra git commit: Rename and move config.KSMetaData to schema.KeyspaceMetadata

2015-07-01 Thread aleksey
Repository: cassandra
Updated Branches:
  refs/heads/trunk 31e3f612b - a89597da1


http://git-wip-us.apache.org/repos/asf/cassandra/blob/a89597da/test/unit/org/apache/cassandra/cql3/validation/entities/UFTest.java
--
diff --git 
a/test/unit/org/apache/cassandra/cql3/validation/entities/UFTest.java 
b/test/unit/org/apache/cassandra/cql3/validation/entities/UFTest.java
index ee9364a..637e072 100644
--- a/test/unit/org/apache/cassandra/cql3/validation/entities/UFTest.java
+++ b/test/unit/org/apache/cassandra/cql3/validation/entities/UFTest.java
@@ -36,7 +36,6 @@ import org.junit.Test;
 
 import com.datastax.driver.core.*;
 import com.datastax.driver.core.exceptions.InvalidQueryException;
-import org.apache.cassandra.config.KSMetaData;
 import org.apache.cassandra.config.Schema;
 import org.apache.cassandra.cql3.QueryProcessor;
 import org.apache.cassandra.cql3.UntypedResultSet;
@@ -47,6 +46,7 @@ import org.apache.cassandra.db.marshal.CollectionType;
 import org.apache.cassandra.dht.ByteOrderedPartitioner;
 import org.apache.cassandra.exceptions.FunctionExecutionException;
 import org.apache.cassandra.exceptions.InvalidRequestException;
+import org.apache.cassandra.schema.KeyspaceMetadata;
 import org.apache.cassandra.service.ClientState;
 import org.apache.cassandra.service.StorageService;
 import org.apache.cassandra.transport.Event;
@@ -2174,7 +2174,7 @@ public class UFTest extends CQLTester
   LANGUAGE JAVA\n +
   AS 'throw new RuntimeException();';);
 
-KSMetaData ksm = Schema.instance.getKSMetaData(KEYSPACE_PER_TEST);
+KeyspaceMetadata ksm = 
Schema.instance.getKSMetaData(KEYSPACE_PER_TEST);
 UDFunction f = (UDFunction) 
ksm.functions.get(parseFunctionName(fName)).iterator().next();
 
 UDFunction broken = UDFunction.createBrokenFunction(f.name(),
@@ -2185,7 +2185,7 @@ public class UFTest extends CQLTester
 java,
 f.body(),
 new 
InvalidRequestException(foo bar is broken));
-
Schema.instance.setKeyspaceDefinition(ksm.withSwapped(ksm.functions.without(f.name(),
 f.argTypes()).with(broken)));
+
Schema.instance.setKeyspaceMetadata(ksm.withSwapped(ksm.functions.without(f.name(),
 f.argTypes()).with(broken)));
 
 assertInvalidThrowMessage(foo bar is broken, 
InvalidRequestException.class,
   SELECT key,  + fName + (dval) FROM %s);

http://git-wip-us.apache.org/repos/asf/cassandra/blob/a89597da/test/unit/org/apache/cassandra/cql3/validation/operations/AggregationTest.java
--
diff --git 
a/test/unit/org/apache/cassandra/cql3/validation/operations/AggregationTest.java
 
b/test/unit/org/apache/cassandra/cql3/validation/operations/AggregationTest.java
index ac26368..6971b79 100644
--- 
a/test/unit/org/apache/cassandra/cql3/validation/operations/AggregationTest.java
+++ 
b/test/unit/org/apache/cassandra/cql3/validation/operations/AggregationTest.java
@@ -27,7 +27,6 @@ import org.apache.commons.lang3.time.DateUtils;
 import org.junit.Assert;
 import org.junit.Test;
 
-import org.apache.cassandra.config.KSMetaData;
 import org.apache.cassandra.config.Schema;
 import org.apache.cassandra.cql3.QueryProcessor;
 import org.apache.cassandra.cql3.functions.UDAggregate;
@@ -35,6 +34,7 @@ import org.apache.cassandra.cql3.CQLTester;
 import org.apache.cassandra.exceptions.FunctionExecutionException;
 import org.apache.cassandra.exceptions.InvalidRequestException;
 import org.apache.cassandra.serializers.Int32Serializer;
+import org.apache.cassandra.schema.KeyspaceMetadata;
 import org.apache.cassandra.service.ClientState;
 import org.apache.cassandra.transport.Event;
 import org.apache.cassandra.transport.messages.ResultMessage;
@@ -1015,7 +1015,7 @@ public class AggregationTest extends CQLTester
SFUNC  + shortFunctionName(fState) +   +
STYPE int );
 
-KSMetaData ksm = Schema.instance.getKSMetaData(keyspace());
+KeyspaceMetadata ksm = Schema.instance.getKSMetaData(keyspace());
 UDAggregate f = (UDAggregate) 
ksm.functions.get(parseFunctionName(a)).iterator().next();
 
 UDAggregate broken = UDAggregate.createBroken(f.name(),
@@ -1024,7 +1024,7 @@ public class AggregationTest extends CQLTester
   null,
   new 
InvalidRequestException(foo bar is broken));
 
-
Schema.instance.setKeyspaceDefinition(ksm.withSwapped(ksm.functions.without(f.name(),
 f.argTypes()).with(broken)));
+

[2/2] cassandra git commit: Rename and move config.KSMetaData to schema.KeyspaceMetadata

2015-07-01 Thread aleksey
Rename and move config.KSMetaData to schema.KeyspaceMetadata

patch by Aleksey Yeschenko; reviewed by Robert Stupp for CASSANDRA-9677


Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/a89597da
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/a89597da
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/a89597da

Branch: refs/heads/trunk
Commit: a89597da137ad55a5a1b5268ff414c3c1effce10
Parents: 31e3f61
Author: Aleksey Yeschenko alek...@apache.org
Authored: Wed Jul 1 17:18:12 2015 +0300
Committer: Aleksey Yeschenko alek...@apache.org
Committed: Wed Jul 1 18:55:10 2015 +0300

--
 .../org/apache/cassandra/auth/AuthKeyspace.java |   6 +-
 .../org/apache/cassandra/config/KSMetaData.java | 125 --
 .../org/apache/cassandra/config/Schema.java |  54 
 .../org/apache/cassandra/cql3/CQL3Type.java |   9 +-
 .../cassandra/cql3/functions/UDFunction.java|   4 +-
 .../cql3/statements/AlterKeyspaceStatement.java |   8 +-
 .../cql3/statements/AlterTypeStatement.java |   4 +-
 .../statements/CreateKeyspaceStatement.java |   4 +-
 .../cql3/statements/CreateTypeStatement.java|   5 +-
 .../cql3/statements/DropFunctionStatement.java  |   4 +-
 .../cql3/statements/DropIndexStatement.java |   4 +-
 .../cql3/statements/DropTypeStatement.java  |   5 +-
 src/java/org/apache/cassandra/db/Keyspace.java  |  13 +-
 .../org/apache/cassandra/db/SystemKeyspace.java |   6 +-
 .../cassandra/io/sstable/CQLSSTableWriter.java  |   9 +-
 .../repair/SystemDistributedKeyspace.java   |   6 +-
 .../cassandra/schema/KeyspaceMetadata.java  | 126 +++
 .../cassandra/schema/LegacySchemaTables.java|  44 +++
 .../cassandra/service/MigrationManager.java |  40 +++---
 .../cassandra/service/StorageService.java   |  15 +--
 .../cassandra/thrift/CassandraServer.java   |   3 +-
 .../cassandra/thrift/ThriftConversion.java  |   7 +-
 .../apache/cassandra/tracing/TraceKeyspace.java |   6 +-
 test/unit/org/apache/cassandra/MockSchema.java  |   4 +-
 .../unit/org/apache/cassandra/SchemaLoader.java |  35 +++---
 .../apache/cassandra/config/CFMetaDataTest.java |   3 +-
 .../config/DatabaseDescriptorTest.java  |  13 +-
 .../config/LegacySchemaTablesTest.java  |   3 +-
 .../cql3/validation/entities/UFTest.java|   6 +-
 .../validation/operations/AggregationTest.java  |   6 +-
 .../apache/cassandra/db/SystemKeyspaceTest.java |   2 +-
 .../db/compaction/AntiCompactionTest.java   |   6 -
 .../compaction/BlacklistingCompactionsTest.java |   5 -
 .../db/compaction/CompactionsPurgeTest.java |   2 -
 .../db/compaction/CompactionsTest.java  |   2 -
 .../io/sstable/SSTableRewriterTest.java |   6 -
 .../io/sstable/SSTableScannerTest.java  |   2 -
 .../cassandra/locator/SimpleStrategyTest.java   |   4 +-
 .../org/apache/cassandra/schema/DefsTest.java   |  23 ++--
 .../service/LeaveAndBootstrapTest.java  |   4 +-
 .../org/apache/cassandra/service/MoveTest.java  |   4 +-
 .../service/StorageServiceServerTest.java   |  34 ++---
 .../cassandra/triggers/TriggersSchemaTest.java  |  10 +-
 43 files changed, 334 insertions(+), 347 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/cassandra/blob/a89597da/src/java/org/apache/cassandra/auth/AuthKeyspace.java
--
diff --git a/src/java/org/apache/cassandra/auth/AuthKeyspace.java 
b/src/java/org/apache/cassandra/auth/AuthKeyspace.java
index 17a9f72..7ba083c 100644
--- a/src/java/org/apache/cassandra/auth/AuthKeyspace.java
+++ b/src/java/org/apache/cassandra/auth/AuthKeyspace.java
@@ -20,7 +20,7 @@ package org.apache.cassandra.auth;
 import java.util.concurrent.TimeUnit;
 
 import org.apache.cassandra.config.CFMetaData;
-import org.apache.cassandra.config.KSMetaData;
+import org.apache.cassandra.schema.KeyspaceMetadata;
 import org.apache.cassandra.schema.KeyspaceParams;
 import org.apache.cassandra.schema.Tables;
 
@@ -83,8 +83,8 @@ public final class AuthKeyspace
  .gcGraceSeconds((int) TimeUnit.DAYS.toSeconds(90));
 }
 
-public static KSMetaData definition()
+public static KeyspaceMetadata metadata()
 {
-return KSMetaData.create(NAME, KeyspaceParams.simple(1), 
Tables.of(Roles, RoleMembers, RolePermissions, ResourceRoleIndex));
+return KeyspaceMetadata.create(NAME, KeyspaceParams.simple(1), 
Tables.of(Roles, RoleMembers, RolePermissions, ResourceRoleIndex));
 }
 }

http://git-wip-us.apache.org/repos/asf/cassandra/blob/a89597da/src/java/org/apache/cassandra/config/KSMetaData.java
--
diff --git a/src/java/org/apache/cassandra/config/KSMetaData.java 

cassandra git commit: Rename class for DATE type in Java driver

2015-06-18 Thread snazy
Repository: cassandra
Updated Branches:
  refs/heads/cassandra-2.2 94be12c6f - a13399279


Rename class for DATE type in Java driver

patch by Robert Stupp; reviewed by Aleksey Yeschenko for CASSANDRA-9563


Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/a1339927
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/a1339927
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/a1339927

Branch: refs/heads/cassandra-2.2
Commit: a13399279b4e863779af938fb4f7da9abc4755d2
Parents: 94be12c
Author: Robert Stupp sn...@snazy.de
Authored: Thu Jun 18 18:02:45 2015 +0200
Committer: Robert Stupp sn...@snazy.de
Committed: Thu Jun 18 18:02:45 2015 +0200

--
 CHANGES.txt  |   1 +
 ...r-core-2.2.0-rc1-SNAPSHOT-20150603-shaded.jar | Bin 2155169 - 0 bytes
 ...r-core-2.2.0-rc2-SNAPSHOT-20150617-shaded.jar | Bin 0 - 2154972 bytes
 .../cassandra/hadoop/cql3/CqlRecordReader.java   |   6 +++---
 4 files changed, 4 insertions(+), 3 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/cassandra/blob/a1339927/CHANGES.txt
--
diff --git a/CHANGES.txt b/CHANGES.txt
index 3671af9..76a42ab 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -1,4 +1,5 @@
 2.2
+ * Rename class for DATE type in Java driver (CASSANDRA-9563)
  * Duplicate compilation of UDFs on coordinator (CASSANDRA-9475)
  * Fix connection leak in CqlRecordWriter (CASSANDRA-9576)
  * Mlockall before opening system sstables  remove boot_without_jna option 
(CASSANDRA-9573)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/a1339927/lib/cassandra-driver-core-2.2.0-rc1-SNAPSHOT-20150603-shaded.jar
--
diff --git a/lib/cassandra-driver-core-2.2.0-rc1-SNAPSHOT-20150603-shaded.jar 
b/lib/cassandra-driver-core-2.2.0-rc1-SNAPSHOT-20150603-shaded.jar
deleted file mode 100644
index d75a595..000
Binary files a/lib/cassandra-driver-core-2.2.0-rc1-SNAPSHOT-20150603-shaded.jar 
and /dev/null differ

http://git-wip-us.apache.org/repos/asf/cassandra/blob/a1339927/lib/cassandra-driver-core-2.2.0-rc2-SNAPSHOT-20150617-shaded.jar
--
diff --git a/lib/cassandra-driver-core-2.2.0-rc2-SNAPSHOT-20150617-shaded.jar 
b/lib/cassandra-driver-core-2.2.0-rc2-SNAPSHOT-20150617-shaded.jar
new file mode 100644
index 000..7d971df
Binary files /dev/null and 
b/lib/cassandra-driver-core-2.2.0-rc2-SNAPSHOT-20150617-shaded.jar differ

http://git-wip-us.apache.org/repos/asf/cassandra/blob/a1339927/src/java/org/apache/cassandra/hadoop/cql3/CqlRecordReader.java
--
diff --git a/src/java/org/apache/cassandra/hadoop/cql3/CqlRecordReader.java 
b/src/java/org/apache/cassandra/hadoop/cql3/CqlRecordReader.java
index 3e79ad1..6db851d 100644
--- a/src/java/org/apache/cassandra/hadoop/cql3/CqlRecordReader.java
+++ b/src/java/org/apache/cassandra/hadoop/cql3/CqlRecordReader.java
@@ -37,7 +37,7 @@ import org.slf4j.LoggerFactory;
 import com.datastax.driver.core.Cluster;
 import com.datastax.driver.core.ColumnDefinitions;
 import com.datastax.driver.core.ColumnMetadata;
-import com.datastax.driver.core.DateWithoutTime;
+import com.datastax.driver.core.LocalDate;
 import com.datastax.driver.core.Metadata;
 import com.datastax.driver.core.ResultSet;
 import com.datastax.driver.core.Row;
@@ -418,13 +418,13 @@ public class CqlRecordReader extends RecordReaderLong, 
Row
 }
 
 @Override
-public DateWithoutTime getDate(int i)
+public LocalDate getDate(int i)
 {
 return row.getDate(i);
 }
 
 @Override
-public DateWithoutTime getDate(String s)
+public LocalDate getDate(String s)
 {
 return row.getDate(s);
 }



[1/2] cassandra git commit: Rename class for DATE type in Java driver

2015-06-18 Thread snazy
Repository: cassandra
Updated Branches:
  refs/heads/trunk 4938ab5bf - 67baaef0f


Rename class for DATE type in Java driver

patch by Robert Stupp; reviewed by Aleksey Yeschenko for CASSANDRA-9563


Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/a1339927
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/a1339927
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/a1339927

Branch: refs/heads/trunk
Commit: a13399279b4e863779af938fb4f7da9abc4755d2
Parents: 94be12c
Author: Robert Stupp sn...@snazy.de
Authored: Thu Jun 18 18:02:45 2015 +0200
Committer: Robert Stupp sn...@snazy.de
Committed: Thu Jun 18 18:02:45 2015 +0200

--
 CHANGES.txt  |   1 +
 ...r-core-2.2.0-rc1-SNAPSHOT-20150603-shaded.jar | Bin 2155169 - 0 bytes
 ...r-core-2.2.0-rc2-SNAPSHOT-20150617-shaded.jar | Bin 0 - 2154972 bytes
 .../cassandra/hadoop/cql3/CqlRecordReader.java   |   6 +++---
 4 files changed, 4 insertions(+), 3 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/cassandra/blob/a1339927/CHANGES.txt
--
diff --git a/CHANGES.txt b/CHANGES.txt
index 3671af9..76a42ab 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -1,4 +1,5 @@
 2.2
+ * Rename class for DATE type in Java driver (CASSANDRA-9563)
  * Duplicate compilation of UDFs on coordinator (CASSANDRA-9475)
  * Fix connection leak in CqlRecordWriter (CASSANDRA-9576)
  * Mlockall before opening system sstables  remove boot_without_jna option 
(CASSANDRA-9573)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/a1339927/lib/cassandra-driver-core-2.2.0-rc1-SNAPSHOT-20150603-shaded.jar
--
diff --git a/lib/cassandra-driver-core-2.2.0-rc1-SNAPSHOT-20150603-shaded.jar 
b/lib/cassandra-driver-core-2.2.0-rc1-SNAPSHOT-20150603-shaded.jar
deleted file mode 100644
index d75a595..000
Binary files a/lib/cassandra-driver-core-2.2.0-rc1-SNAPSHOT-20150603-shaded.jar 
and /dev/null differ

http://git-wip-us.apache.org/repos/asf/cassandra/blob/a1339927/lib/cassandra-driver-core-2.2.0-rc2-SNAPSHOT-20150617-shaded.jar
--
diff --git a/lib/cassandra-driver-core-2.2.0-rc2-SNAPSHOT-20150617-shaded.jar 
b/lib/cassandra-driver-core-2.2.0-rc2-SNAPSHOT-20150617-shaded.jar
new file mode 100644
index 000..7d971df
Binary files /dev/null and 
b/lib/cassandra-driver-core-2.2.0-rc2-SNAPSHOT-20150617-shaded.jar differ

http://git-wip-us.apache.org/repos/asf/cassandra/blob/a1339927/src/java/org/apache/cassandra/hadoop/cql3/CqlRecordReader.java
--
diff --git a/src/java/org/apache/cassandra/hadoop/cql3/CqlRecordReader.java 
b/src/java/org/apache/cassandra/hadoop/cql3/CqlRecordReader.java
index 3e79ad1..6db851d 100644
--- a/src/java/org/apache/cassandra/hadoop/cql3/CqlRecordReader.java
+++ b/src/java/org/apache/cassandra/hadoop/cql3/CqlRecordReader.java
@@ -37,7 +37,7 @@ import org.slf4j.LoggerFactory;
 import com.datastax.driver.core.Cluster;
 import com.datastax.driver.core.ColumnDefinitions;
 import com.datastax.driver.core.ColumnMetadata;
-import com.datastax.driver.core.DateWithoutTime;
+import com.datastax.driver.core.LocalDate;
 import com.datastax.driver.core.Metadata;
 import com.datastax.driver.core.ResultSet;
 import com.datastax.driver.core.Row;
@@ -418,13 +418,13 @@ public class CqlRecordReader extends RecordReaderLong, 
Row
 }
 
 @Override
-public DateWithoutTime getDate(int i)
+public LocalDate getDate(int i)
 {
 return row.getDate(i);
 }
 
 @Override
-public DateWithoutTime getDate(String s)
+public LocalDate getDate(String s)
 {
 return row.getDate(s);
 }



cassandra git commit: rename

2015-04-17 Thread jbellis
Repository: cassandra
Updated Branches:
  refs/heads/trunk e983956c2 - 11dfc0253


rename


Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/11dfc025
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/11dfc025
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/11dfc025

Branch: refs/heads/trunk
Commit: 11dfc025305113f5cfeac4151fb72cee2e6f83f9
Parents: e983956
Author: Jonathan Ellis jbel...@apache.org
Authored: Fri Apr 17 12:48:28 2015 -0500
Committer: Jonathan Ellis jbel...@apache.org
Committed: Fri Apr 17 12:48:28 2015 -0500

--
 .../apache/cassandra/config/CFMetaDataTest.java | 150 -
 .../config/LegacySchemaTablesTest.java  | 150 +
 .../org/apache/cassandra/schema/DefsTest.java   | 568 +++
 .../schema/LegacySchemaTablesTest.java  | 568 ---
 4 files changed, 718 insertions(+), 718 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/cassandra/blob/11dfc025/test/unit/org/apache/cassandra/config/CFMetaDataTest.java
--
diff --git a/test/unit/org/apache/cassandra/config/CFMetaDataTest.java 
b/test/unit/org/apache/cassandra/config/CFMetaDataTest.java
deleted file mode 100644
index 5fed5be..000
--- a/test/unit/org/apache/cassandra/config/CFMetaDataTest.java
+++ /dev/null
@@ -1,150 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * License); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * AS IS BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.cassandra.config;
-
-import java.util.ArrayList;
-import java.util.List;
-import java.util.HashMap;
-import java.util.HashSet;
-
-import org.apache.cassandra.SchemaLoader;
-import org.apache.cassandra.db.*;
-import org.apache.cassandra.db.marshal.AsciiType;
-import org.apache.cassandra.db.marshal.UTF8Type;
-import org.apache.cassandra.exceptions.ConfigurationException;
-import org.apache.cassandra.io.compress.*;
-import org.apache.cassandra.locator.SimpleStrategy;
-import org.apache.cassandra.schema.LegacySchemaTables;
-import org.apache.cassandra.service.StorageService;
-import org.apache.cassandra.thrift.CfDef;
-import org.apache.cassandra.thrift.ColumnDef;
-import org.apache.cassandra.thrift.IndexType;
-import org.apache.cassandra.thrift.ThriftConversion;
-import org.apache.cassandra.utils.ByteBufferUtil;
-import org.apache.cassandra.utils.FBUtilities;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-
-import static org.junit.Assert.assertEquals;
-
-public class CFMetaDataTest
-{
-private static final String KEYSPACE1 = CFMetaDataTest1;
-private static final String CF_STANDARD1 = Standard1;
-
-private static ListColumnDef columnDefs = new ArrayListColumnDef();
-
-static
-{
-columnDefs.add(new ColumnDef(ByteBufferUtil.bytes(col1), 
AsciiType.class.getCanonicalName())
-.setIndex_name(col1Index)
-.setIndex_type(IndexType.KEYS));
-
-columnDefs.add(new ColumnDef(ByteBufferUtil.bytes(col2), 
UTF8Type.class.getCanonicalName())
-.setIndex_name(col2Index)
-.setIndex_type(IndexType.KEYS));
-}
-
-@BeforeClass
-public static void defineSchema() throws ConfigurationException
-{
-SchemaLoader.prepareServer();
-SchemaLoader.createKeyspace(KEYSPACE1,
-SimpleStrategy.class,
-KSMetaData.optsWithRF(1),
-SchemaLoader.standardCFMD(KEYSPACE1, 
CF_STANDARD1));
-}
-
-@Test
-public void testThriftConversion() throws Exception
-{
-CfDef cfDef = new 
CfDef().setDefault_validation_class(AsciiType.class.getCanonicalName())
- .setComment(Test comment)
- .setColumn_metadata(columnDefs)
- .setKeyspace(KEYSPACE1)
- .setName(CF_STANDARD1);
-
-// convert Thrift to CFMetaData
-

cassandra git commit: rename

2015-02-17 Thread jbellis
Repository: cassandra
Updated Branches:
  refs/heads/trunk f6879b205 - 48563e0be


rename


Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/48563e0b
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/48563e0b
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/48563e0b

Branch: refs/heads/trunk
Commit: 48563e0be186dbeca2933f874d0030d7671d02ab
Parents: f6879b2
Author: Jonathan Ellis jbel...@apache.org
Authored: Tue Feb 17 16:55:06 2015 -0600
Committer: Jonathan Ellis jbel...@apache.org
Committed: Tue Feb 17 16:55:06 2015 -0600

--
 src/java/org/apache/cassandra/gms/Gossiper.java | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/cassandra/blob/48563e0b/src/java/org/apache/cassandra/gms/Gossiper.java
--
diff --git a/src/java/org/apache/cassandra/gms/Gossiper.java 
b/src/java/org/apache/cassandra/gms/Gossiper.java
index c34793c..4584044 100644
--- a/src/java/org/apache/cassandra/gms/Gossiper.java
+++ b/src/java/org/apache/cassandra/gms/Gossiper.java
@@ -152,7 +152,7 @@ public class Gossiper implements 
IFailureDetectionEventListener, GossiperMBean
 boolean gossipedToSeed = doGossipToLiveMember(message);
 
 /* Gossip to some unreachable member with some probability 
to check if he is back up */
-doGossipToUnreachableMember(message);
+maybeGossipToUnreachableMember(message);
 
 /* Gossip to a seed if we did not do so above, or we have 
seen less nodes
than there are seeds.  This prevents partitions where 
each group of nodes
@@ -615,7 +615,7 @@ public class Gossiper implements 
IFailureDetectionEventListener, GossiperMBean
 }
 
 /* Sends a Gossip message to an unreachable member */
-private void doGossipToUnreachableMember(MessageOutGossipDigestSyn 
message)
+private void maybeGossipToUnreachableMember(MessageOutGossipDigestSyn 
message)
 {
 double liveEndpointCount = liveEndpoints.size();
 double unreachableEndpointCount = unreachableEndpoints.size();