jihaozh commented on a change in pull request #4609: [TE][Composite-Alert] 
Entity Anomaly Merger
URL: https://github.com/apache/incubator-pinot/pull/4609#discussion_r323965562
 
 

 ##########
 File path: 
thirdeye/thirdeye-pinot/src/main/java/org/apache/pinot/thirdeye/detection/spi/model/AnomalySlice.java
 ##########
 @@ -20,29 +20,36 @@
 package org.apache.pinot.thirdeye.detection.spi.model;
 
 import com.google.common.collect.ArrayListMultimap;
+import com.google.common.collect.Collections2;
 import com.google.common.collect.Multimap;
+import java.util.List;
+import org.apache.commons.lang3.StringUtils;
 import org.apache.pinot.thirdeye.datalayer.dto.MergedAnomalyResultDTO;
 
+import static org.apache.pinot.thirdeye.detection.wrapper.GrouperWrapper.*;
+
 
 /**
  * Selector for anomalies based on (optionally) detector id, start time, end 
time, and
  * dimension filters.
  */
 public class AnomalySlice {
-  final long start;
-  final long end;
-  final Multimap<String, String> filters;
+  private final long start;
+  private final long end;
+  private  Multimap<String, String> filters;
+  private final List<String> detectionComponentNames;
+  private final boolean isTaggedAsChild;
 
   public AnomalySlice() {
-    this.start = -1;
-    this.end = -1;
-    this.filters = ArrayListMultimap.create();
+    this(-1, -1, ArrayListMultimap.create(), null, false);
   }
 
-  public AnomalySlice(long start, long end, Multimap<String, String> filters) {
+  public AnomalySlice(long start, long end, Multimap<String, String> filters, 
List<String> detectionComponentName, boolean includeChildAnomalies) {
     this.start = start;
     this.end = end;
     this.filters = filters;
+    this.detectionComponentNames = detectionComponentName;
+    this.isTaggedAsChild = includeChildAnomalies;
 
 Review comment:
   Maybe name the `isTaggedAsChild` instance variable as 
`includeChildAnomalies` too, which I think will be more clear.

----------------------------------------------------------------
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:
us...@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org

Reply via email to