You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by st...@apache.org on 2016/07/20 02:03:04 UTC

[01/10] cassandra git commit: Fixed cqlshlib.test.remove_test_db

Repository: cassandra
Updated Branches:
  refs/heads/cassandra-2.2 f0d1d75eb -> e8186fe39
  refs/heads/cassandra-3.0 0297cbe97 -> dce453741
  refs/heads/cassandra-3.9 4bd4be867 -> 8df6d4d4c
  refs/heads/trunk cc582855e -> f129dea86


Fixed cqlshlib.test.remove_test_db

patch by Stefania Alborghetti; reviewed by Philip Thompson for CASSANDRA-12214


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

Branch: refs/heads/cassandra-2.2
Commit: e8186fe390073f5d7ea11057c5bc842db86d95d2
Parents: f0d1d75
Author: Stefania Alborghetti <st...@datastax.com>
Authored: Tue Jul 19 11:15:46 2016 +0800
Committer: Stefania Alborghetti <st...@datastax.com>
Committed: Wed Jul 20 09:54:53 2016 +0800

----------------------------------------------------------------------
 CHANGES.txt                              |  1 +
 pylib/cqlshlib/test/__init__.py          |  6 +++---
 pylib/cqlshlib/test/cassconnect.py       | 22 +++++++++++-----------
 pylib/cqlshlib/test/test_cqlsh_output.py | 14 +++++++-------
 4 files changed, 22 insertions(+), 21 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/e8186fe3/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index 837c3fb..ffd92b5 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -1,4 +1,5 @@
 2.2.8
+ * Fixed cqlshlib.test.remove_test_db (CASSANDRA-12214)
  * Synchronize ThriftServer::stop() (CASSANDRA-12105)
  * Use dedicated thread for JMX notifications (CASSANDRA-12146)
  * NPE when trying to remove purgable tombstones from result (CASSANDRA-12143)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/e8186fe3/pylib/cqlshlib/test/__init__.py
----------------------------------------------------------------------
diff --git a/pylib/cqlshlib/test/__init__.py b/pylib/cqlshlib/test/__init__.py
index 31f66f3..ba8f373 100644
--- a/pylib/cqlshlib/test/__init__.py
+++ b/pylib/cqlshlib/test/__init__.py
@@ -14,7 +14,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-from .cassconnect import create_test_db, remove_test_db
+from .cassconnect import create_db, remove_db
 
-setUp = create_test_db
-tearDown = remove_test_db
+setUp = create_db
+tearDown = remove_db

http://git-wip-us.apache.org/repos/asf/cassandra/blob/e8186fe3/pylib/cqlshlib/test/cassconnect.py
----------------------------------------------------------------------
diff --git a/pylib/cqlshlib/test/cassconnect.py b/pylib/cqlshlib/test/cassconnect.py
index 94910a6..4a1311e 100644
--- a/pylib/cqlshlib/test/cassconnect.py
+++ b/pylib/cqlshlib/test/cassconnect.py
@@ -37,15 +37,15 @@ def get_cassandra_cursor(cql_version=cqlsh.DEFAULT_CQLVER):
 
 TEST_KEYSPACES_CREATED = []
 
-def get_test_keyspace():
-    return TEST_KEYSPACES_CREATED[-1]
+def get_keyspace():
+    return None if len(TEST_KEYSPACES_CREATED) == 0 else TEST_KEYSPACES_CREATED[-1]
 
-def make_test_ks_name():
+def make_ks_name():
     # abuse mktemp to get a quick random-ish name
     return os.path.basename(tempfile.mktemp(prefix='CqlshTests_'))
 
-def create_test_keyspace(cursor):
-    ksname = make_test_ks_name()
+def create_keyspace(cursor):
+    ksname = make_ks_name()
     qksname = quote_name(ksname)
     cursor.execute('''
         CREATE KEYSPACE %s WITH replication =
@@ -72,13 +72,13 @@ def execute_cql_file(cursor, fname):
     with open(fname) as f:
         return execute_cql_commands(cursor, f.read())
 
-def create_test_db():
+def create_db():
     with cassandra_cursor(ks=None) as c:
-        k = create_test_keyspace(c)
+        k = create_keyspace(c)
         execute_cql_file(c, test_keyspace_init)
     return k
 
-def remove_test_db():
+def remove_db():
     with cassandra_cursor(ks=None) as c:
         c.execute('DROP KEYSPACE %s' % quote_name(TEST_KEYSPACES_CREATED.pop(-1)))
 
@@ -112,7 +112,7 @@ def cassandra_cursor(cql_version=None, ks=''):
     """
 
     if ks == '':
-        ks = get_test_keyspace()
+        ks = get_keyspace()
     conn = get_cassandra_connection(cql_version=cql_version)
     try:
         c = conn.connect(ks)
@@ -131,10 +131,10 @@ def testrun_cqlsh(keyspace=DEFAULTVAL, **kwargs):
     # use a positive default sentinel so that keyspace=None can be used
     # to override the default behavior
     if keyspace is DEFAULTVAL:
-        keyspace = get_test_keyspace()
+        keyspace = get_keyspace()
     return run_cqlsh(keyspace=keyspace, **kwargs)
 
 def testcall_cqlsh(keyspace=None, **kwargs):
     if keyspace is None:
-        keyspace = get_test_keyspace()
+        keyspace = get_keyspace()
     return call_cqlsh(keyspace=keyspace, **kwargs)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/e8186fe3/pylib/cqlshlib/test/test_cqlsh_output.py
----------------------------------------------------------------------
diff --git a/pylib/cqlshlib/test/test_cqlsh_output.py b/pylib/cqlshlib/test/test_cqlsh_output.py
index fdc562f..60699f3 100644
--- a/pylib/cqlshlib/test/test_cqlsh_output.py
+++ b/pylib/cqlshlib/test/test_cqlsh_output.py
@@ -23,7 +23,7 @@ import re
 from itertools import izip
 from .basecase import (BaseTestCase, cqlshlog, dedent, at_a_time, cqlsh,
                        TEST_HOST, TEST_PORT)
-from .cassconnect import (get_test_keyspace, testrun_cqlsh, testcall_cqlsh,
+from .cassconnect import (get_keyspace, testrun_cqlsh, testcall_cqlsh,
                           cassandra_cursor, split_cql_commands, quote_name)
 from .ansi_colors import (ColoredText, lookup_colorcode, lookup_colorname,
                           lookup_colorletter, ansi_seq)
@@ -534,10 +534,10 @@ class TestCqlshOutput(BaseTestCase):
             output = c.read_to_next_prompt().replace('\r\n', '\n')
             self.assertTrue(output.endswith('cqlsh> '))
 
-            cmd = "USE \"%s\";\n" % get_test_keyspace().replace('"', '""')
+            cmd = "USE \"%s\";\n" % get_keyspace().replace('"', '""')
             c.send(cmd)
             output = c.read_to_next_prompt().replace('\r\n', '\n')
-            self.assertTrue(output.endswith('cqlsh:%s> ' % (get_test_keyspace())))
+            self.assertTrue(output.endswith('cqlsh:%s> ' % (get_keyspace())))
 
             c.send('use system;\n')
             output = c.read_to_next_prompt().replace('\r\n', '\n')
@@ -561,7 +561,7 @@ class TestCqlshOutput(BaseTestCase):
     def test_describe_keyspace_output(self):
         fullcqlver = cqlsh.DEFAULT_CQLVER
         with testrun_cqlsh(tty=True, cqlver=fullcqlver) as c:
-            ks = get_test_keyspace()
+            ks = get_keyspace()
             qks = quote_name(ks)
             for cmd in ('describe keyspace', 'desc keyspace'):
                 for givename in ('system', '', qks):
@@ -632,7 +632,7 @@ class TestCqlshOutput(BaseTestCase):
                 AND read_repair_chance = 0.0
                 AND speculative_retry = '99.0PERCENTILE';
 
-        """ % quote_name(get_test_keyspace()))
+        """ % quote_name(get_keyspace()))
 
         with testrun_cqlsh(tty=True, cqlver=cqlsh.DEFAULT_CQLVER) as c:
             for cmdword in ('describe table', 'desc columnfamily'):
@@ -650,7 +650,7 @@ class TestCqlshOutput(BaseTestCase):
             \n
         '''
 
-        ks = get_test_keyspace()
+        ks = get_keyspace()
 
         with testrun_cqlsh(tty=True, keyspace=None, cqlver=cqlsh.DEFAULT_CQLVER) as c:
 
@@ -711,7 +711,7 @@ class TestCqlshOutput(BaseTestCase):
                 self.assertNoHasColors(output)
                 self.assertRegexpMatches(output, output_re + '$')
 
-            c.send('USE %s;\n' % quote_name(get_test_keyspace()))
+            c.send('USE %s;\n' % quote_name(get_keyspace()))
             c.read_to_next_prompt()
 
             for semicolon in ('', ';'):


[07/10] cassandra git commit: Merge branch 'cassandra-2.2' into cassandra-3.0

Posted by st...@apache.org.
Merge branch 'cassandra-2.2' into cassandra-3.0


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

Branch: refs/heads/trunk
Commit: dce4537410d66a3cbd24b2e581737b849e011917
Parents: 0297cbe e8186fe
Author: Stefania Alborghetti <st...@datastax.com>
Authored: Wed Jul 20 09:56:12 2016 +0800
Committer: Stefania Alborghetti <st...@datastax.com>
Committed: Wed Jul 20 09:56:12 2016 +0800

----------------------------------------------------------------------
 CHANGES.txt                              |  1 +
 pylib/cqlshlib/test/__init__.py          |  6 +++---
 pylib/cqlshlib/test/cassconnect.py       | 22 +++++++++++-----------
 pylib/cqlshlib/test/test_cqlsh_output.py | 14 +++++++-------
 4 files changed, 22 insertions(+), 21 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/dce45374/CHANGES.txt
----------------------------------------------------------------------
diff --cc CHANGES.txt
index f205e0b,ffd92b5..739c095
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@@ -1,21 -1,8 +1,22 @@@
 -2.2.8
 +3.0.9
 + * Fix problem with undeleteable rows on upgrade to new sstable format (CASSANDRA-12144)
 + * Fix paging logic for deleted partitions with static columns (CASSANDRA-12107)
 + * Wait until the message is being send to decide which serializer must be used (CASSANDRA-11393)
 + * Fix migration of static thrift column names with non-text comparators (CASSANDRA-12147)
 + * Fix upgrading sparse tables that are incorrectly marked as dense (CASSANDRA-11315)
 + * Fix reverse queries ignoring range tombstones (CASSANDRA-11733)
 + * Avoid potential race when rebuilding CFMetaData (CASSANDRA-12098)
 + * Avoid missing sstables when getting the canonical sstables (CASSANDRA-11996)
 + * Always select the live sstables when getting sstables in bounds (CASSANDRA-11944)
 + * Fix column ordering of results with static columns for Thrift requests in
 +   a mixed 2.x/3.x cluster, also fix potential non-resolved duplication of
 +   those static columns in query results (CASSANDRA-12123)
 + * Avoid digest mismatch with empty but static rows (CASSANDRA-12090)
 + * Fix EOF exception when altering column type (CASSANDRA-11820)
 +Merged from 2.2:
+  * Fixed cqlshlib.test.remove_test_db (CASSANDRA-12214)
   * Synchronize ThriftServer::stop() (CASSANDRA-12105)
   * Use dedicated thread for JMX notifications (CASSANDRA-12146)
 - * NPE when trying to remove purgable tombstones from result (CASSANDRA-12143)
   * Improve streaming synchronization and fault tolerance (CASSANDRA-11414)
   * MemoryUtil.getShort() should return an unsigned short also for architectures not supporting unaligned memory accesses (CASSANDRA-11973)
  Merged from 2.1:

http://git-wip-us.apache.org/repos/asf/cassandra/blob/dce45374/pylib/cqlshlib/test/test_cqlsh_output.py
----------------------------------------------------------------------
diff --cc pylib/cqlshlib/test/test_cqlsh_output.py
index f867312,60699f3..85ce626
--- a/pylib/cqlshlib/test/test_cqlsh_output.py
+++ b/pylib/cqlshlib/test/test_cqlsh_output.py
@@@ -631,9 -630,9 +631,9 @@@ class TestCqlshOutput(BaseTestCase)
                  AND memtable_flush_period_in_ms = 0
                  AND min_index_interval = 128
                  AND read_repair_chance = 0.0
 -                AND speculative_retry = '99.0PERCENTILE';
 +                AND speculative_retry = '99PERCENTILE';
  
-         """ % quote_name(get_test_keyspace()))
+         """ % quote_name(get_keyspace()))
  
          with testrun_cqlsh(tty=True, cqlver=cqlsh.DEFAULT_CQLVER) as c:
              for cmdword in ('describe table', 'desc columnfamily'):


[08/10] cassandra git commit: Merge branch 'cassandra-3.0' into cassandra-3.9

Posted by st...@apache.org.
Merge branch 'cassandra-3.0' into cassandra-3.9


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

Branch: refs/heads/cassandra-3.9
Commit: 8df6d4d4c60f865a09a93ff678ea5f6417465c29
Parents: 4bd4be8 dce4537
Author: Stefania Alborghetti <st...@datastax.com>
Authored: Wed Jul 20 09:58:14 2016 +0800
Committer: Stefania Alborghetti <st...@datastax.com>
Committed: Wed Jul 20 09:58:40 2016 +0800

----------------------------------------------------------------------
 CHANGES.txt                              |  2 ++
 pylib/cqlshlib/test/__init__.py          |  6 +++---
 pylib/cqlshlib/test/cassconnect.py       | 22 +++++++++++-----------
 pylib/cqlshlib/test/test_cqlsh_output.py | 14 +++++++-------
 4 files changed, 23 insertions(+), 21 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/8df6d4d4/CHANGES.txt
----------------------------------------------------------------------
diff --cc CHANGES.txt
index 780ea96,739c095..dac46ab
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@@ -1,36 -1,5 +1,38 @@@
 -3.0.9
 +3.9
 +Merged from 3.0:
   * Fix problem with undeleteable rows on upgrade to new sstable format (CASSANDRA-12144)
++Merged from 2.2:
++ * Fixed cqlshlib.test.remove_test_db (CASSANDRA-12214)
 +
 +3.8
 + * Fix hdr logging for single operation workloads (CASSANDRA-12145)
 + * Fix SASI PREFIX search in CONTAINS mode with partial terms (CASSANDRA-12073)
 + * Increase size of flushExecutor thread pool (CASSANDRA-12071)
 + * Partial revert of CASSANDRA-11971, cannot recycle buffer in SP.sendMessagesToNonlocalDC (CASSANDRA-11950)
 + * Upgrade netty to 4.0.39 (CASSANDRA-12032, CASSANDRA-12034)
 + * Improve details in compaction log message (CASSANDRA-12080)
 + * Allow unset values in CQLSSTableWriter (CASSANDRA-11911)
 + * Chunk cache to request compressor-compatible buffers if pool space is exhausted (CASSANDRA-11993)
 + * Remove DatabaseDescriptor dependencies from SequentialWriter (CASSANDRA-11579)
 + * Move skip_stop_words filter before stemming (CASSANDRA-12078)
 + * Support seek() in EncryptedFileSegmentInputStream (CASSANDRA-11957)
 + * SSTable tools mishandling LocalPartitioner (CASSANDRA-12002)
 + * When SEPWorker assigned work, set thread name to match pool (CASSANDRA-11966)
 + * Add cross-DC latency metrics (CASSANDRA-11596)
 + * Allow terms in selection clause (CASSANDRA-10783)
 + * Add bind variables to trace (CASSANDRA-11719)
 + * Switch counter shards' clock to timestamps (CASSANDRA-9811)
 + * Introduce HdrHistogram and response/service/wait separation to stress tool (CASSANDRA-11853)
 + * entry-weighers in QueryProcessor should respect partitionKeyBindIndexes field (CASSANDRA-11718)
 + * Support older ant versions (CASSANDRA-11807)
 + * Estimate compressed on disk size when deciding if sstable size limit reached (CASSANDRA-11623)
 + * cassandra-stress profiles should support case sensitive schemas (CASSANDRA-11546)
 + * Remove DatabaseDescriptor dependency from FileUtils (CASSANDRA-11578)
 + * Faster streaming (CASSANDRA-9766)
 + * Add prepared query parameter to trace for "Execute CQL3 prepared query" session (CASSANDRA-11425)
 + * Add repaired percentage metric (CASSANDRA-11503)
 + * Add Change-Data-Capture (CASSANDRA-8844)
 +Merged from 3.0:
   * Fix paging logic for deleted partitions with static columns (CASSANDRA-12107)
   * Wait until the message is being send to decide which serializer must be used (CASSANDRA-11393)
   * Fix migration of static thrift column names with non-text comparators (CASSANDRA-12147)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/8df6d4d4/pylib/cqlshlib/test/test_cqlsh_output.py
----------------------------------------------------------------------


[06/10] cassandra git commit: Merge branch 'cassandra-2.2' into cassandra-3.0

Posted by st...@apache.org.
Merge branch 'cassandra-2.2' into cassandra-3.0


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

Branch: refs/heads/cassandra-3.0
Commit: dce4537410d66a3cbd24b2e581737b849e011917
Parents: 0297cbe e8186fe
Author: Stefania Alborghetti <st...@datastax.com>
Authored: Wed Jul 20 09:56:12 2016 +0800
Committer: Stefania Alborghetti <st...@datastax.com>
Committed: Wed Jul 20 09:56:12 2016 +0800

----------------------------------------------------------------------
 CHANGES.txt                              |  1 +
 pylib/cqlshlib/test/__init__.py          |  6 +++---
 pylib/cqlshlib/test/cassconnect.py       | 22 +++++++++++-----------
 pylib/cqlshlib/test/test_cqlsh_output.py | 14 +++++++-------
 4 files changed, 22 insertions(+), 21 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/dce45374/CHANGES.txt
----------------------------------------------------------------------
diff --cc CHANGES.txt
index f205e0b,ffd92b5..739c095
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@@ -1,21 -1,8 +1,22 @@@
 -2.2.8
 +3.0.9
 + * Fix problem with undeleteable rows on upgrade to new sstable format (CASSANDRA-12144)
 + * Fix paging logic for deleted partitions with static columns (CASSANDRA-12107)
 + * Wait until the message is being send to decide which serializer must be used (CASSANDRA-11393)
 + * Fix migration of static thrift column names with non-text comparators (CASSANDRA-12147)
 + * Fix upgrading sparse tables that are incorrectly marked as dense (CASSANDRA-11315)
 + * Fix reverse queries ignoring range tombstones (CASSANDRA-11733)
 + * Avoid potential race when rebuilding CFMetaData (CASSANDRA-12098)
 + * Avoid missing sstables when getting the canonical sstables (CASSANDRA-11996)
 + * Always select the live sstables when getting sstables in bounds (CASSANDRA-11944)
 + * Fix column ordering of results with static columns for Thrift requests in
 +   a mixed 2.x/3.x cluster, also fix potential non-resolved duplication of
 +   those static columns in query results (CASSANDRA-12123)
 + * Avoid digest mismatch with empty but static rows (CASSANDRA-12090)
 + * Fix EOF exception when altering column type (CASSANDRA-11820)
 +Merged from 2.2:
+  * Fixed cqlshlib.test.remove_test_db (CASSANDRA-12214)
   * Synchronize ThriftServer::stop() (CASSANDRA-12105)
   * Use dedicated thread for JMX notifications (CASSANDRA-12146)
 - * NPE when trying to remove purgable tombstones from result (CASSANDRA-12143)
   * Improve streaming synchronization and fault tolerance (CASSANDRA-11414)
   * MemoryUtil.getShort() should return an unsigned short also for architectures not supporting unaligned memory accesses (CASSANDRA-11973)
  Merged from 2.1:

http://git-wip-us.apache.org/repos/asf/cassandra/blob/dce45374/pylib/cqlshlib/test/test_cqlsh_output.py
----------------------------------------------------------------------
diff --cc pylib/cqlshlib/test/test_cqlsh_output.py
index f867312,60699f3..85ce626
--- a/pylib/cqlshlib/test/test_cqlsh_output.py
+++ b/pylib/cqlshlib/test/test_cqlsh_output.py
@@@ -631,9 -630,9 +631,9 @@@ class TestCqlshOutput(BaseTestCase)
                  AND memtable_flush_period_in_ms = 0
                  AND min_index_interval = 128
                  AND read_repair_chance = 0.0
 -                AND speculative_retry = '99.0PERCENTILE';
 +                AND speculative_retry = '99PERCENTILE';
  
-         """ % quote_name(get_test_keyspace()))
+         """ % quote_name(get_keyspace()))
  
          with testrun_cqlsh(tty=True, cqlver=cqlsh.DEFAULT_CQLVER) as c:
              for cmdword in ('describe table', 'desc columnfamily'):


[04/10] cassandra git commit: Fixed cqlshlib.test.remove_test_db

Posted by st...@apache.org.
Fixed cqlshlib.test.remove_test_db

patch by Stefania Alborghetti; reviewed by Philip Thompson for CASSANDRA-12214


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

Branch: refs/heads/trunk
Commit: e8186fe390073f5d7ea11057c5bc842db86d95d2
Parents: f0d1d75
Author: Stefania Alborghetti <st...@datastax.com>
Authored: Tue Jul 19 11:15:46 2016 +0800
Committer: Stefania Alborghetti <st...@datastax.com>
Committed: Wed Jul 20 09:54:53 2016 +0800

----------------------------------------------------------------------
 CHANGES.txt                              |  1 +
 pylib/cqlshlib/test/__init__.py          |  6 +++---
 pylib/cqlshlib/test/cassconnect.py       | 22 +++++++++++-----------
 pylib/cqlshlib/test/test_cqlsh_output.py | 14 +++++++-------
 4 files changed, 22 insertions(+), 21 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/e8186fe3/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index 837c3fb..ffd92b5 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -1,4 +1,5 @@
 2.2.8
+ * Fixed cqlshlib.test.remove_test_db (CASSANDRA-12214)
  * Synchronize ThriftServer::stop() (CASSANDRA-12105)
  * Use dedicated thread for JMX notifications (CASSANDRA-12146)
  * NPE when trying to remove purgable tombstones from result (CASSANDRA-12143)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/e8186fe3/pylib/cqlshlib/test/__init__.py
----------------------------------------------------------------------
diff --git a/pylib/cqlshlib/test/__init__.py b/pylib/cqlshlib/test/__init__.py
index 31f66f3..ba8f373 100644
--- a/pylib/cqlshlib/test/__init__.py
+++ b/pylib/cqlshlib/test/__init__.py
@@ -14,7 +14,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-from .cassconnect import create_test_db, remove_test_db
+from .cassconnect import create_db, remove_db
 
-setUp = create_test_db
-tearDown = remove_test_db
+setUp = create_db
+tearDown = remove_db

http://git-wip-us.apache.org/repos/asf/cassandra/blob/e8186fe3/pylib/cqlshlib/test/cassconnect.py
----------------------------------------------------------------------
diff --git a/pylib/cqlshlib/test/cassconnect.py b/pylib/cqlshlib/test/cassconnect.py
index 94910a6..4a1311e 100644
--- a/pylib/cqlshlib/test/cassconnect.py
+++ b/pylib/cqlshlib/test/cassconnect.py
@@ -37,15 +37,15 @@ def get_cassandra_cursor(cql_version=cqlsh.DEFAULT_CQLVER):
 
 TEST_KEYSPACES_CREATED = []
 
-def get_test_keyspace():
-    return TEST_KEYSPACES_CREATED[-1]
+def get_keyspace():
+    return None if len(TEST_KEYSPACES_CREATED) == 0 else TEST_KEYSPACES_CREATED[-1]
 
-def make_test_ks_name():
+def make_ks_name():
     # abuse mktemp to get a quick random-ish name
     return os.path.basename(tempfile.mktemp(prefix='CqlshTests_'))
 
-def create_test_keyspace(cursor):
-    ksname = make_test_ks_name()
+def create_keyspace(cursor):
+    ksname = make_ks_name()
     qksname = quote_name(ksname)
     cursor.execute('''
         CREATE KEYSPACE %s WITH replication =
@@ -72,13 +72,13 @@ def execute_cql_file(cursor, fname):
     with open(fname) as f:
         return execute_cql_commands(cursor, f.read())
 
-def create_test_db():
+def create_db():
     with cassandra_cursor(ks=None) as c:
-        k = create_test_keyspace(c)
+        k = create_keyspace(c)
         execute_cql_file(c, test_keyspace_init)
     return k
 
-def remove_test_db():
+def remove_db():
     with cassandra_cursor(ks=None) as c:
         c.execute('DROP KEYSPACE %s' % quote_name(TEST_KEYSPACES_CREATED.pop(-1)))
 
@@ -112,7 +112,7 @@ def cassandra_cursor(cql_version=None, ks=''):
     """
 
     if ks == '':
-        ks = get_test_keyspace()
+        ks = get_keyspace()
     conn = get_cassandra_connection(cql_version=cql_version)
     try:
         c = conn.connect(ks)
@@ -131,10 +131,10 @@ def testrun_cqlsh(keyspace=DEFAULTVAL, **kwargs):
     # use a positive default sentinel so that keyspace=None can be used
     # to override the default behavior
     if keyspace is DEFAULTVAL:
-        keyspace = get_test_keyspace()
+        keyspace = get_keyspace()
     return run_cqlsh(keyspace=keyspace, **kwargs)
 
 def testcall_cqlsh(keyspace=None, **kwargs):
     if keyspace is None:
-        keyspace = get_test_keyspace()
+        keyspace = get_keyspace()
     return call_cqlsh(keyspace=keyspace, **kwargs)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/e8186fe3/pylib/cqlshlib/test/test_cqlsh_output.py
----------------------------------------------------------------------
diff --git a/pylib/cqlshlib/test/test_cqlsh_output.py b/pylib/cqlshlib/test/test_cqlsh_output.py
index fdc562f..60699f3 100644
--- a/pylib/cqlshlib/test/test_cqlsh_output.py
+++ b/pylib/cqlshlib/test/test_cqlsh_output.py
@@ -23,7 +23,7 @@ import re
 from itertools import izip
 from .basecase import (BaseTestCase, cqlshlog, dedent, at_a_time, cqlsh,
                        TEST_HOST, TEST_PORT)
-from .cassconnect import (get_test_keyspace, testrun_cqlsh, testcall_cqlsh,
+from .cassconnect import (get_keyspace, testrun_cqlsh, testcall_cqlsh,
                           cassandra_cursor, split_cql_commands, quote_name)
 from .ansi_colors import (ColoredText, lookup_colorcode, lookup_colorname,
                           lookup_colorletter, ansi_seq)
@@ -534,10 +534,10 @@ class TestCqlshOutput(BaseTestCase):
             output = c.read_to_next_prompt().replace('\r\n', '\n')
             self.assertTrue(output.endswith('cqlsh> '))
 
-            cmd = "USE \"%s\";\n" % get_test_keyspace().replace('"', '""')
+            cmd = "USE \"%s\";\n" % get_keyspace().replace('"', '""')
             c.send(cmd)
             output = c.read_to_next_prompt().replace('\r\n', '\n')
-            self.assertTrue(output.endswith('cqlsh:%s> ' % (get_test_keyspace())))
+            self.assertTrue(output.endswith('cqlsh:%s> ' % (get_keyspace())))
 
             c.send('use system;\n')
             output = c.read_to_next_prompt().replace('\r\n', '\n')
@@ -561,7 +561,7 @@ class TestCqlshOutput(BaseTestCase):
     def test_describe_keyspace_output(self):
         fullcqlver = cqlsh.DEFAULT_CQLVER
         with testrun_cqlsh(tty=True, cqlver=fullcqlver) as c:
-            ks = get_test_keyspace()
+            ks = get_keyspace()
             qks = quote_name(ks)
             for cmd in ('describe keyspace', 'desc keyspace'):
                 for givename in ('system', '', qks):
@@ -632,7 +632,7 @@ class TestCqlshOutput(BaseTestCase):
                 AND read_repair_chance = 0.0
                 AND speculative_retry = '99.0PERCENTILE';
 
-        """ % quote_name(get_test_keyspace()))
+        """ % quote_name(get_keyspace()))
 
         with testrun_cqlsh(tty=True, cqlver=cqlsh.DEFAULT_CQLVER) as c:
             for cmdword in ('describe table', 'desc columnfamily'):
@@ -650,7 +650,7 @@ class TestCqlshOutput(BaseTestCase):
             \n
         '''
 
-        ks = get_test_keyspace()
+        ks = get_keyspace()
 
         with testrun_cqlsh(tty=True, keyspace=None, cqlver=cqlsh.DEFAULT_CQLVER) as c:
 
@@ -711,7 +711,7 @@ class TestCqlshOutput(BaseTestCase):
                 self.assertNoHasColors(output)
                 self.assertRegexpMatches(output, output_re + '$')
 
-            c.send('USE %s;\n' % quote_name(get_test_keyspace()))
+            c.send('USE %s;\n' % quote_name(get_keyspace()))
             c.read_to_next_prompt()
 
             for semicolon in ('', ';'):


[02/10] cassandra git commit: Fixed cqlshlib.test.remove_test_db

Posted by st...@apache.org.
Fixed cqlshlib.test.remove_test_db

patch by Stefania Alborghetti; reviewed by Philip Thompson for CASSANDRA-12214


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

Branch: refs/heads/cassandra-3.0
Commit: e8186fe390073f5d7ea11057c5bc842db86d95d2
Parents: f0d1d75
Author: Stefania Alborghetti <st...@datastax.com>
Authored: Tue Jul 19 11:15:46 2016 +0800
Committer: Stefania Alborghetti <st...@datastax.com>
Committed: Wed Jul 20 09:54:53 2016 +0800

----------------------------------------------------------------------
 CHANGES.txt                              |  1 +
 pylib/cqlshlib/test/__init__.py          |  6 +++---
 pylib/cqlshlib/test/cassconnect.py       | 22 +++++++++++-----------
 pylib/cqlshlib/test/test_cqlsh_output.py | 14 +++++++-------
 4 files changed, 22 insertions(+), 21 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/e8186fe3/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index 837c3fb..ffd92b5 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -1,4 +1,5 @@
 2.2.8
+ * Fixed cqlshlib.test.remove_test_db (CASSANDRA-12214)
  * Synchronize ThriftServer::stop() (CASSANDRA-12105)
  * Use dedicated thread for JMX notifications (CASSANDRA-12146)
  * NPE when trying to remove purgable tombstones from result (CASSANDRA-12143)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/e8186fe3/pylib/cqlshlib/test/__init__.py
----------------------------------------------------------------------
diff --git a/pylib/cqlshlib/test/__init__.py b/pylib/cqlshlib/test/__init__.py
index 31f66f3..ba8f373 100644
--- a/pylib/cqlshlib/test/__init__.py
+++ b/pylib/cqlshlib/test/__init__.py
@@ -14,7 +14,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-from .cassconnect import create_test_db, remove_test_db
+from .cassconnect import create_db, remove_db
 
-setUp = create_test_db
-tearDown = remove_test_db
+setUp = create_db
+tearDown = remove_db

http://git-wip-us.apache.org/repos/asf/cassandra/blob/e8186fe3/pylib/cqlshlib/test/cassconnect.py
----------------------------------------------------------------------
diff --git a/pylib/cqlshlib/test/cassconnect.py b/pylib/cqlshlib/test/cassconnect.py
index 94910a6..4a1311e 100644
--- a/pylib/cqlshlib/test/cassconnect.py
+++ b/pylib/cqlshlib/test/cassconnect.py
@@ -37,15 +37,15 @@ def get_cassandra_cursor(cql_version=cqlsh.DEFAULT_CQLVER):
 
 TEST_KEYSPACES_CREATED = []
 
-def get_test_keyspace():
-    return TEST_KEYSPACES_CREATED[-1]
+def get_keyspace():
+    return None if len(TEST_KEYSPACES_CREATED) == 0 else TEST_KEYSPACES_CREATED[-1]
 
-def make_test_ks_name():
+def make_ks_name():
     # abuse mktemp to get a quick random-ish name
     return os.path.basename(tempfile.mktemp(prefix='CqlshTests_'))
 
-def create_test_keyspace(cursor):
-    ksname = make_test_ks_name()
+def create_keyspace(cursor):
+    ksname = make_ks_name()
     qksname = quote_name(ksname)
     cursor.execute('''
         CREATE KEYSPACE %s WITH replication =
@@ -72,13 +72,13 @@ def execute_cql_file(cursor, fname):
     with open(fname) as f:
         return execute_cql_commands(cursor, f.read())
 
-def create_test_db():
+def create_db():
     with cassandra_cursor(ks=None) as c:
-        k = create_test_keyspace(c)
+        k = create_keyspace(c)
         execute_cql_file(c, test_keyspace_init)
     return k
 
-def remove_test_db():
+def remove_db():
     with cassandra_cursor(ks=None) as c:
         c.execute('DROP KEYSPACE %s' % quote_name(TEST_KEYSPACES_CREATED.pop(-1)))
 
@@ -112,7 +112,7 @@ def cassandra_cursor(cql_version=None, ks=''):
     """
 
     if ks == '':
-        ks = get_test_keyspace()
+        ks = get_keyspace()
     conn = get_cassandra_connection(cql_version=cql_version)
     try:
         c = conn.connect(ks)
@@ -131,10 +131,10 @@ def testrun_cqlsh(keyspace=DEFAULTVAL, **kwargs):
     # use a positive default sentinel so that keyspace=None can be used
     # to override the default behavior
     if keyspace is DEFAULTVAL:
-        keyspace = get_test_keyspace()
+        keyspace = get_keyspace()
     return run_cqlsh(keyspace=keyspace, **kwargs)
 
 def testcall_cqlsh(keyspace=None, **kwargs):
     if keyspace is None:
-        keyspace = get_test_keyspace()
+        keyspace = get_keyspace()
     return call_cqlsh(keyspace=keyspace, **kwargs)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/e8186fe3/pylib/cqlshlib/test/test_cqlsh_output.py
----------------------------------------------------------------------
diff --git a/pylib/cqlshlib/test/test_cqlsh_output.py b/pylib/cqlshlib/test/test_cqlsh_output.py
index fdc562f..60699f3 100644
--- a/pylib/cqlshlib/test/test_cqlsh_output.py
+++ b/pylib/cqlshlib/test/test_cqlsh_output.py
@@ -23,7 +23,7 @@ import re
 from itertools import izip
 from .basecase import (BaseTestCase, cqlshlog, dedent, at_a_time, cqlsh,
                        TEST_HOST, TEST_PORT)
-from .cassconnect import (get_test_keyspace, testrun_cqlsh, testcall_cqlsh,
+from .cassconnect import (get_keyspace, testrun_cqlsh, testcall_cqlsh,
                           cassandra_cursor, split_cql_commands, quote_name)
 from .ansi_colors import (ColoredText, lookup_colorcode, lookup_colorname,
                           lookup_colorletter, ansi_seq)
@@ -534,10 +534,10 @@ class TestCqlshOutput(BaseTestCase):
             output = c.read_to_next_prompt().replace('\r\n', '\n')
             self.assertTrue(output.endswith('cqlsh> '))
 
-            cmd = "USE \"%s\";\n" % get_test_keyspace().replace('"', '""')
+            cmd = "USE \"%s\";\n" % get_keyspace().replace('"', '""')
             c.send(cmd)
             output = c.read_to_next_prompt().replace('\r\n', '\n')
-            self.assertTrue(output.endswith('cqlsh:%s> ' % (get_test_keyspace())))
+            self.assertTrue(output.endswith('cqlsh:%s> ' % (get_keyspace())))
 
             c.send('use system;\n')
             output = c.read_to_next_prompt().replace('\r\n', '\n')
@@ -561,7 +561,7 @@ class TestCqlshOutput(BaseTestCase):
     def test_describe_keyspace_output(self):
         fullcqlver = cqlsh.DEFAULT_CQLVER
         with testrun_cqlsh(tty=True, cqlver=fullcqlver) as c:
-            ks = get_test_keyspace()
+            ks = get_keyspace()
             qks = quote_name(ks)
             for cmd in ('describe keyspace', 'desc keyspace'):
                 for givename in ('system', '', qks):
@@ -632,7 +632,7 @@ class TestCqlshOutput(BaseTestCase):
                 AND read_repair_chance = 0.0
                 AND speculative_retry = '99.0PERCENTILE';
 
-        """ % quote_name(get_test_keyspace()))
+        """ % quote_name(get_keyspace()))
 
         with testrun_cqlsh(tty=True, cqlver=cqlsh.DEFAULT_CQLVER) as c:
             for cmdword in ('describe table', 'desc columnfamily'):
@@ -650,7 +650,7 @@ class TestCqlshOutput(BaseTestCase):
             \n
         '''
 
-        ks = get_test_keyspace()
+        ks = get_keyspace()
 
         with testrun_cqlsh(tty=True, keyspace=None, cqlver=cqlsh.DEFAULT_CQLVER) as c:
 
@@ -711,7 +711,7 @@ class TestCqlshOutput(BaseTestCase):
                 self.assertNoHasColors(output)
                 self.assertRegexpMatches(output, output_re + '$')
 
-            c.send('USE %s;\n' % quote_name(get_test_keyspace()))
+            c.send('USE %s;\n' % quote_name(get_keyspace()))
             c.read_to_next_prompt()
 
             for semicolon in ('', ';'):


[03/10] cassandra git commit: Fixed cqlshlib.test.remove_test_db

Posted by st...@apache.org.
Fixed cqlshlib.test.remove_test_db

patch by Stefania Alborghetti; reviewed by Philip Thompson for CASSANDRA-12214


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

Branch: refs/heads/cassandra-3.9
Commit: e8186fe390073f5d7ea11057c5bc842db86d95d2
Parents: f0d1d75
Author: Stefania Alborghetti <st...@datastax.com>
Authored: Tue Jul 19 11:15:46 2016 +0800
Committer: Stefania Alborghetti <st...@datastax.com>
Committed: Wed Jul 20 09:54:53 2016 +0800

----------------------------------------------------------------------
 CHANGES.txt                              |  1 +
 pylib/cqlshlib/test/__init__.py          |  6 +++---
 pylib/cqlshlib/test/cassconnect.py       | 22 +++++++++++-----------
 pylib/cqlshlib/test/test_cqlsh_output.py | 14 +++++++-------
 4 files changed, 22 insertions(+), 21 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/e8186fe3/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index 837c3fb..ffd92b5 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -1,4 +1,5 @@
 2.2.8
+ * Fixed cqlshlib.test.remove_test_db (CASSANDRA-12214)
  * Synchronize ThriftServer::stop() (CASSANDRA-12105)
  * Use dedicated thread for JMX notifications (CASSANDRA-12146)
  * NPE when trying to remove purgable tombstones from result (CASSANDRA-12143)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/e8186fe3/pylib/cqlshlib/test/__init__.py
----------------------------------------------------------------------
diff --git a/pylib/cqlshlib/test/__init__.py b/pylib/cqlshlib/test/__init__.py
index 31f66f3..ba8f373 100644
--- a/pylib/cqlshlib/test/__init__.py
+++ b/pylib/cqlshlib/test/__init__.py
@@ -14,7 +14,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-from .cassconnect import create_test_db, remove_test_db
+from .cassconnect import create_db, remove_db
 
-setUp = create_test_db
-tearDown = remove_test_db
+setUp = create_db
+tearDown = remove_db

http://git-wip-us.apache.org/repos/asf/cassandra/blob/e8186fe3/pylib/cqlshlib/test/cassconnect.py
----------------------------------------------------------------------
diff --git a/pylib/cqlshlib/test/cassconnect.py b/pylib/cqlshlib/test/cassconnect.py
index 94910a6..4a1311e 100644
--- a/pylib/cqlshlib/test/cassconnect.py
+++ b/pylib/cqlshlib/test/cassconnect.py
@@ -37,15 +37,15 @@ def get_cassandra_cursor(cql_version=cqlsh.DEFAULT_CQLVER):
 
 TEST_KEYSPACES_CREATED = []
 
-def get_test_keyspace():
-    return TEST_KEYSPACES_CREATED[-1]
+def get_keyspace():
+    return None if len(TEST_KEYSPACES_CREATED) == 0 else TEST_KEYSPACES_CREATED[-1]
 
-def make_test_ks_name():
+def make_ks_name():
     # abuse mktemp to get a quick random-ish name
     return os.path.basename(tempfile.mktemp(prefix='CqlshTests_'))
 
-def create_test_keyspace(cursor):
-    ksname = make_test_ks_name()
+def create_keyspace(cursor):
+    ksname = make_ks_name()
     qksname = quote_name(ksname)
     cursor.execute('''
         CREATE KEYSPACE %s WITH replication =
@@ -72,13 +72,13 @@ def execute_cql_file(cursor, fname):
     with open(fname) as f:
         return execute_cql_commands(cursor, f.read())
 
-def create_test_db():
+def create_db():
     with cassandra_cursor(ks=None) as c:
-        k = create_test_keyspace(c)
+        k = create_keyspace(c)
         execute_cql_file(c, test_keyspace_init)
     return k
 
-def remove_test_db():
+def remove_db():
     with cassandra_cursor(ks=None) as c:
         c.execute('DROP KEYSPACE %s' % quote_name(TEST_KEYSPACES_CREATED.pop(-1)))
 
@@ -112,7 +112,7 @@ def cassandra_cursor(cql_version=None, ks=''):
     """
 
     if ks == '':
-        ks = get_test_keyspace()
+        ks = get_keyspace()
     conn = get_cassandra_connection(cql_version=cql_version)
     try:
         c = conn.connect(ks)
@@ -131,10 +131,10 @@ def testrun_cqlsh(keyspace=DEFAULTVAL, **kwargs):
     # use a positive default sentinel so that keyspace=None can be used
     # to override the default behavior
     if keyspace is DEFAULTVAL:
-        keyspace = get_test_keyspace()
+        keyspace = get_keyspace()
     return run_cqlsh(keyspace=keyspace, **kwargs)
 
 def testcall_cqlsh(keyspace=None, **kwargs):
     if keyspace is None:
-        keyspace = get_test_keyspace()
+        keyspace = get_keyspace()
     return call_cqlsh(keyspace=keyspace, **kwargs)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/e8186fe3/pylib/cqlshlib/test/test_cqlsh_output.py
----------------------------------------------------------------------
diff --git a/pylib/cqlshlib/test/test_cqlsh_output.py b/pylib/cqlshlib/test/test_cqlsh_output.py
index fdc562f..60699f3 100644
--- a/pylib/cqlshlib/test/test_cqlsh_output.py
+++ b/pylib/cqlshlib/test/test_cqlsh_output.py
@@ -23,7 +23,7 @@ import re
 from itertools import izip
 from .basecase import (BaseTestCase, cqlshlog, dedent, at_a_time, cqlsh,
                        TEST_HOST, TEST_PORT)
-from .cassconnect import (get_test_keyspace, testrun_cqlsh, testcall_cqlsh,
+from .cassconnect import (get_keyspace, testrun_cqlsh, testcall_cqlsh,
                           cassandra_cursor, split_cql_commands, quote_name)
 from .ansi_colors import (ColoredText, lookup_colorcode, lookup_colorname,
                           lookup_colorletter, ansi_seq)
@@ -534,10 +534,10 @@ class TestCqlshOutput(BaseTestCase):
             output = c.read_to_next_prompt().replace('\r\n', '\n')
             self.assertTrue(output.endswith('cqlsh> '))
 
-            cmd = "USE \"%s\";\n" % get_test_keyspace().replace('"', '""')
+            cmd = "USE \"%s\";\n" % get_keyspace().replace('"', '""')
             c.send(cmd)
             output = c.read_to_next_prompt().replace('\r\n', '\n')
-            self.assertTrue(output.endswith('cqlsh:%s> ' % (get_test_keyspace())))
+            self.assertTrue(output.endswith('cqlsh:%s> ' % (get_keyspace())))
 
             c.send('use system;\n')
             output = c.read_to_next_prompt().replace('\r\n', '\n')
@@ -561,7 +561,7 @@ class TestCqlshOutput(BaseTestCase):
     def test_describe_keyspace_output(self):
         fullcqlver = cqlsh.DEFAULT_CQLVER
         with testrun_cqlsh(tty=True, cqlver=fullcqlver) as c:
-            ks = get_test_keyspace()
+            ks = get_keyspace()
             qks = quote_name(ks)
             for cmd in ('describe keyspace', 'desc keyspace'):
                 for givename in ('system', '', qks):
@@ -632,7 +632,7 @@ class TestCqlshOutput(BaseTestCase):
                 AND read_repair_chance = 0.0
                 AND speculative_retry = '99.0PERCENTILE';
 
-        """ % quote_name(get_test_keyspace()))
+        """ % quote_name(get_keyspace()))
 
         with testrun_cqlsh(tty=True, cqlver=cqlsh.DEFAULT_CQLVER) as c:
             for cmdword in ('describe table', 'desc columnfamily'):
@@ -650,7 +650,7 @@ class TestCqlshOutput(BaseTestCase):
             \n
         '''
 
-        ks = get_test_keyspace()
+        ks = get_keyspace()
 
         with testrun_cqlsh(tty=True, keyspace=None, cqlver=cqlsh.DEFAULT_CQLVER) as c:
 
@@ -711,7 +711,7 @@ class TestCqlshOutput(BaseTestCase):
                 self.assertNoHasColors(output)
                 self.assertRegexpMatches(output, output_re + '$')
 
-            c.send('USE %s;\n' % quote_name(get_test_keyspace()))
+            c.send('USE %s;\n' % quote_name(get_keyspace()))
             c.read_to_next_prompt()
 
             for semicolon in ('', ';'):


[05/10] cassandra git commit: Merge branch 'cassandra-2.2' into cassandra-3.0

Posted by st...@apache.org.
Merge branch 'cassandra-2.2' into cassandra-3.0


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

Branch: refs/heads/cassandra-3.9
Commit: dce4537410d66a3cbd24b2e581737b849e011917
Parents: 0297cbe e8186fe
Author: Stefania Alborghetti <st...@datastax.com>
Authored: Wed Jul 20 09:56:12 2016 +0800
Committer: Stefania Alborghetti <st...@datastax.com>
Committed: Wed Jul 20 09:56:12 2016 +0800

----------------------------------------------------------------------
 CHANGES.txt                              |  1 +
 pylib/cqlshlib/test/__init__.py          |  6 +++---
 pylib/cqlshlib/test/cassconnect.py       | 22 +++++++++++-----------
 pylib/cqlshlib/test/test_cqlsh_output.py | 14 +++++++-------
 4 files changed, 22 insertions(+), 21 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/dce45374/CHANGES.txt
----------------------------------------------------------------------
diff --cc CHANGES.txt
index f205e0b,ffd92b5..739c095
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@@ -1,21 -1,8 +1,22 @@@
 -2.2.8
 +3.0.9
 + * Fix problem with undeleteable rows on upgrade to new sstable format (CASSANDRA-12144)
 + * Fix paging logic for deleted partitions with static columns (CASSANDRA-12107)
 + * Wait until the message is being send to decide which serializer must be used (CASSANDRA-11393)
 + * Fix migration of static thrift column names with non-text comparators (CASSANDRA-12147)
 + * Fix upgrading sparse tables that are incorrectly marked as dense (CASSANDRA-11315)
 + * Fix reverse queries ignoring range tombstones (CASSANDRA-11733)
 + * Avoid potential race when rebuilding CFMetaData (CASSANDRA-12098)
 + * Avoid missing sstables when getting the canonical sstables (CASSANDRA-11996)
 + * Always select the live sstables when getting sstables in bounds (CASSANDRA-11944)
 + * Fix column ordering of results with static columns for Thrift requests in
 +   a mixed 2.x/3.x cluster, also fix potential non-resolved duplication of
 +   those static columns in query results (CASSANDRA-12123)
 + * Avoid digest mismatch with empty but static rows (CASSANDRA-12090)
 + * Fix EOF exception when altering column type (CASSANDRA-11820)
 +Merged from 2.2:
+  * Fixed cqlshlib.test.remove_test_db (CASSANDRA-12214)
   * Synchronize ThriftServer::stop() (CASSANDRA-12105)
   * Use dedicated thread for JMX notifications (CASSANDRA-12146)
 - * NPE when trying to remove purgable tombstones from result (CASSANDRA-12143)
   * Improve streaming synchronization and fault tolerance (CASSANDRA-11414)
   * MemoryUtil.getShort() should return an unsigned short also for architectures not supporting unaligned memory accesses (CASSANDRA-11973)
  Merged from 2.1:

http://git-wip-us.apache.org/repos/asf/cassandra/blob/dce45374/pylib/cqlshlib/test/test_cqlsh_output.py
----------------------------------------------------------------------
diff --cc pylib/cqlshlib/test/test_cqlsh_output.py
index f867312,60699f3..85ce626
--- a/pylib/cqlshlib/test/test_cqlsh_output.py
+++ b/pylib/cqlshlib/test/test_cqlsh_output.py
@@@ -631,9 -630,9 +631,9 @@@ class TestCqlshOutput(BaseTestCase)
                  AND memtable_flush_period_in_ms = 0
                  AND min_index_interval = 128
                  AND read_repair_chance = 0.0
 -                AND speculative_retry = '99.0PERCENTILE';
 +                AND speculative_retry = '99PERCENTILE';
  
-         """ % quote_name(get_test_keyspace()))
+         """ % quote_name(get_keyspace()))
  
          with testrun_cqlsh(tty=True, cqlver=cqlsh.DEFAULT_CQLVER) as c:
              for cmdword in ('describe table', 'desc columnfamily'):


[10/10] cassandra git commit: Merge branch 'cassandra-3.9' into trunk

Posted by st...@apache.org.
Merge branch 'cassandra-3.9' into trunk


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

Branch: refs/heads/trunk
Commit: f129dea8694ba2a7822748722294da40c9fc0de3
Parents: cc58285 8df6d4d
Author: Stefania Alborghetti <st...@datastax.com>
Authored: Wed Jul 20 10:00:12 2016 +0800
Committer: Stefania Alborghetti <st...@datastax.com>
Committed: Wed Jul 20 10:00:12 2016 +0800

----------------------------------------------------------------------
 CHANGES.txt                              |  2 ++
 pylib/cqlshlib/test/__init__.py          |  6 +++---
 pylib/cqlshlib/test/cassconnect.py       | 22 +++++++++++-----------
 pylib/cqlshlib/test/test_cqlsh_output.py | 14 +++++++-------
 4 files changed, 23 insertions(+), 21 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/f129dea8/CHANGES.txt
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/cassandra/blob/f129dea8/pylib/cqlshlib/test/cassconnect.py
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/cassandra/blob/f129dea8/pylib/cqlshlib/test/test_cqlsh_output.py
----------------------------------------------------------------------
diff --cc pylib/cqlshlib/test/test_cqlsh_output.py
index a6290ff,9936f50..8c19e62
--- a/pylib/cqlshlib/test/test_cqlsh_output.py
+++ b/pylib/cqlshlib/test/test_cqlsh_output.py
@@@ -552,8 -559,9 +552,8 @@@ class TestCqlshOutput(BaseTestCase)
                               "RRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRR")
  
      def test_describe_keyspace_output(self):
 -        fullcqlver = cqlsh.DEFAULT_CQLVER
 -        with testrun_cqlsh(tty=True, cqlver=fullcqlver) as c:
 +        with testrun_cqlsh(tty=True) as c:
-             ks = get_test_keyspace()
+             ks = get_keyspace()
              qks = quote_name(ks)
              for cmd in ('describe keyspace', 'desc keyspace'):
                  for givename in ('system', '', qks):
@@@ -625,9 -633,9 +625,9 @@@
                  AND read_repair_chance = 0.0
                  AND speculative_retry = '99PERCENTILE';
  
-         """ % quote_name(get_test_keyspace()))
+         """ % quote_name(get_keyspace()))
  
 -        with testrun_cqlsh(tty=True, cqlver=cqlsh.DEFAULT_CQLVER) as c:
 +        with testrun_cqlsh(tty=True) as c:
              for cmdword in ('describe table', 'desc columnfamily'):
                  for semicolon in (';', ''):
                      output = c.cmd_and_response('%s has_all_types%s' % (cmdword, semicolon))
@@@ -643,9 -651,9 +643,9 @@@
              \n
          '''
  
-         ks = get_test_keyspace()
+         ks = get_keyspace()
  
 -        with testrun_cqlsh(tty=True, keyspace=None, cqlver=cqlsh.DEFAULT_CQLVER) as c:
 +        with testrun_cqlsh(tty=True, keyspace=None) as c:
  
              # when not in a keyspace
              for cmdword in ('DESCRIBE COLUMNFAMILIES', 'desc tables'):


[09/10] cassandra git commit: Merge branch 'cassandra-3.0' into cassandra-3.9

Posted by st...@apache.org.
Merge branch 'cassandra-3.0' into cassandra-3.9


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

Branch: refs/heads/trunk
Commit: 8df6d4d4c60f865a09a93ff678ea5f6417465c29
Parents: 4bd4be8 dce4537
Author: Stefania Alborghetti <st...@datastax.com>
Authored: Wed Jul 20 09:58:14 2016 +0800
Committer: Stefania Alborghetti <st...@datastax.com>
Committed: Wed Jul 20 09:58:40 2016 +0800

----------------------------------------------------------------------
 CHANGES.txt                              |  2 ++
 pylib/cqlshlib/test/__init__.py          |  6 +++---
 pylib/cqlshlib/test/cassconnect.py       | 22 +++++++++++-----------
 pylib/cqlshlib/test/test_cqlsh_output.py | 14 +++++++-------
 4 files changed, 23 insertions(+), 21 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/8df6d4d4/CHANGES.txt
----------------------------------------------------------------------
diff --cc CHANGES.txt
index 780ea96,739c095..dac46ab
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@@ -1,36 -1,5 +1,38 @@@
 -3.0.9
 +3.9
 +Merged from 3.0:
   * Fix problem with undeleteable rows on upgrade to new sstable format (CASSANDRA-12144)
++Merged from 2.2:
++ * Fixed cqlshlib.test.remove_test_db (CASSANDRA-12214)
 +
 +3.8
 + * Fix hdr logging for single operation workloads (CASSANDRA-12145)
 + * Fix SASI PREFIX search in CONTAINS mode with partial terms (CASSANDRA-12073)
 + * Increase size of flushExecutor thread pool (CASSANDRA-12071)
 + * Partial revert of CASSANDRA-11971, cannot recycle buffer in SP.sendMessagesToNonlocalDC (CASSANDRA-11950)
 + * Upgrade netty to 4.0.39 (CASSANDRA-12032, CASSANDRA-12034)
 + * Improve details in compaction log message (CASSANDRA-12080)
 + * Allow unset values in CQLSSTableWriter (CASSANDRA-11911)
 + * Chunk cache to request compressor-compatible buffers if pool space is exhausted (CASSANDRA-11993)
 + * Remove DatabaseDescriptor dependencies from SequentialWriter (CASSANDRA-11579)
 + * Move skip_stop_words filter before stemming (CASSANDRA-12078)
 + * Support seek() in EncryptedFileSegmentInputStream (CASSANDRA-11957)
 + * SSTable tools mishandling LocalPartitioner (CASSANDRA-12002)
 + * When SEPWorker assigned work, set thread name to match pool (CASSANDRA-11966)
 + * Add cross-DC latency metrics (CASSANDRA-11596)
 + * Allow terms in selection clause (CASSANDRA-10783)
 + * Add bind variables to trace (CASSANDRA-11719)
 + * Switch counter shards' clock to timestamps (CASSANDRA-9811)
 + * Introduce HdrHistogram and response/service/wait separation to stress tool (CASSANDRA-11853)
 + * entry-weighers in QueryProcessor should respect partitionKeyBindIndexes field (CASSANDRA-11718)
 + * Support older ant versions (CASSANDRA-11807)
 + * Estimate compressed on disk size when deciding if sstable size limit reached (CASSANDRA-11623)
 + * cassandra-stress profiles should support case sensitive schemas (CASSANDRA-11546)
 + * Remove DatabaseDescriptor dependency from FileUtils (CASSANDRA-11578)
 + * Faster streaming (CASSANDRA-9766)
 + * Add prepared query parameter to trace for "Execute CQL3 prepared query" session (CASSANDRA-11425)
 + * Add repaired percentage metric (CASSANDRA-11503)
 + * Add Change-Data-Capture (CASSANDRA-8844)
 +Merged from 3.0:
   * Fix paging logic for deleted partitions with static columns (CASSANDRA-12107)
   * Wait until the message is being send to decide which serializer must be used (CASSANDRA-11393)
   * Fix migration of static thrift column names with non-text comparators (CASSANDRA-12147)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/8df6d4d4/pylib/cqlshlib/test/test_cqlsh_output.py
----------------------------------------------------------------------