ravipesala commented on a change in pull request #3126: [WIP][CARBONDATA-3293] Prune datamaps improvement
URL:
https://github.com/apache/carbondata/pull/3126#discussion_r258030024
##########
File path: core/src/main/java/org/apache/carbondata/core/datamap/TableDataMap.java
##########
@@ -499,4 +501,26 @@ public DataMapFactory getDataMapFactory() {
}
return prunedSegments;
}
+
+ /**
+ * Prune the datamap of the given segments and return the Map of blocklet path and row count
+ *
+ * @param segments
+ * @param partitions
+ * @return
+ * @throws IOException
+ */
+ public Map<String, Integer> pruneBlockRowCount(List<Segment> segments,
+ final List<PartitionSpec> partitions) throws IOException {
+ Map<String, Integer> blockletToRowCountMap = new HashMap<>();
+ for (Segment segment : segments) {
+ List<CoarseGrainDataMap> dataMaps = dataMapFactory.getDataMaps(segment);
+ for (CoarseGrainDataMap dataMap : dataMaps) {
Review comment:
Not from all datamaps, it should be only from default datamap.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[hidden email]
With regards,
Apache Git Services