cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jasobr...@apache.org
Subject [2/2] git commit: Merge remote-tracking branch 'apache/cassandra-1.2' into trunk
Date Tue, 02 Apr 2013 18:49:07 GMT
Merge remote-tracking branch 'apache/cassandra-1.2' into trunk

Conflicts:
	src/java/org/apache/cassandra/db/columniterator/SimpleSliceReader.java
	src/java/org/apache/cassandra/io/sstable/SSTableIdentityIterator.java
	test/unit/org/apache/cassandra/db/ScrubTest.java


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

Branch: refs/heads/trunk
Commit: ae1f7be73422b72fe5a2dc2170a99c55c0bf5f0d
Parents: 313c79a 4f75875
Author: Jason Brown <jasedbrown@gmail.com>
Authored: Tue Apr 2 11:47:41 2013 -0700
Committer: Jason Brown <jasedbrown@gmail.com>
Committed: Tue Apr 2 11:47:41 2013 -0700

----------------------------------------------------------------------
 CHANGES.txt                                        |    1 +
 .../org/apache/cassandra/db/RowIndexEntry.java     |    2 +-
 .../db/columniterator/IndexedSliceReader.java      |   10 +-
 .../db/columniterator/SSTableNamesIterator.java    |    2 +-
 .../db/columniterator/SimpleSliceReader.java       |    8 +-
 .../apache/cassandra/io/sstable/IndexHelper.java   |   23 +-
 .../io/sstable/SSTableIdentityIterator.java        |    8 +-
 test/unit/org/apache/cassandra/db/ScrubTest.java   |  245 ---------------
 8 files changed, 31 insertions(+), 268 deletions(-)
----------------------------------------------------------------------


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

http://git-wip-us.apache.org/repos/asf/cassandra/blob/ae1f7be7/src/java/org/apache/cassandra/db/RowIndexEntry.java
----------------------------------------------------------------------
diff --cc src/java/org/apache/cassandra/db/RowIndexEntry.java
index 6982a77,e9f08b2..2a8dcfe
--- a/src/java/org/apache/cassandra/db/RowIndexEntry.java
+++ b/src/java/org/apache/cassandra/db/RowIndexEntry.java
@@@ -86,23 -94,33 +86,23 @@@ public class RowIndexEntr
              }
          }
  
 -        public RowIndexEntry deserializePositionOnly(DataInput dis, Descriptor.Version version)
throws IOException
 +        public RowIndexEntry deserialize(DataInput in, Descriptor.Version version) throws
IOException
          {
 -            long position = dis.readLong();
 +            long position = in.readLong();
              if (version.hasPromotedIndexes)
              {
 -                int size = dis.readInt();
 -                if (size > 0)
 -                    FileUtils.skipBytesFully(dis, size);
 -            }
 -            return new RowIndexEntry(position);
 -        }
 -
 -        public RowIndexEntry deserialize(DataInput dis, Descriptor.Version version) throws
IOException
 -        {
 -            long position = dis.readLong();
 -            if (version.hasPromotedIndexes)
 -            {
 -                int size = dis.readInt();
 +                int size = in.readInt();
                  if (size > 0)
                  {
 -                    DeletionInfo delInfo = DeletionInfo.serializer().deserializeFromSSTable(dis,
version);
 -                    int entries = dis.readInt();
 +                    DeletionInfo delInfo = DeletionInfo.serializer().deserializeFromSSTable(in,
version);
 +                    int entries = in.readInt();
                      List<IndexHelper.IndexInfo> columnsIndex = new ArrayList<IndexHelper.IndexInfo>(entries);
                      for (int i = 0; i < entries; i++)
 -                        columnsIndex.add(IndexHelper.IndexInfo.deserialize(dis));
 -                    IFilter bf = FilterFactory.deserialize(dis, version.filterType, false);
 -                    return new IndexedEntry(position, delInfo, columnsIndex, bf);
 +                        columnsIndex.add(IndexHelper.IndexInfo.deserialize(in));
 +
 +                    if (version.hasRowLevelBF)
-                         IndexHelper.skipBloomFilter(in);
++                        IndexHelper.skipBloomFilter(in, version.filterType);
 +                    return new IndexedEntry(position, delInfo, columnsIndex);
                  }
                  else
                  {

http://git-wip-us.apache.org/repos/asf/cassandra/blob/ae1f7be7/src/java/org/apache/cassandra/db/columniterator/IndexedSliceReader.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/cassandra/blob/ae1f7be7/src/java/org/apache/cassandra/db/columniterator/SSTableNamesIterator.java
----------------------------------------------------------------------
diff --cc src/java/org/apache/cassandra/db/columniterator/SSTableNamesIterator.java
index e7257bf,da4631d..6399993
--- a/src/java/org/apache/cassandra/db/columniterator/SSTableNamesIterator.java
+++ b/src/java/org/apache/cassandra/db/columniterator/SSTableNamesIterator.java
@@@ -130,7 -133,7 +130,7 @@@ public class SSTableNamesIterator exten
          else
          {
              assert file != null;
-             IndexHelper.skipBloomFilter(file);
 -            bf = IndexHelper.defreezeBloomFilter(file, sstable.descriptor.version.filterType);
++            IndexHelper.skipBloomFilter(file, sstable.descriptor.version.filterType );
              indexList = IndexHelper.deserializeIndex(file);
          }
  

http://git-wip-us.apache.org/repos/asf/cassandra/blob/ae1f7be7/src/java/org/apache/cassandra/db/columniterator/SimpleSliceReader.java
----------------------------------------------------------------------
diff --cc src/java/org/apache/cassandra/db/columniterator/SimpleSliceReader.java
index 1231710,132f9cb..26b0dfb
--- a/src/java/org/apache/cassandra/db/columniterator/SimpleSliceReader.java
+++ b/src/java/org/apache/cassandra/db/columniterator/SimpleSliceReader.java
@@@ -68,16 -72,17 +69,17 @@@ class SimpleSliceReader extends Abstrac
              ByteBufferUtil.skipShortLength(file);
              SSTableReader.readRowSize(file, sstable.descriptor);
  
-             if (!sstable.descriptor.version.hasPromotedIndexes)
+             Descriptor.Version version = sstable.descriptor.version;
+             if (!version.hasPromotedIndexes)
              {
 -                IndexHelper.skipBloomFilter(file, version.filterType);
 +                if(sstable.descriptor.version.hasRowLevelBF)
-                     IndexHelper.skipBloomFilter(file);
++                    IndexHelper.skipBloomFilter(file, version.filterType);
                  IndexHelper.skipIndex(file);
              }
  
              emptyColumnFamily = ColumnFamily.create(sstable.metadata);
-             emptyColumnFamily.delete(DeletionInfo.serializer().deserializeFromSSTable(file,
sstable.descriptor.version));
+             emptyColumnFamily.delete(DeletionInfo.serializer().deserializeFromSSTable(file,
version));
 -            atomSerializer = emptyColumnFamily.getOnDiskSerializer();
 -            columns = file.readInt();
 +            atomIterator = emptyColumnFamily.metadata().getOnDiskIterator(file, file.readInt(),
sstable.descriptor.version);
              mark = file.mark();
          }
          catch (IOException e)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/ae1f7be7/src/java/org/apache/cassandra/io/sstable/IndexHelper.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/cassandra/blob/ae1f7be7/src/java/org/apache/cassandra/io/sstable/SSTableIdentityIterator.java
----------------------------------------------------------------------
diff --cc src/java/org/apache/cassandra/io/sstable/SSTableIdentityIterator.java
index ceb1df3,157ccf8..dd068fb
--- a/src/java/org/apache/cassandra/io/sstable/SSTableIdentityIterator.java
+++ b/src/java/org/apache/cassandra/io/sstable/SSTableIdentityIterator.java
@@@ -126,7 -127,7 +126,7 @@@ public class SSTableIdentityIterator im
                  {
                      try
                      {
-                         IndexHelper.skipBloomFilter(file);
 -                        IndexHelper.defreezeBloomFilter(file, dataSize, dataVersion.filterType);
++                        IndexHelper.skipBloomFilter(file, dataVersion.filterType);
                      }
                      catch (Exception e)
                      {


Mime
View raw message