dethrive commented on code in PR #2089:
URL: https://github.com/apache/kylin/pull/2089#discussion_r1107395563


##########
src/core-metadata/src/main/java/org/apache/kylin/metadata/cube/model/RuleBasedIndex.java:
##########
@@ -348,6 +391,18 @@ Set<LayoutEntity> genCuboidLayouts(Set<LayoutEntity> 
previousLayouts, Set<Layout
         if (excludeDel) {
             genLayouts.removeIf(layout -> 
layoutBlackList.contains(layout.getId()));
         }
+
+        // If contains the `layout_cost_based_pruned_list`, will use layouts 
in the cost based planner list
+        if (useCostBasedList && layoutsOfCostBasedList != null) {
+            // use the recommend white list id
+            Set<LayoutEntity> result = Sets.newHashSet();
+            genLayouts.stream().forEach(layout -> {

Review Comment:
   直接 forEach 就可以了



-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to