cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From slebre...@apache.org
Subject [3/6] git commit: Remove dead sliced_buffer_size_in_kb option
Date Fri, 30 Mar 2012 14:50:08 GMT
Remove dead sliced_buffer_size_in_kb option

patch by slebresne; reviewed by jbellis for CASSANDRA-4076


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

Branch: refs/heads/cassandra-1.1
Commit: d69d304c4e4788daa201539e5e8441d30bb02396
Parents: e05a327
Author: Sylvain Lebresne <sylvain@datastax.com>
Authored: Fri Mar 30 16:44:24 2012 +0200
Committer: Sylvain Lebresne <sylvain@datastax.com>
Committed: Fri Mar 30 16:44:24 2012 +0200

----------------------------------------------------------------------
 CHANGES.txt                                        |    1 +
 NEWS.txt                                           |    3 ++-
 conf/cassandra.yaml                                |    4 ----
 examples/client_only/conf/cassandra.yaml           |    4 ----
 src/java/org/apache/cassandra/config/Config.java   |    2 --
 .../cassandra/config/DatabaseDescriptor.java       |   10 ----------
 .../db/columniterator/SSTableNamesIterator.java    |    2 +-
 .../db/columniterator/SSTableSliceIterator.java    |    2 +-
 .../apache/cassandra/io/sstable/SSTableReader.java |    2 +-
 .../cassandra/io/sstable/SSTableReaderTest.java    |    2 +-
 10 files changed, 7 insertions(+), 25 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/d69d304c/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index 55d17f7..9c62679 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -2,6 +2,7 @@
  * Adds caching and bloomFilterFpChange to CQL options (CASSANDRA-4042)
  * Adds posibility to autoconfigure size of the KeyCache (CASSANDRA-4087)
  * fix KEYS index from skipping results (CASSANDRA-3996)
+ * Remove sliced_buffer_size_in_kb dead option (CASSANDRA-4076)
 
 
 1.1-beta2

http://git-wip-us.apache.org/repos/asf/cassandra/blob/d69d304c/NEWS.txt
----------------------------------------------------------------------
diff --git a/NEWS.txt b/NEWS.txt
index a588e91..eca9e02 100644
--- a/NEWS.txt
+++ b/NEWS.txt
@@ -48,7 +48,8 @@ Upgrading
       + Prior to 1.1, you could use KEY as the primary key name in some
         select statements, even if the PK was actually given a different
         name.  In 1.1+ you must use the defined PK name.
-        
+    - The sliced_buffer_size_in_kb option has been removed from the
+      cassandra.yaml config file (this option was a no-op since 1.0).
 
 Features
 --------

http://git-wip-us.apache.org/repos/asf/cassandra/blob/d69d304c/conf/cassandra.yaml
----------------------------------------------------------------------
diff --git a/conf/cassandra.yaml b/conf/cassandra.yaml
index 866319c..1874f32 100644
--- a/conf/cassandra.yaml
+++ b/conf/cassandra.yaml
@@ -223,10 +223,6 @@ concurrent_writes: 32
 # the maximum number of secondary indexes created on a single CF.
 memtable_flush_queue_size: 4
 
-# Buffer size to use when performing contiguous column slices. 
-# Increase this to the size of the column slices you typically perform
-sliced_buffer_size_in_kb: 64
-
 # Whether to, when doing sequential writing, fsync() at intervals in
 # order to force the operating system to flush the dirty
 # buffers. Enable this to avoid sudden dirty buffer flushing from

http://git-wip-us.apache.org/repos/asf/cassandra/blob/d69d304c/examples/client_only/conf/cassandra.yaml
----------------------------------------------------------------------
diff --git a/examples/client_only/conf/cassandra.yaml b/examples/client_only/conf/cassandra.yaml
index 2d92794..701d191 100644
--- a/examples/client_only/conf/cassandra.yaml
+++ b/examples/client_only/conf/cassandra.yaml
@@ -150,10 +150,6 @@ concurrent_writes: 32
 # By default this will be set to the amount of data directories defined.
 #memtable_flush_writers: 1
 
-# Buffer size to use when performing contiguous column slices. 
-# Increase this to the size of the column slices you typically perform
-sliced_buffer_size_in_kb: 64
-
 # TCP port, for commands and data
 storage_port: 7000
 

http://git-wip-us.apache.org/repos/asf/cassandra/blob/d69d304c/src/java/org/apache/cassandra/config/Config.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/config/Config.java b/src/java/org/apache/cassandra/config/Config.java
index 2bc34dc..91b96f1 100644
--- a/src/java/org/apache/cassandra/config/Config.java
+++ b/src/java/org/apache/cassandra/config/Config.java
@@ -61,8 +61,6 @@ public class Config
     public Integer memtable_flush_writers = null; // will get set to the length of data dirs
in DatabaseDescriptor
     public Integer memtable_total_space_in_mb;
 
-    public Integer sliced_buffer_size_in_kb = 64;
-
     public Integer storage_port = 7000;
     public Integer ssl_storage_port = 7001;
     public String listen_address;

http://git-wip-us.apache.org/repos/asf/cassandra/blob/d69d304c/src/java/org/apache/cassandra/config/DatabaseDescriptor.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/config/DatabaseDescriptor.java b/src/java/org/apache/cassandra/config/DatabaseDescriptor.java
index 8c5997f..792dc18 100644
--- a/src/java/org/apache/cassandra/config/DatabaseDescriptor.java
+++ b/src/java/org/apache/cassandra/config/DatabaseDescriptor.java
@@ -864,16 +864,6 @@ public class DatabaseDescriptor
         return indexAccessMode;
     }
 
-    public static int getIndexedReadBufferSizeInKB()
-    {
-        return conf.column_index_size_in_kb;
-    }
-
-    public static int getSlicedReadBufferSizeInKB()
-    {
-        return conf.sliced_buffer_size_in_kb;
-    }
-
     public static boolean isSnapshotBeforeCompaction()
     {
         return conf.snapshot_before_compaction;

http://git-wip-us.apache.org/repos/asf/cassandra/blob/d69d304c/src/java/org/apache/cassandra/db/columniterator/SSTableNamesIterator.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/db/columniterator/SSTableNamesIterator.java b/src/java/org/apache/cassandra/db/columniterator/SSTableNamesIterator.java
index fdb0c5c..c063d3e 100644
--- a/src/java/org/apache/cassandra/db/columniterator/SSTableNamesIterator.java
+++ b/src/java/org/apache/cassandra/db/columniterator/SSTableNamesIterator.java
@@ -58,7 +58,7 @@ public class SSTableNamesIterator extends SimpleAbstractColumnIterator implement
         this.columns = columns;
         this.key = key;
 
-        FileDataInput file = sstable.getFileDataInput(key, DatabaseDescriptor.getIndexedReadBufferSizeInKB()
* 1024);
+        FileDataInput file = sstable.getFileDataInput(key);
         if (file == null)
             return;
 

http://git-wip-us.apache.org/repos/asf/cassandra/blob/d69d304c/src/java/org/apache/cassandra/db/columniterator/SSTableSliceIterator.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/db/columniterator/SSTableSliceIterator.java b/src/java/org/apache/cassandra/db/columniterator/SSTableSliceIterator.java
index 72fe1bf..8a43e28 100644
--- a/src/java/org/apache/cassandra/db/columniterator/SSTableSliceIterator.java
+++ b/src/java/org/apache/cassandra/db/columniterator/SSTableSliceIterator.java
@@ -45,7 +45,7 @@ public class SSTableSliceIterator implements IColumnIterator
     public SSTableSliceIterator(SSTableReader sstable, DecoratedKey key, ByteBuffer startColumn,
ByteBuffer finishColumn, boolean reversed)
     {
         this.key = key;
-        fileToClose = sstable.getFileDataInput(this.key, DatabaseDescriptor.getSlicedReadBufferSizeInKB()
* 1024);
+        fileToClose = sstable.getFileDataInput(this.key);
         if (fileToClose == null)
             return;
 

http://git-wip-us.apache.org/repos/asf/cassandra/blob/d69d304c/src/java/org/apache/cassandra/io/sstable/SSTableReader.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/io/sstable/SSTableReader.java b/src/java/org/apache/cassandra/io/sstable/SSTableReader.java
index 57cdfa2..6c679ee 100644
--- a/src/java/org/apache/cassandra/io/sstable/SSTableReader.java
+++ b/src/java/org/apache/cassandra/io/sstable/SSTableReader.java
@@ -834,7 +834,7 @@ public class SSTableReader extends SSTable
         return new SSTableBoundedScanner(this, true, range);
     }
 
-    public FileDataInput getFileDataInput(DecoratedKey decoratedKey, int bufferSize)
+    public FileDataInput getFileDataInput(DecoratedKey decoratedKey)
     {
         long position = getPosition(decoratedKey, Operator.EQ);
         if (position < 0)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/d69d304c/test/unit/org/apache/cassandra/io/sstable/SSTableReaderTest.java
----------------------------------------------------------------------
diff --git a/test/unit/org/apache/cassandra/io/sstable/SSTableReaderTest.java b/test/unit/org/apache/cassandra/io/sstable/SSTableReaderTest.java
index 102fccd..004dac8 100644
--- a/test/unit/org/apache/cassandra/io/sstable/SSTableReaderTest.java
+++ b/test/unit/org/apache/cassandra/io/sstable/SSTableReaderTest.java
@@ -125,7 +125,7 @@ public class SSTableReaderTest extends SchemaLoader
         for (int j = 0; j < 100; j += 2)
         {
             DecoratedKey dk = Util.dk(String.valueOf(j));
-            FileDataInput file = sstable.getFileDataInput(dk, DatabaseDescriptor.getIndexedReadBufferSizeInKB()
* 1024);
+            FileDataInput file = sstable.getFileDataInput(dk);
             DecoratedKey keyInDisk = SSTableReader.decodeKey(sstable.partitioner,
                                                              sstable.descriptor,
                                                              ByteBufferUtil.readWithShortLength(file));


Mime
View raw message