cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jasobr...@apache.org
Subject [1/2] git commit: Do not hard code the current Descriptor version into BootstrapTest. patch by jasobrown; reviewed by Aleksey Yeschenko for CASSANDRA-5495
Date Thu, 18 Apr 2013 17:42:56 GMT
Updated Branches:
  refs/heads/trunk 116d90761 -> 29974346a


Do not hard code the current Descriptor version into BootstrapTest.
patch by jasobrown; reviewed by Aleksey Yeschenko for CASSANDRA-5495


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

Branch: refs/heads/trunk
Commit: 9fc071a39971d7e2a4b17399b07630f6f2438484
Parents: 455a0fc
Author: Jason Brown <jasedbrown@gmail.com>
Authored: Thu Apr 18 05:56:18 2013 -0700
Committer: Jason Brown <jasedbrown@gmail.com>
Committed: Thu Apr 18 10:34:03 2013 -0700

----------------------------------------------------------------------
 .../apache/cassandra/io/sstable/Descriptor.java    |    2 +-
 .../apache/cassandra/streaming/BootstrapTest.java  |    3 ++-
 2 files changed, 3 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/9fc071a3/src/java/org/apache/cassandra/io/sstable/Descriptor.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/io/sstable/Descriptor.java b/src/java/org/apache/cassandra/io/sstable/Descriptor.java
index 0338044..f21a0d5 100644
--- a/src/java/org/apache/cassandra/io/sstable/Descriptor.java
+++ b/src/java/org/apache/cassandra/io/sstable/Descriptor.java
@@ -47,7 +47,7 @@ public class Descriptor
     public static class Version
     {
         // This needs to be at the begining for initialization sake
-        private static final String current_version = "ib";
+        public static final String current_version = "ib";
 
         public static final Version LEGACY = new Version("a"); // "pre-history"
         // b (0.7.0): added version to sstable filenames

http://git-wip-us.apache.org/repos/asf/cassandra/blob/9fc071a3/test/unit/org/apache/cassandra/streaming/BootstrapTest.java
----------------------------------------------------------------------
diff --git a/test/unit/org/apache/cassandra/streaming/BootstrapTest.java b/test/unit/org/apache/cassandra/streaming/BootstrapTest.java
index 1af3074..6578dde 100644
--- a/test/unit/org/apache/cassandra/streaming/BootstrapTest.java
+++ b/test/unit/org/apache/cassandra/streaming/BootstrapTest.java
@@ -36,7 +36,8 @@ public class BootstrapTest extends SchemaLoader
     @Test
     public void testGetNewNames() throws IOException
     {
-        Descriptor desc = Descriptor.fromFilename(new File("Keyspace1", "Keyspace1-Standard1-ib-500-Data.db").toString());
+        String ver = Descriptor.Version.current_version;
+        Descriptor desc = Descriptor.fromFilename(new File("Keyspace1", "Keyspace1-Standard1-"
+ ver +"-500-Data.db").toString());
         // assert !desc.isLatestVersion; // minimum compatible version -- for now it is the
latest as well
         PendingFile inContext = new PendingFile(null, desc, "Data.db", Arrays.asList(Pair.create(0L,
1L)), OperationType.BOOTSTRAP);
 


Mime
View raw message