cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From j...@apache.org
Subject svn commit: r1199273 - in /cassandra/trunk: ./ contrib/ interface/thrift/gen-java/org/apache/cassandra/thrift/ src/java/org/apache/cassandra/cql/ src/java/org/apache/cassandra/hadoop/
Date Tue, 08 Nov 2011 15:01:18 GMT
Author: jake
Date: Tue Nov  8 15:01:18 2011
New Revision: 1199273

URL: http://svn.apache.org/viewvc?rev=1199273&view=rev
Log:
merge from 1.0

Modified:
    cassandra/trunk/   (props changed)
    cassandra/trunk/CHANGES.txt
    cassandra/trunk/contrib/   (props changed)
    cassandra/trunk/interface/thrift/gen-java/org/apache/cassandra/thrift/Cassandra.java 
 (props changed)
    cassandra/trunk/interface/thrift/gen-java/org/apache/cassandra/thrift/Column.java   (props
changed)
    cassandra/trunk/interface/thrift/gen-java/org/apache/cassandra/thrift/InvalidRequestException.java
  (props changed)
    cassandra/trunk/interface/thrift/gen-java/org/apache/cassandra/thrift/NotFoundException.java
  (props changed)
    cassandra/trunk/interface/thrift/gen-java/org/apache/cassandra/thrift/SuperColumn.java
  (props changed)
    cassandra/trunk/src/java/org/apache/cassandra/cql/QueryProcessor.java
    cassandra/trunk/src/java/org/apache/cassandra/hadoop/ColumnFamilyRecordReader.java

Propchange: cassandra/trunk/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Nov  8 15:01:18 2011
@@ -1,10 +1,10 @@
 /cassandra/branches/cassandra-0.6:922689-1052356,1052358-1053452,1053454,1053456-1131291
 /cassandra/branches/cassandra-0.7:1026516-1183000
 /cassandra/branches/cassandra-0.7.0:1053690-1055654
-/cassandra/branches/cassandra-0.8:1090934-1125013,1125019-1196961,1197786
+/cassandra/branches/cassandra-0.8:1090934-1125013,1125019-1198724,1198726-1199259
 /cassandra/branches/cassandra-0.8.0:1125021-1130369
 /cassandra/branches/cassandra-0.8.1:1101014-1125018
-/cassandra/branches/cassandra-1.0:1167085-1199009
+/cassandra/branches/cassandra-1.0:1167085-1199271
 /cassandra/branches/cassandra-1.0.0:1167104-1167229,1167232-1181093,1181741,1181816,1181820,1182951,1183243
 /cassandra/tags/cassandra-0.7.0-rc3:1051699-1053689
 /cassandra/tags/cassandra-0.8.0-rc1:1102511-1125020

Modified: cassandra/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/cassandra/trunk/CHANGES.txt?rev=1199273&r1=1199272&r2=1199273&view=diff
==============================================================================
--- cassandra/trunk/CHANGES.txt (original)
+++ cassandra/trunk/CHANGES.txt Tue Nov  8 15:01:18 2011
@@ -7,12 +7,17 @@
 
 
 1.0.3
- * (Hadoop) Fix empty row filtering (CASSANDRA-3450)
  * fix invalidate-related test failures (CASSANDRA-3437)
  * add next-gen cqlsh to bin/
+ * (CQL) fix handling of rows with no columns (CASSANDRA-3424)
 Merged from 0.8:
  * Make counter shard merging thread safe (CASSANDRA-3178)
-
+ * fix updating CF row_cache_provider (CASSANDRA-3414)
+ * CFMetaData.convertToThrift method to set RowCacheProvider (CASSANDRA-3405)
+ * acquire compactionlock during truncate (CASSANDRA-3399)
+ * fix displaying cfdef entries for super columnfamilies (CASSANDRA-3415)
+ * Make counter shard merging thread safe (CASSANDRA-3178)
+ * Revert CASSANDRA-2855
 
 1.0.2
  * "defragment" rows for name-based queries under STCS (CASSANDRA-2503)
@@ -32,7 +37,6 @@ Merged from 0.8:
  * acquire compactionlock during truncate (CASSANDRA-3399)
  * fix displaying cfdef entries for super columnfamilies (CASSANDRA-3415)
 
-
 1.0.1
  * acquire references during index build to prevent delete problems
    on Windows (CASSANDRA-3314)
@@ -76,6 +80,7 @@ Merged from 0.8:
  * expire dead gossip states based on time (CASSANDRA-2961)
  * improve CompactionTask extensibility (CASSANDRA-3330)
  * Allow one leveled compaction task to kick off another (CASSANDRA-3363)
+ * allow encryption only between datacenters (CASSANDRA-2802)
 Merged from 0.8:
  * fix truncate allowing data to be replayed post-restart (CASSANDRA-3297)
  * make iwriter final in IndexWriter to avoid NPE (CASSANDRA-2863)
@@ -109,7 +114,6 @@ Merged from 0.8:
    (CASSANDRA-3351)
  * remove incorrect optimization from slice read path (CASSANDRA-3390)
  * Fix race in AntiEntropyService (CASSANDRA-3400)
- * allow encryption only between datacenters (CASSANDRA-2802)
 
 1.0.0-final
  * close scrubbed sstable fd before deleting it (CASSANDRA-3318)
@@ -129,27 +133,6 @@ Merged from 0.8:
    compressed one (CASSANDRA-3338)
  * Fix hsha thrift server (CASSANDRA-3346)
  * Make sure repair only stream needed sstables (CASSANDRA-3345)
-Merged from 0.8:
- * Fix tool .bat files when CASSANDRA_HOME contains spaces (CASSANDRA-3258)
- * Force flush of status table when removing/updating token (CASSANDRA-3243)
- * Evict gossip state immediately when a token is taken over by a new IP (CASSANDRA-3259)
- * Fix bug where the failure detector can take too long to mark a host
-   down (CASSANDRA-3273)
- * (Hadoop) allow wrapping ranges in queries (CASSANDRA-3137)
- * (Hadoop) check all interfaces for a match with split location
-   before falling back to random replica (CASSANDRA-3211)
- * (Hadoop) Make Pig storage handle implements LoadMetadata (CASSANDRA-2777)
- * (Hadoop) Fix exception during PIG 'dump' (CASSANDRA-2810)
- * Fix stress COUNTER_GET option (CASSANDRA-3301)
- * Fix missing fields in CLI `show schema` output (CASSANDRA-3304)
- * Nodetool no longer leaks threads and closes JMX connections (CASSANDRA-3309)
- * fix truncate allowing data to be replayed post-restart (CASSANDRA-3297)
- * Move SimpleAuthority and SimpleAuthenticator to examples (CASSANDRA-2922)
- * Fix handling of tombstone by SSTableExport/Import (CASSANDRA-3357)
- * Fix transposition in cfHistograms (CASSANDRA-3222)
- * Allow using number as DC name when creating keyspace in CQL (CASSANDRA-3239)
- * Force flush of system table after updating/removing a token (CASSANDRA-3243)
-
 
 1.0.0-rc2
  * Log a meaningful warning when a node receives a message for a repair session
@@ -173,7 +156,6 @@ Merged from 0.8:
  * Evict gossip state immediately when a token is taken over by a new IP 
    (CASSANDRA-3259)
 
-
 1.0.0-rc1
  * Update CQL to generate microsecond timestamps by default (CASSANDRA-3227)
  * Fix counting CFMetadata towards Memtable liveRatio (CASSANDRA-3023)
@@ -194,8 +176,7 @@ Merged from 0.8:
  * Don't allow any cache loading exceptions to halt startup (CASSANDRA-3218)
  * Fix sstableloader --ignores option (CASSANDRA-3247)
  * File descriptor limit increased in packaging (CASSANDRA-3206)
- * Fix deadlock in commit log during flush (CASSANDRA-3253)
- 
+ * Fix deadlock in commit log during flush (CASSANDRA-3253) 
 
 1.0.0-beta1
  * removed binarymemtable (CASSANDRA-2692)
@@ -283,6 +264,40 @@ Merged from 0.8:
  * Pluggable compaction strategy (CASSANDRA-1610)
  * Add new broadcast_address config option (CASSANDRA-2491)
 
+0.8.7
+ * Kill server on wrapped OOME such as from FileChannel.map (CASSANDRA-3201)
+ * Allow using quotes in "USE <keyspace>;" CLI command (CASSANDRA-3208)
+ * Log message when a full repair operation completes (CASSANDRA-3207)
+ * Don't allow any cache loading exceptions to halt startup (CASSANDRA-3218)
+ * Fix sstableloader --ignores option (CASSANDRA-3247)
+ * File descriptor limit increased in packaging (CASSANDRA-3206)
+ * Log a meaningfull warning when a node receive a message for a repair session
+   that doesn't exist anymore (CASSANDRA-3256)
+ * Fix FD leak when internode encryption is enabled (CASSANDRA-3257)
+ * FBUtilities.hexToBytes(String) to throw NumberFormatException when string
+   contains non-hex characters (CASSANDRA-3231)
+ * Keep SimpleSnitch proximity ordering unchanged from what the Strategy
+   generates, as intended (CASSANDRA-3262)
+ * remove Scrub from compactionstats when finished (CASSANDRA-3255)
+ * Fix tool .bat files when CASSANDRA_HOME contains spaces (CASSANDRA-3258)
+ * Force flush of status table when removing/updating token (CASSANDRA-3243)
+ * Evict gossip state immediately when a token is taken over by a new IP (CASSANDRA-3259)
+ * Fix bug where the failure detector can take too long to mark a host
+   down (CASSANDRA-3273)
+ * (Hadoop) allow wrapping ranges in queries (CASSANDRA-3137)
+ * (Hadoop) check all interfaces for a match with split location
+   before falling back to random replica (CASSANDRA-3211)
+ * (Hadoop) Make Pig storage handle implements LoadMetadata (CASSANDRA-2777)
+ * (Hadoop) Fix exception during PIG 'dump' (CASSANDRA-2810)
+ * Fix stress COUNTER_GET option (CASSANDRA-3301)
+ * Fix missing fields in CLI `show schema` output (CASSANDRA-3304)
+ * Nodetool no longer leaks threads and closes JMX connections (CASSANDRA-3309)
+ * fix truncate allowing data to be replayed post-restart (CASSANDRA-3297)
+ * Move SimpleAuthority and SimpleAuthenticator to examples (CASSANDRA-2922)
+ * Fix handling of tombstone by SSTableExport/Import (CASSANDRA-3357)
+ * Fix transposition in cfHistograms (CASSANDRA-3222)
+ * Allow using number as DC name when creating keyspace in CQL (CASSANDRA-3239)
+ * Force flush of system table after updating/removing a token (CASSANDRA-3243)
 
 0.8.6
  * revert CASSANDRA-2388

Propchange: cassandra/trunk/contrib/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Nov  8 15:01:18 2011
@@ -1,10 +1,10 @@
 /cassandra/branches/cassandra-0.6/contrib:922689-1052356,1052358-1053452,1053454,1053456-1068009
 /cassandra/branches/cassandra-0.7/contrib:1026516-1183000
 /cassandra/branches/cassandra-0.7.0/contrib:1053690-1055654
-/cassandra/branches/cassandra-0.8/contrib:1090934-1125013,1125019-1196961,1197786
+/cassandra/branches/cassandra-0.8/contrib:1090934-1125013,1125019-1198724,1198726-1199259
 /cassandra/branches/cassandra-0.8.0/contrib:1125021-1130369
 /cassandra/branches/cassandra-0.8.1/contrib:1101014-1125018
-/cassandra/branches/cassandra-1.0/contrib:1167085-1199009
+/cassandra/branches/cassandra-1.0/contrib:1167085-1199271
 /cassandra/branches/cassandra-1.0.0/contrib:1167104-1167229,1167232-1181093,1181741,1181816,1181820,1182951,1183243
 /cassandra/tags/cassandra-0.7.0-rc3/contrib:1051699-1053689
 /cassandra/tags/cassandra-0.8.0-rc1/contrib:1102511-1125020

Propchange: cassandra/trunk/interface/thrift/gen-java/org/apache/cassandra/thrift/Cassandra.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Nov  8 15:01:18 2011
@@ -1,10 +1,10 @@
 /cassandra/branches/cassandra-0.6/interface/thrift/gen-java/org/apache/cassandra/thrift/Cassandra.java:922689-1052356,1052358-1053452,1053454,1053456-1131291
 /cassandra/branches/cassandra-0.7/interface/thrift/gen-java/org/apache/cassandra/thrift/Cassandra.java:1026516-1183000
 /cassandra/branches/cassandra-0.7.0/interface/thrift/gen-java/org/apache/cassandra/thrift/Cassandra.java:1053690-1055654
-/cassandra/branches/cassandra-0.8/interface/thrift/gen-java/org/apache/cassandra/thrift/Cassandra.java:1090934-1125013,1125019-1196961,1197786
+/cassandra/branches/cassandra-0.8/interface/thrift/gen-java/org/apache/cassandra/thrift/Cassandra.java:1090934-1125013,1125019-1198724,1198726-1199259
 /cassandra/branches/cassandra-0.8.0/interface/thrift/gen-java/org/apache/cassandra/thrift/Cassandra.java:1125021-1130369
 /cassandra/branches/cassandra-0.8.1/interface/thrift/gen-java/org/apache/cassandra/thrift/Cassandra.java:1101014-1125018
-/cassandra/branches/cassandra-1.0/interface/thrift/gen-java/org/apache/cassandra/thrift/Cassandra.java:1167085-1199009
+/cassandra/branches/cassandra-1.0/interface/thrift/gen-java/org/apache/cassandra/thrift/Cassandra.java:1167085-1199271
 /cassandra/branches/cassandra-1.0.0/interface/thrift/gen-java/org/apache/cassandra/thrift/Cassandra.java:1167104-1167229,1167232-1181093,1181741,1181816,1181820,1182951,1183243
 /cassandra/tags/cassandra-0.7.0-rc3/interface/thrift/gen-java/org/apache/cassandra/thrift/Cassandra.java:1051699-1053689
 /cassandra/tags/cassandra-0.8.0-rc1/interface/thrift/gen-java/org/apache/cassandra/thrift/Cassandra.java:1102511-1125020

Propchange: cassandra/trunk/interface/thrift/gen-java/org/apache/cassandra/thrift/Column.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Nov  8 15:01:18 2011
@@ -1,10 +1,10 @@
 /cassandra/branches/cassandra-0.6/interface/thrift/gen-java/org/apache/cassandra/thrift/Column.java:922689-1052356,1052358-1053452,1053454,1053456-1131291
 /cassandra/branches/cassandra-0.7/interface/thrift/gen-java/org/apache/cassandra/thrift/Column.java:1026516-1183000
 /cassandra/branches/cassandra-0.7.0/interface/thrift/gen-java/org/apache/cassandra/thrift/Column.java:1053690-1055654
-/cassandra/branches/cassandra-0.8/interface/thrift/gen-java/org/apache/cassandra/thrift/Column.java:1090934-1125013,1125019-1196961,1197786
+/cassandra/branches/cassandra-0.8/interface/thrift/gen-java/org/apache/cassandra/thrift/Column.java:1090934-1125013,1125019-1198724,1198726-1199259
 /cassandra/branches/cassandra-0.8.0/interface/thrift/gen-java/org/apache/cassandra/thrift/Column.java:1125021-1130369
 /cassandra/branches/cassandra-0.8.1/interface/thrift/gen-java/org/apache/cassandra/thrift/Column.java:1101014-1125018
-/cassandra/branches/cassandra-1.0/interface/thrift/gen-java/org/apache/cassandra/thrift/Column.java:1167085-1199009
+/cassandra/branches/cassandra-1.0/interface/thrift/gen-java/org/apache/cassandra/thrift/Column.java:1167085-1199271
 /cassandra/branches/cassandra-1.0.0/interface/thrift/gen-java/org/apache/cassandra/thrift/Column.java:1167104-1167229,1167232-1181093,1181741,1181816,1181820,1182951,1183243
 /cassandra/tags/cassandra-0.7.0-rc3/interface/thrift/gen-java/org/apache/cassandra/thrift/Column.java:1051699-1053689
 /cassandra/tags/cassandra-0.8.0-rc1/interface/thrift/gen-java/org/apache/cassandra/thrift/Column.java:1102511-1125020

Propchange: cassandra/trunk/interface/thrift/gen-java/org/apache/cassandra/thrift/InvalidRequestException.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Nov  8 15:01:18 2011
@@ -1,10 +1,10 @@
 /cassandra/branches/cassandra-0.6/interface/thrift/gen-java/org/apache/cassandra/thrift/InvalidRequestException.java:922689-1052356,1052358-1053452,1053454,1053456-1131291
 /cassandra/branches/cassandra-0.7/interface/thrift/gen-java/org/apache/cassandra/thrift/InvalidRequestException.java:1026516-1183000
 /cassandra/branches/cassandra-0.7.0/interface/thrift/gen-java/org/apache/cassandra/thrift/InvalidRequestException.java:1053690-1055654
-/cassandra/branches/cassandra-0.8/interface/thrift/gen-java/org/apache/cassandra/thrift/InvalidRequestException.java:1090934-1125013,1125019-1196961,1197786
+/cassandra/branches/cassandra-0.8/interface/thrift/gen-java/org/apache/cassandra/thrift/InvalidRequestException.java:1090934-1125013,1125019-1198724,1198726-1199259
 /cassandra/branches/cassandra-0.8.0/interface/thrift/gen-java/org/apache/cassandra/thrift/InvalidRequestException.java:1125021-1130369
 /cassandra/branches/cassandra-0.8.1/interface/thrift/gen-java/org/apache/cassandra/thrift/InvalidRequestException.java:1101014-1125018
-/cassandra/branches/cassandra-1.0/interface/thrift/gen-java/org/apache/cassandra/thrift/InvalidRequestException.java:1167085-1199009
+/cassandra/branches/cassandra-1.0/interface/thrift/gen-java/org/apache/cassandra/thrift/InvalidRequestException.java:1167085-1199271
 /cassandra/branches/cassandra-1.0.0/interface/thrift/gen-java/org/apache/cassandra/thrift/InvalidRequestException.java:1167104-1167229,1167232-1181093,1181741,1181816,1181820,1182951,1183243
 /cassandra/tags/cassandra-0.7.0-rc3/interface/thrift/gen-java/org/apache/cassandra/thrift/InvalidRequestException.java:1051699-1053689
 /cassandra/tags/cassandra-0.8.0-rc1/interface/thrift/gen-java/org/apache/cassandra/thrift/InvalidRequestException.java:1102511-1125020

Propchange: cassandra/trunk/interface/thrift/gen-java/org/apache/cassandra/thrift/NotFoundException.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Nov  8 15:01:18 2011
@@ -1,10 +1,10 @@
 /cassandra/branches/cassandra-0.6/interface/thrift/gen-java/org/apache/cassandra/thrift/NotFoundException.java:922689-1052356,1052358-1053452,1053454,1053456-1131291
 /cassandra/branches/cassandra-0.7/interface/thrift/gen-java/org/apache/cassandra/thrift/NotFoundException.java:1026516-1183000
 /cassandra/branches/cassandra-0.7.0/interface/thrift/gen-java/org/apache/cassandra/thrift/NotFoundException.java:1053690-1055654
-/cassandra/branches/cassandra-0.8/interface/thrift/gen-java/org/apache/cassandra/thrift/NotFoundException.java:1090934-1125013,1125019-1196961,1197786
+/cassandra/branches/cassandra-0.8/interface/thrift/gen-java/org/apache/cassandra/thrift/NotFoundException.java:1090934-1125013,1125019-1198724,1198726-1199259
 /cassandra/branches/cassandra-0.8.0/interface/thrift/gen-java/org/apache/cassandra/thrift/NotFoundException.java:1125021-1130369
 /cassandra/branches/cassandra-0.8.1/interface/thrift/gen-java/org/apache/cassandra/thrift/NotFoundException.java:1101014-1125018
-/cassandra/branches/cassandra-1.0/interface/thrift/gen-java/org/apache/cassandra/thrift/NotFoundException.java:1167085-1199009
+/cassandra/branches/cassandra-1.0/interface/thrift/gen-java/org/apache/cassandra/thrift/NotFoundException.java:1167085-1199271
 /cassandra/branches/cassandra-1.0.0/interface/thrift/gen-java/org/apache/cassandra/thrift/NotFoundException.java:1167104-1167229,1167232-1181093,1181741,1181816,1181820,1182951,1183243
 /cassandra/tags/cassandra-0.7.0-rc3/interface/thrift/gen-java/org/apache/cassandra/thrift/NotFoundException.java:1051699-1053689
 /cassandra/tags/cassandra-0.8.0-rc1/interface/thrift/gen-java/org/apache/cassandra/thrift/NotFoundException.java:1102511-1125020

Propchange: cassandra/trunk/interface/thrift/gen-java/org/apache/cassandra/thrift/SuperColumn.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Nov  8 15:01:18 2011
@@ -1,10 +1,10 @@
 /cassandra/branches/cassandra-0.6/interface/thrift/gen-java/org/apache/cassandra/thrift/SuperColumn.java:922689-1052356,1052358-1053452,1053454,1053456-1131291
 /cassandra/branches/cassandra-0.7/interface/thrift/gen-java/org/apache/cassandra/thrift/SuperColumn.java:1026516-1183000
 /cassandra/branches/cassandra-0.7.0/interface/thrift/gen-java/org/apache/cassandra/thrift/SuperColumn.java:1053690-1055654
-/cassandra/branches/cassandra-0.8/interface/thrift/gen-java/org/apache/cassandra/thrift/SuperColumn.java:1090934-1125013,1125019-1196961,1197786
+/cassandra/branches/cassandra-0.8/interface/thrift/gen-java/org/apache/cassandra/thrift/SuperColumn.java:1090934-1125013,1125019-1198724,1198726-1199259
 /cassandra/branches/cassandra-0.8.0/interface/thrift/gen-java/org/apache/cassandra/thrift/SuperColumn.java:1125021-1130369
 /cassandra/branches/cassandra-0.8.1/interface/thrift/gen-java/org/apache/cassandra/thrift/SuperColumn.java:1101014-1125018
-/cassandra/branches/cassandra-1.0/interface/thrift/gen-java/org/apache/cassandra/thrift/SuperColumn.java:1167085-1199009
+/cassandra/branches/cassandra-1.0/interface/thrift/gen-java/org/apache/cassandra/thrift/SuperColumn.java:1167085-1199271
 /cassandra/branches/cassandra-1.0.0/interface/thrift/gen-java/org/apache/cassandra/thrift/SuperColumn.java:1167104-1167229,1167232-1181093,1181741,1181816,1181820,1182951,1183243
 /cassandra/tags/cassandra-0.7.0-rc3/interface/thrift/gen-java/org/apache/cassandra/thrift/SuperColumn.java:1051699-1053689
 /cassandra/tags/cassandra-0.8.0-rc1/interface/thrift/gen-java/org/apache/cassandra/thrift/SuperColumn.java:1102511-1125020

Modified: cassandra/trunk/src/java/org/apache/cassandra/cql/QueryProcessor.java
URL: http://svn.apache.org/viewvc/cassandra/trunk/src/java/org/apache/cassandra/cql/QueryProcessor.java?rev=1199273&r1=1199272&r2=1199273&view=diff
==============================================================================
--- cassandra/trunk/src/java/org/apache/cassandra/cql/QueryProcessor.java (original)
+++ cassandra/trunk/src/java/org/apache/cassandra/cql/QueryProcessor.java Tue Nov  8 15:01:18
2011
@@ -580,10 +580,6 @@ public class QueryProcessor
                 List<CqlRow> cqlRows = new ArrayList<CqlRow>();
                 for (org.apache.cassandra.db.Row row : rows)
                 {
-                    /// No results for this row
-                    if (row.cf == null)
-                        continue;
-
                     List<Column> thriftColumns = new ArrayList<Column>();
                     if (select.isColumnRange())
                     {
@@ -596,16 +592,19 @@ public class QueryProcessor
                         }
 
                         // preserve comparator order
-                        for (IColumn c : row.cf.getSortedColumns())
+                        if (row.cf != null)
                         {
-                            if (c.isMarkedForDelete())
-                                continue;
+                            for (IColumn c : row.cf.getSortedColumns())
+                            {
+                                if (c.isMarkedForDelete())
+                                    continue;
 
-                            ColumnDefinition cd = metadata.getColumnDefinition(c.name());
-                            if (cd != null)
-                                result.schema.value_types.put(c.name(), TypeParser.getShortName(cd.getValidator()));
+                                ColumnDefinition cd = metadata.getColumnDefinition(c.name());
+                                if (cd != null)
+                                    result.schema.value_types.put(c.name(), TypeParser.getShortName(cd.getValidator()));
 
-                            thriftColumns.add(thriftify(c));
+                                thriftColumns.add(thriftify(c));
+                            }
                         }
                     }
                     else

Modified: cassandra/trunk/src/java/org/apache/cassandra/hadoop/ColumnFamilyRecordReader.java
URL: http://svn.apache.org/viewvc/cassandra/trunk/src/java/org/apache/cassandra/hadoop/ColumnFamilyRecordReader.java?rev=1199273&r1=1199272&r2=1199273&view=diff
==============================================================================
--- cassandra/trunk/src/java/org/apache/cassandra/hadoop/ColumnFamilyRecordReader.java (original)
+++ cassandra/trunk/src/java/org/apache/cassandra/hadoop/ColumnFamilyRecordReader.java Tue
Nov  8 15:01:18 2011
@@ -98,7 +98,7 @@ public class ColumnFamilyRecordReader ex
         batchRowCount = ConfigHelper.getRangeBatchSize(conf);
         cfName = ConfigHelper.getInputColumnFamily(conf);
         consistencyLevel = ConsistencyLevel.valueOf(ConfigHelper.getReadConsistencyLevel(conf));
-
+        
         
         keyspace = ConfigHelper.getInputKeyspace(conf);
         
@@ -235,55 +235,40 @@ public class ColumnFamilyRecordReader ex
             {
                 startToken = split.getStartToken();
             } 
-
-            // The removal of empty CF rows could result in an empty List<KeySlice>
rows.
-            // Keep trying until we return on reaching the end of the range or rows is nonEmpty.
-            while (rows == null || rows.isEmpty()) {
-                if (startToken.equals(split.getEndToken()))
+            else if (startToken.equals(split.getEndToken()))
+            {
+                rows = null;
+                return;
+            }
+            
+            KeyRange keyRange = new KeyRange(batchRowCount)
+                                .setStart_token(startToken)
+                                .setEnd_token(split.getEndToken());
+            try
+            {
+                rows = client.get_range_slices(new ColumnParent(cfName),
+                                               predicate,
+                                               keyRange,
+                                               consistencyLevel);
+                  
+                // nothing new? reached the end
+                if (rows.isEmpty())
                 {
                     rows = null;
                     return;
                 }
-
-                KeyRange keyRange = new KeyRange(batchRowCount)
-                                    .setStart_token(startToken)
-                                    .setEnd_token(split.getEndToken());
-                try
-                {
-                    rows = client.get_range_slices(new ColumnParent(cfName),
-                                                   predicate,
-                                                   keyRange,
-                                                   consistencyLevel);
-
-                    // nothing new? reached the end
-                    if (rows.isEmpty())
-                    {
-                        rows = null;
-                        return;
-                    }
-
-                    // Pre-compute the last row key, before removing empty rows
-                    ByteBuffer lastRowKey = rows.get(rows.size() - 1).key;
-
-                    // only remove empty rows if the slice predicate is empty
-                    if (isPredicateEmpty(predicate))
-                    {
-                        Iterator<KeySlice> rowsIterator = rows.iterator();
-                        while (rowsIterator.hasNext())
-                            if (rowsIterator.next().columns.isEmpty())
-                                rowsIterator.remove();
-                    }
-
-                    // reset to iterate through the new batch
-                    i = 0;
-
-                    // prepare for the next slice to be read
-                    startToken = partitioner.getTokenFactory().toString(partitioner.getToken(lastRowKey));
-                }
-                catch (Exception e)
-                {
-                    throw new RuntimeException(e);
-                }
+                               
+                // reset to iterate through this new batch
+                i = 0;
+                
+                // prepare for the next slice to be read
+                KeySlice lastRow = rows.get(rows.size() - 1);
+                ByteBuffer rowkey = lastRow.key;
+                startToken = partitioner.getTokenFactory().toString(partitioner.getToken(rowkey));
+            }
+            catch (Exception e)
+            {
+                throw new RuntimeException(e);
             }
         }
 
@@ -354,18 +339,4 @@ public class ColumnFamilyRecordReader ex
             return sc;
         }
     }
-
-    private boolean isPredicateEmpty(SlicePredicate predicate)
-    {
-        if (predicate != null)
-            if (predicate.isSetSlice_range())
-            {
-                if (predicate.getSlice_range().getStart() != null || predicate.getSlice_range().getFinish()
!= null)
-                return false;
-            }
-            else if (predicate.isSetColumn_names())
-                return false;
-
-        return true;
-    }
 }



Mime
View raw message