ravipesala commented on a change in pull request #3177:
[CARBONDATA-3337][CARBONDATA-3306] Distributed index server
URL: https://github.com/apache/carbondata/pull/3177#discussion_r279636602
##########
File path:
core/src/main/java/org/apache/carbondata/core/datamap/TableDataMap.java
##########
@@ -491,14 +491,21 @@ public DataMapFactory getDataMapFactory() {
throws IOException {
List<Segment> prunedSegments = new
ArrayList<>(CarbonCommonConstants.DEFAULT_COLLECTION_SIZE);
for (Segment segment : segments) {
- List<DataMap> dataMaps = dataMapFactory.getDataMaps(segment);
- for (DataMap dataMap : dataMaps) {
- if (dataMap.isScanRequired(filterExp)) {
- // If any one task in a given segment contains the data that means
the segment need to
- // be scanned and we need to validate further data maps in the same
segment
- prunedSegments.add(segment);
- break;
- }
+ prunedSegments.addAll(pruneSegments(segment, filterExp));
+ }
+ return prunedSegments;
+ }
+
+ public List<Segment> pruneSegments(Segment segment, FilterResolverIntf
filterExp)
Review comment:
PLease remove if not used
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services