Rounding.java

1
/*
2
 * Copyright OpenSearch Contributors
3
 * SPDX-License-Identifier: Apache-2.0
4
 */
5
6
package org.opensearch.sql.planner.physical.collector;
7
8
import static org.opensearch.sql.data.type.ExprCoreType.DATE;
9
import static org.opensearch.sql.data.type.ExprCoreType.DATETIME;
10
import static org.opensearch.sql.data.type.ExprCoreType.DOUBLE;
11
import static org.opensearch.sql.data.type.ExprCoreType.LONG;
12
import static org.opensearch.sql.data.type.ExprCoreType.TIME;
13
import static org.opensearch.sql.data.type.ExprCoreType.TIMESTAMP;
14
15
import java.time.Instant;
16
import java.time.LocalDate;
17
import java.time.LocalDateTime;
18
import java.time.LocalTime;
19
import java.time.ZoneId;
20
import java.time.ZonedDateTime;
21
import java.time.temporal.ChronoField;
22
import java.util.Arrays;
23
import java.util.concurrent.TimeUnit;
24
import lombok.EqualsAndHashCode;
25
import lombok.Getter;
26
import lombok.RequiredArgsConstructor;
27
import org.opensearch.sql.data.model.ExprDateValue;
28
import org.opensearch.sql.data.model.ExprDatetimeValue;
29
import org.opensearch.sql.data.model.ExprTimeValue;
30
import org.opensearch.sql.data.model.ExprTimestampValue;
31
import org.opensearch.sql.data.model.ExprValue;
32
import org.opensearch.sql.data.model.ExprValueUtils;
33
import org.opensearch.sql.data.type.ExprType;
34
import org.opensearch.sql.exception.ExpressionEvaluationException;
35
import org.opensearch.sql.expression.span.SpanExpression;
36
import org.opensearch.sql.utils.DateTimeUtils;
37
38
/**
39
 * Rounding.
40
 */
41
@EqualsAndHashCode
42
public abstract class Rounding<T> {
43
  @Getter
44
  protected T maxRounded;
45
  @Getter
46
  protected T minRounded;
47
48
  /**
49
   * Create Rounding instance.
50
   */
51
  public static Rounding<?> createRounding(SpanExpression span) {
52
    ExprValue interval = span.getValue().valueOf();
53
    ExprType type = span.type();
54
55 1 1. createRounding : negated conditional → KILLED
    if (LONG.isCompatible(type)) {
56 1 1. createRounding : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding::createRounding → KILLED
      return new LongRounding(interval);
57
    }
58 1 1. createRounding : negated conditional → KILLED
    if (DOUBLE.isCompatible(type)) {
59 1 1. createRounding : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding::createRounding → KILLED
      return new DoubleRounding(interval);
60
    }
61 1 1. createRounding : negated conditional → KILLED
    if (type.equals(DATETIME)) {
62 1 1. createRounding : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding::createRounding → KILLED
      return new DatetimeRounding(interval, span.getUnit().getName());
63
    }
64 1 1. createRounding : negated conditional → KILLED
    if (type.equals(TIMESTAMP)) {
65 1 1. createRounding : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding::createRounding → KILLED
      return new TimestampRounding(interval, span.getUnit().getName());
66
    }
67 1 1. createRounding : negated conditional → KILLED
    if (type.equals(DATE)) {
68 1 1. createRounding : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding::createRounding → KILLED
      return new DateRounding(interval, span.getUnit().getName());
69
    }
70 1 1. createRounding : negated conditional → KILLED
    if (type.equals(TIME)) {
71 1 1. createRounding : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding::createRounding → KILLED
      return new TimeRounding(interval, span.getUnit().getName());
72
    }
73 1 1. createRounding : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding::createRounding → KILLED
    return new UnknownRounding();
74
  }
75
76
  public abstract ExprValue round(ExprValue value);
77
78
  public abstract Integer locate(ExprValue value);
79
80
  public abstract ExprValue[] createBuckets();
81
82
83
  static class TimestampRounding extends Rounding<Instant> {
84
    private final ExprValue interval;
85
    private final DateTimeUnit dateTimeUnit;
86
87
    public TimestampRounding(ExprValue interval, String unit) {
88
      this.interval = interval;
89
      this.dateTimeUnit = DateTimeUnit.resolve(unit);
90
    }
91
92
    @Override
93
    public ExprValue round(ExprValue var) {
94
      Instant instant = Instant.ofEpochMilli(dateTimeUnit.round(var.timestampValue()
95
          .toEpochMilli(), interval.integerValue()));
96 1 1. round : removed call to org/opensearch/sql/planner/physical/collector/Rounding$TimestampRounding::updateRounded → KILLED
      updateRounded(instant);
97 1 1. round : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$TimestampRounding::round → KILLED
      return new ExprTimestampValue(instant);
98
    }
99
100
    @Override
101
    public ExprValue[] createBuckets() {
102 1 1. createBuckets : negated conditional → KILLED
      if (dateTimeUnit.isMillisBased) {
103 4 1. createBuckets : Replaced long division with multiplication → SURVIVED
2. createBuckets : Replaced long subtraction with addition → TIMED_OUT
3. createBuckets : Replaced long multiplication with division → KILLED
4. createBuckets : Replaced integer addition with subtraction → KILLED
        int size = (int) ((maxRounded.toEpochMilli() - minRounded.toEpochMilli()) / (interval
104
            .integerValue() * dateTimeUnit.ratio)) + 1;
105 1 1. createBuckets : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$TimestampRounding::createBuckets → KILLED
        return new ExprValue[size];
106
      } else {
107
        ZonedDateTime maxZonedDateTime = maxRounded.atZone(ZoneId.of("UTC"));
108
        ZonedDateTime minZonedDateTime = minRounded.atZone(ZoneId.of("UTC"));
109
        int monthDiff = (maxZonedDateTime.getYear() - minZonedDateTime
110 4 1. createBuckets : Replaced integer subtraction with addition → SURVIVED
2. createBuckets : Replaced integer subtraction with addition → SURVIVED
3. createBuckets : Replaced integer multiplication with division → KILLED
4. createBuckets : Replaced integer addition with subtraction → KILLED
            .getYear()) * 12 + maxZonedDateTime.getMonthValue() - minZonedDateTime.getMonthValue();
111 3 1. createBuckets : Replaced integer division with multiplication → SURVIVED
2. createBuckets : Replaced integer multiplication with division → KILLED
3. createBuckets : Replaced integer addition with subtraction → KILLED
        int size = monthDiff / ((int) dateTimeUnit.ratio * interval.integerValue()) + 1;
112 1 1. createBuckets : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$TimestampRounding::createBuckets → KILLED
        return new ExprValue[size];
113
      }
114
    }
115
116
    @Override
117
    public Integer locate(ExprValue value) {
118 1 1. locate : negated conditional → KILLED
      if (dateTimeUnit.isMillisBased) {
119
        long intervalInEpochMillis = dateTimeUnit.ratio;
120 1 1. locate : replaced Integer return value with 0 for org/opensearch/sql/planner/physical/collector/Rounding$TimestampRounding::locate → KILLED
        return Long.valueOf((value.timestampValue()
121
            .atZone(ZoneId.of("UTC")).toInstant().toEpochMilli() - minRounded
122 1 1. locate : Replaced long subtraction with addition → KILLED
            .atZone(ZoneId.of("UTC")).toInstant().toEpochMilli()) / (intervalInEpochMillis
123 2 1. locate : Replaced long multiplication with division → KILLED
2. locate : Replaced long division with multiplication → KILLED
            * interval.integerValue())).intValue();
124
      } else {
125
        int monthDiff = (value.dateValue().getYear() - minRounded.atZone(ZoneId.of("UTC"))
126 3 1. locate : Replaced integer addition with subtraction → SURVIVED
2. locate : Replaced integer subtraction with addition → KILLED
3. locate : Replaced integer multiplication with division → KILLED
            .getYear()) * 12 + value.dateValue().getMonthValue() - minRounded
127 1 1. locate : Replaced integer subtraction with addition → SURVIVED
            .atZone(ZoneId.of("UTC")).getMonthValue();
128 3 1. locate : Replaced long multiplication with division → KILLED
2. locate : Replaced long division with multiplication → KILLED
3. locate : replaced Integer return value with 0 for org/opensearch/sql/planner/physical/collector/Rounding$TimestampRounding::locate → KILLED
        return (int) (monthDiff / (dateTimeUnit.ratio * interval.integerValue()));
129
      }
130
    }
131
132
    private void updateRounded(Instant value) {
133 2 1. updateRounded : negated conditional → KILLED
2. updateRounded : negated conditional → KILLED
      if (maxRounded == null || value.isAfter(maxRounded)) {
134
        maxRounded = value;
135
      }
136 2 1. updateRounded : negated conditional → KILLED
2. updateRounded : negated conditional → KILLED
      if (minRounded == null || value.isBefore(minRounded)) {
137
        minRounded = value;
138
      }
139
    }
140
  }
141
142
143
  static class DatetimeRounding extends Rounding<LocalDateTime> {
144
    private final ExprValue interval;
145
    private final DateTimeUnit dateTimeUnit;
146
147
    public DatetimeRounding(ExprValue interval, String unit) {
148
      this.interval = interval;
149
      this.dateTimeUnit = DateTimeUnit.resolve(unit);
150
    }
151
152
    @Override
153
    public ExprValue round(ExprValue var) {
154
      Instant instant = Instant.ofEpochMilli(dateTimeUnit.round(var.datetimeValue()
155
          .atZone(ZoneId.of("UTC")).toInstant().toEpochMilli(), interval.integerValue()));
156 1 1. round : removed call to org/opensearch/sql/planner/physical/collector/Rounding$DatetimeRounding::updateRounded → KILLED
      updateRounded(instant);
157 1 1. round : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DatetimeRounding::round → KILLED
      return new ExprDatetimeValue(instant.atZone(ZoneId.of("UTC")).toLocalDateTime());
158
    }
159
160
    @Override
161
    public ExprValue[] createBuckets() {
162 1 1. createBuckets : negated conditional → KILLED
      if (dateTimeUnit.isMillisBased) {
163
        int size = (int) ((maxRounded.atZone(ZoneId.of("UTC")).toInstant()
164
            .toEpochMilli() - minRounded.atZone(ZoneId.of("UTC")).toInstant()
165 4 1. createBuckets : Replaced long subtraction with addition → SURVIVED
2. createBuckets : Replaced long multiplication with division → KILLED
3. createBuckets : Replaced long division with multiplication → KILLED
4. createBuckets : Replaced integer addition with subtraction → KILLED
            .toEpochMilli()) / (interval.integerValue() * dateTimeUnit.ratio)) + 1;
166 1 1. createBuckets : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DatetimeRounding::createBuckets → KILLED
        return new ExprValue[size];
167
      } else {
168
        ZonedDateTime maxZonedDateTime = maxRounded.atZone(ZoneId.of("UTC"));
169
        ZonedDateTime minZonedDateTime = minRounded.atZone(ZoneId.of("UTC"));
170
        int monthDiff = (maxZonedDateTime.getYear() - minZonedDateTime
171 4 1. createBuckets : Replaced integer subtraction with addition → SURVIVED
2. createBuckets : Replaced integer subtraction with addition → SURVIVED
3. createBuckets : Replaced integer multiplication with division → KILLED
4. createBuckets : Replaced integer addition with subtraction → KILLED
            .getYear()) * 12 + maxZonedDateTime.getMonthValue() - minZonedDateTime.getMonthValue();
172 3 1. createBuckets : Replaced integer division with multiplication → SURVIVED
2. createBuckets : Replaced integer multiplication with division → KILLED
3. createBuckets : Replaced integer addition with subtraction → KILLED
        int size = monthDiff / ((int) dateTimeUnit.ratio * interval.integerValue()) + 1;
173 1 1. createBuckets : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DatetimeRounding::createBuckets → KILLED
        return new ExprValue[size];
174
      }
175
    }
176
177
    @Override
178
    public Integer locate(ExprValue value) {
179 1 1. locate : negated conditional → KILLED
      if (dateTimeUnit.isMillisBased) {
180
        long intervalInEpochMillis = dateTimeUnit.ratio;
181 1 1. locate : replaced Integer return value with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DatetimeRounding::locate → KILLED
        return Long.valueOf((value.datetimeValue()
182
            .atZone(ZoneId.of("UTC")).toInstant().toEpochMilli() - minRounded
183 1 1. locate : Replaced long subtraction with addition → KILLED
            .atZone(ZoneId.of("UTC")).toInstant().toEpochMilli()) / (intervalInEpochMillis
184 2 1. locate : Replaced long multiplication with division → KILLED
2. locate : Replaced long division with multiplication → KILLED
            * interval.integerValue())).intValue();
185
      } else {
186 2 1. locate : Replaced integer subtraction with addition → KILLED
2. locate : Replaced integer multiplication with division → KILLED
        int monthDiff = (value.datetimeValue().getYear() - minRounded.getYear()) * 12
187 2 1. locate : Replaced integer addition with subtraction → KILLED
2. locate : Replaced integer subtraction with addition → KILLED
            + value.dateValue().getMonthValue() - minRounded.getMonthValue();
188 3 1. locate : Replaced long multiplication with division → KILLED
2. locate : Replaced long division with multiplication → KILLED
3. locate : replaced Integer return value with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DatetimeRounding::locate → KILLED
        return (int) (monthDiff / (dateTimeUnit.ratio * interval.integerValue()));
189
      }
190
    }
191
192
    private void updateRounded(Instant value) {
193 2 1. updateRounded : negated conditional → KILLED
2. updateRounded : negated conditional → KILLED
      if (maxRounded == null || value.isAfter(maxRounded
194
          .atZone(ZoneId.of("UTC")).toInstant())) {
195
        maxRounded = value.atZone(ZoneId.of("UTC")).toLocalDateTime();
196
      }
197 2 1. updateRounded : negated conditional → KILLED
2. updateRounded : negated conditional → KILLED
      if (minRounded == null || value.isBefore(minRounded
198
          .atZone(ZoneId.of("UTC")).toInstant())) {
199
        minRounded = value.atZone(ZoneId.of("UTC")).toLocalDateTime();
200
      }
201
    }
202
  }
203
204
205
  static class DateRounding extends Rounding<LocalDate> {
206
    private final ExprValue interval;
207
    private final DateTimeUnit dateTimeUnit;
208
209
    public DateRounding(ExprValue interval, String unit) {
210
      this.interval = interval;
211
      this.dateTimeUnit = DateTimeUnit.resolve(unit);
212
    }
213
214
    @Override
215
    public ExprValue round(ExprValue var) {
216
      Instant instant = Instant.ofEpochMilli(dateTimeUnit.round(var.dateValue().atStartOfDay()
217
          .atZone(ZoneId.of("UTC")).toInstant().toEpochMilli(), interval.integerValue()));
218 1 1. round : removed call to org/opensearch/sql/planner/physical/collector/Rounding$DateRounding::updateRounded → KILLED
      updateRounded(instant);
219 1 1. round : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DateRounding::round → KILLED
      return new ExprDateValue(instant.atZone(ZoneId.of("UTC")).toLocalDate());
220
    }
221
222
    @Override
223
    public ExprValue[] createBuckets() {
224 1 1. createBuckets : negated conditional → KILLED
      if (dateTimeUnit.isMillisBased) {
225
        int size = (int) ((maxRounded.atStartOfDay().atZone(ZoneId.of("UTC")).toInstant()
226
            .toEpochMilli() - minRounded.atStartOfDay().atZone(ZoneId.of("UTC")).toInstant()
227 4 1. createBuckets : Replaced long subtraction with addition → SURVIVED
2. createBuckets : Replaced long division with multiplication → TIMED_OUT
3. createBuckets : Replaced long multiplication with division → KILLED
4. createBuckets : Replaced integer addition with subtraction → KILLED
            .toEpochMilli()) / (interval.integerValue() * dateTimeUnit.ratio)) + 1;
228 1 1. createBuckets : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DateRounding::createBuckets → KILLED
        return new ExprValue[size];
229
      } else {
230
        ZonedDateTime maxZonedDateTime = maxRounded.atStartOfDay().atZone(ZoneId.of("UTC"));
231
        ZonedDateTime minZonedDateTime = minRounded.atStartOfDay().atZone(ZoneId.of("UTC"));
232
        int monthDiff = (maxZonedDateTime.getYear() - minZonedDateTime
233 4 1. createBuckets : Replaced integer subtraction with addition → SURVIVED
2. createBuckets : Replaced integer subtraction with addition → SURVIVED
3. createBuckets : Replaced integer multiplication with division → KILLED
4. createBuckets : Replaced integer addition with subtraction → KILLED
            .getYear()) * 12 + maxZonedDateTime.getMonthValue() - minZonedDateTime.getMonthValue();
234 3 1. createBuckets : Replaced integer multiplication with division → SURVIVED
2. createBuckets : Replaced integer division with multiplication → SURVIVED
3. createBuckets : Replaced integer addition with subtraction → KILLED
        int size = monthDiff / ((int) dateTimeUnit.ratio * interval.integerValue()) + 1;
235 1 1. createBuckets : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DateRounding::createBuckets → KILLED
        return new ExprValue[size];
236
      }
237
    }
238
239
    @Override
240
    public Integer locate(ExprValue value) {
241 1 1. locate : negated conditional → KILLED
      if (dateTimeUnit.isMillisBased) {
242
        long intervalInEpochMillis = dateTimeUnit.ratio;
243 1 1. locate : replaced Integer return value with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DateRounding::locate → KILLED
        return Long.valueOf((value.dateValue().atStartOfDay()
244
            .atZone(ZoneId.of("UTC")).toInstant().toEpochMilli() - minRounded.atStartOfDay()
245 1 1. locate : Replaced long subtraction with addition → KILLED
            .atZone(ZoneId.of("UTC")).toInstant().toEpochMilli()) / (intervalInEpochMillis
246 2 1. locate : Replaced long multiplication with division → KILLED
2. locate : Replaced long division with multiplication → KILLED
            * interval.integerValue())).intValue();
247
      } else {
248 2 1. locate : Replaced integer subtraction with addition → KILLED
2. locate : Replaced integer multiplication with division → KILLED
        int monthDiff = (value.dateValue().getYear() - minRounded.getYear()) * 12
249 2 1. locate : Replaced integer addition with subtraction → KILLED
2. locate : Replaced integer subtraction with addition → KILLED
            + value.dateValue().getMonthValue() - minRounded.getMonthValue();
250 3 1. locate : Replaced long multiplication with division → SURVIVED
2. locate : Replaced long division with multiplication → SURVIVED
3. locate : replaced Integer return value with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DateRounding::locate → KILLED
        return (int) (monthDiff / (dateTimeUnit.ratio * interval.integerValue()));
251
      }
252
    }
253
254
    private void updateRounded(Instant value) {
255 2 1. updateRounded : negated conditional → KILLED
2. updateRounded : negated conditional → KILLED
      if (maxRounded == null || value.isAfter(maxRounded.atStartOfDay()
256
          .atZone(ZoneId.of("UTC")).toInstant())) {
257
        maxRounded = value.atZone(ZoneId.of("UTC")).toLocalDate();
258
      }
259 2 1. updateRounded : negated conditional → KILLED
2. updateRounded : negated conditional → KILLED
      if (minRounded == null || value.isBefore(minRounded.atStartOfDay()
260
          .atZone(ZoneId.of("UTC")).toInstant())) {
261
        minRounded = value.atZone(ZoneId.of("UTC")).toLocalDate();
262
      }
263
    }
264
  }
265
266
  static class TimeRounding extends Rounding<LocalTime> {
267
    private final ExprValue interval;
268
    private final DateTimeUnit dateTimeUnit;
269
270
    public TimeRounding(ExprValue interval, String unit) {
271
      this.interval = interval;
272
      this.dateTimeUnit = DateTimeUnit.resolve(unit);
273
    }
274
275
    @Override
276
    public ExprValue round(ExprValue var) {
277 2 1. round : changed conditional boundary → KILLED
2. round : negated conditional → KILLED
      if (dateTimeUnit.id > 4) {
278
        throw new ExpressionEvaluationException(String
279
            .format("Unable to set span unit %s for TIME type", dateTimeUnit.getName()));
280
      }
281
282
      Instant instant = Instant.ofEpochMilli(dateTimeUnit.round(var.timeValue().getLong(
283
          ChronoField.MILLI_OF_DAY), interval.integerValue()));
284 1 1. round : removed call to org/opensearch/sql/planner/physical/collector/Rounding$TimeRounding::updateRounded → KILLED
      updateRounded(instant);
285 1 1. round : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$TimeRounding::round → KILLED
      return new ExprTimeValue(instant.atZone(ZoneId.of("UTC")).toLocalTime());
286
    }
287
288
    @Override
289
    public ExprValue[] createBuckets() {
290
      // local time is converted to timestamp on 1970-01-01 for aggregations
291
      int size = (int) ((maxRounded.atDate(LocalDate.of(1970, 1, 1))
292
          .atZone(ZoneId.of("UTC")).toInstant().toEpochMilli() - minRounded
293
          .atDate(LocalDate.of(1970, 1, 1)).atZone(ZoneId.of("UTC")).toInstant()
294 4 1. createBuckets : Replaced long subtraction with addition → SURVIVED
2. createBuckets : Replaced long multiplication with division → KILLED
3. createBuckets : Replaced long division with multiplication → KILLED
4. createBuckets : Replaced integer addition with subtraction → KILLED
          .toEpochMilli()) / (interval.integerValue() * dateTimeUnit.ratio)) + 1;
295 1 1. createBuckets : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$TimeRounding::createBuckets → KILLED
      return new ExprValue[size];
296
    }
297
298
    @Override
299
    public Integer locate(ExprValue value) {
300
      long intervalInEpochMillis = dateTimeUnit.ratio;
301 1 1. locate : replaced Integer return value with 0 for org/opensearch/sql/planner/physical/collector/Rounding$TimeRounding::locate → KILLED
      return Long.valueOf((value.timeValue().atDate(LocalDate.of(1970, 1, 1))
302
          .atZone(ZoneId.of("UTC")).toInstant().toEpochMilli() - minRounded
303
          .atDate(LocalDate.of(1970, 1, 1))
304 3 1. locate : Replaced long subtraction with addition → KILLED
2. locate : Replaced long multiplication with division → KILLED
3. locate : Replaced long division with multiplication → KILLED
          .atZone(ZoneId.of("UTC")).toInstant().toEpochMilli()) / (intervalInEpochMillis * interval
305
          .integerValue())).intValue();
306
    }
307
308
    private void updateRounded(Instant value) {
309 2 1. updateRounded : negated conditional → KILLED
2. updateRounded : negated conditional → KILLED
      if (maxRounded == null || value.isAfter(maxRounded.atDate(LocalDate.of(1970, 1, 1))
310
          .atZone(ZoneId.of("UTC")).toInstant())) {
311
        maxRounded = value.atZone(ZoneId.of("UTC")).toLocalTime();
312
      }
313 1 1. updateRounded : negated conditional → KILLED
      if (minRounded == null) {
314
        minRounded = value.atZone(ZoneId.of("UTC")).toLocalTime();
315
      }
316
    }
317
  }
318
319
320
  static class LongRounding extends Rounding<Long> {
321
    private final Long longInterval;
322
323
    protected LongRounding(ExprValue interval) {
324
      longInterval = interval.longValue();
325
    }
326
327
    @Override
328
    public ExprValue round(ExprValue value) {
329 1 1. round : Replaced long multiplication with division → SURVIVED
      long rounded = Math.floorDiv(value.longValue(), longInterval) * longInterval;
330 1 1. round : removed call to org/opensearch/sql/planner/physical/collector/Rounding$LongRounding::updateRounded → KILLED
      updateRounded(rounded);
331 1 1. round : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$LongRounding::round → KILLED
      return ExprValueUtils.longValue(rounded);
332
    }
333
334
    @Override
335
    public Integer locate(ExprValue value) {
336 3 1. locate : Replaced long division with multiplication → SURVIVED
2. locate : Replaced long subtraction with addition → KILLED
3. locate : replaced Integer return value with 0 for org/opensearch/sql/planner/physical/collector/Rounding$LongRounding::locate → KILLED
      return Long.valueOf((value.longValue() - minRounded) / longInterval).intValue();
337
    }
338
339
    @Override
340
    public ExprValue[] createBuckets() {
341 3 1. createBuckets : Replaced long subtraction with addition → SURVIVED
2. createBuckets : Replaced long division with multiplication → SURVIVED
3. createBuckets : Replaced integer addition with subtraction → KILLED
      int size = Long.valueOf((maxRounded - minRounded) / longInterval).intValue() + 1;
342 1 1. createBuckets : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$LongRounding::createBuckets → KILLED
      return new ExprValue[size];
343
    }
344
345
    private void updateRounded(Long value) {
346 3 1. updateRounded : changed conditional boundary → SURVIVED
2. updateRounded : negated conditional → KILLED
3. updateRounded : negated conditional → KILLED
      if (maxRounded == null || value > maxRounded) {
347
        maxRounded = value;
348
      }
349 3 1. updateRounded : changed conditional boundary → SURVIVED
2. updateRounded : negated conditional → KILLED
3. updateRounded : negated conditional → KILLED
      if (minRounded == null || value < minRounded) {
350
        minRounded = value;
351
      }
352
    }
353
  }
354
355
356
  static class DoubleRounding extends Rounding<Double> {
357
    private final Double doubleInterval;
358
359
    protected DoubleRounding(ExprValue interval) {
360
      doubleInterval = interval.doubleValue();
361
    }
362
363
    @Override
364
    public ExprValue round(ExprValue value) {
365
      double rounded = Double
366 2 1. round : Replaced double division with multiplication → KILLED
2. round : Replaced double multiplication with division → KILLED
          .valueOf(value.doubleValue() / doubleInterval).intValue() * doubleInterval;
367 1 1. round : removed call to org/opensearch/sql/planner/physical/collector/Rounding$DoubleRounding::updateRounded → KILLED
      updateRounded(rounded);
368 1 1. round : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DoubleRounding::round → KILLED
      return ExprValueUtils.doubleValue(rounded);
369
    }
370
371
    @Override
372
    public Integer locate(ExprValue value) {
373 3 1. locate : Replaced double subtraction with addition → KILLED
2. locate : Replaced double division with multiplication → KILLED
3. locate : replaced Integer return value with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DoubleRounding::locate → KILLED
      return Double.valueOf((value.doubleValue() - minRounded) / doubleInterval).intValue();
374
    }
375
376
    @Override
377
    public ExprValue[] createBuckets() {
378 3 1. createBuckets : Replaced double subtraction with addition → SURVIVED
2. createBuckets : Replaced double division with multiplication → SURVIVED
3. createBuckets : Replaced integer addition with subtraction → KILLED
      int size = Double.valueOf((maxRounded - minRounded) / doubleInterval).intValue() + 1;
379 1 1. createBuckets : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DoubleRounding::createBuckets → KILLED
      return new ExprValue[size];
380
    }
381
382
    private void updateRounded(Double value) {
383 3 1. updateRounded : changed conditional boundary → SURVIVED
2. updateRounded : negated conditional → KILLED
3. updateRounded : negated conditional → KILLED
      if (maxRounded == null || value > maxRounded) {
384
        maxRounded = value;
385
      }
386 3 1. updateRounded : changed conditional boundary → SURVIVED
2. updateRounded : negated conditional → KILLED
3. updateRounded : negated conditional → KILLED
      if (minRounded == null || value < minRounded) {
387
        minRounded = value;
388
      }
389
    }
390
  }
391
392
393
  @RequiredArgsConstructor
394
  static class UnknownRounding extends Rounding<Object> {
395
    @Override
396
    public ExprValue round(ExprValue var) {
397
      return null;
398
    }
399
400
    @Override
401
    public Integer locate(ExprValue value) {
402 1 1. locate : replaced Integer return value with 0 for org/opensearch/sql/planner/physical/collector/Rounding$UnknownRounding::locate → KILLED
      return null;
403
    }
404
405
    @Override
406
    public ExprValue[] createBuckets() {
407 1 1. createBuckets : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$UnknownRounding::createBuckets → KILLED
      return new ExprValue[0];
408
    }
409
  }
410
411
412
  @RequiredArgsConstructor
413
  public enum DateTimeUnit {
414
    MILLISECOND(1, "ms", true, ChronoField.MILLI_OF_SECOND
415
        .getBaseUnit().getDuration().toMillis()) {
416
      @Override
417
      long round(long utcMillis, int interval) {
418 2 1. round : Replaced long multiplication with division → KILLED
2. round : replaced long return with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit$1::round → KILLED
        return DateTimeUtils.roundFloor(utcMillis, ratio * interval);
419
      }
420
    },
421
422
    SECOND(2, "s", true, ChronoField.SECOND_OF_MINUTE
423
        .getBaseUnit().getDuration().toMillis()) {
424
      @Override
425
      long round(long utcMillis, int interval) {
426 2 1. round : Replaced long multiplication with division → KILLED
2. round : replaced long return with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit$2::round → KILLED
        return DateTimeUtils.roundFloor(utcMillis, ratio * interval);
427
      }
428
    },
429
430
    MINUTE(3, "m", true, ChronoField.MINUTE_OF_HOUR
431
        .getBaseUnit().getDuration().toMillis()) {
432
      @Override
433
      long round(long utcMillis, int interval) {
434 2 1. round : Replaced long multiplication with division → KILLED
2. round : replaced long return with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit$3::round → KILLED
        return DateTimeUtils.roundFloor(utcMillis, ratio * interval);
435
      }
436
    },
437
438
    HOUR(4, "h", true, ChronoField.HOUR_OF_DAY
439
        .getBaseUnit().getDuration().toMillis()) {
440
      @Override
441
      long round(long utcMillis, int interval) {
442 2 1. round : Replaced long multiplication with division → SURVIVED
2. round : replaced long return with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit$4::round → KILLED
        return DateTimeUtils.roundFloor(utcMillis, ratio * interval);
443
      }
444
    },
445
446
    DAY(5, "d", true, ChronoField.DAY_OF_MONTH
447
        .getBaseUnit().getDuration().toMillis()) {
448
      @Override
449
      long round(long utcMillis, int interval) {
450 2 1. round : Replaced long multiplication with division → KILLED
2. round : replaced long return with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit$5::round → KILLED
        return DateTimeUtils.roundFloor(utcMillis, ratio * interval);
451
      }
452
    },
453
454
    WEEK(6, "w", true, TimeUnit.DAYS.toMillis(7L)) {
455
      @Override
456
      long round(long utcMillis, int interval) {
457 1 1. round : replaced long return with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit$6::round → KILLED
        return DateTimeUtils.roundWeek(utcMillis, interval);
458
      }
459
    },
460
461
    MONTH(7, "M", false, 1) {
462
      @Override
463
      long round(long utcMillis, int interval) {
464 1 1. round : replaced long return with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit$7::round → KILLED
        return DateTimeUtils.roundMonth(utcMillis, interval);
465
      }
466
    },
467
468
    QUARTER(8, "q", false, 3) {
469
      @Override
470
      long round(long utcMillis, int interval) {
471 1 1. round : replaced long return with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit$8::round → KILLED
        return DateTimeUtils.roundQuarter(utcMillis, interval);
472
      }
473
    },
474
475
    YEAR(9, "y", false, 12) {
476
      @Override
477
      long round(long utcMillis, int interval) {
478 1 1. round : replaced long return with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit$9::round → KILLED
        return DateTimeUtils.roundYear(utcMillis, interval);
479
      }
480
    };
481
482
    @Getter
483
    private final int id;
484
    @Getter
485
    private final String name;
486
    protected final boolean isMillisBased;
487
    protected final long ratio;
488
489
    abstract long round(long utcMillis, int interval);
490
491
    /**
492
     * Resolve the date time unit.
493
     */
494
    public static Rounding.DateTimeUnit resolve(String name) {
495
      switch (name) {
496
        case "M":
497 1 1. resolve : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit::resolve → KILLED
          return MONTH;
498
        case "m":
499 1 1. resolve : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit::resolve → KILLED
          return MINUTE;
500
        default:
501 1 1. resolve : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit::resolve → KILLED
          return Arrays.stream(values())
502 2 1. lambda$resolve$0 : replaced boolean return with false for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit::lambda$resolve$0 → KILLED
2. lambda$resolve$0 : replaced boolean return with true for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit::lambda$resolve$0 → KILLED
              .filter(v -> v.getName().equalsIgnoreCase(name))
503
              .findFirst()
504 1 1. lambda$resolve$1 : replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit::lambda$resolve$1 → KILLED
              .orElseThrow(() -> new IllegalArgumentException("Unable to resolve unit " + name));
505
      }
506
    }
507
  }
508
509
}

Mutations

55

1.1
Location : createRounding
Killed by : org.opensearch.sql.planner.physical.collector.RoundingTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.collector.RoundingTest]/[method:round_unknown_type()]
negated conditional → KILLED

56

1.1
Location : createRounding
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:integer_field()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding::createRounding → KILLED

58

1.1
Location : createRounding
Killed by : org.opensearch.sql.planner.physical.collector.RoundingTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.collector.RoundingTest]/[method:round_unknown_type()]
negated conditional → KILLED

59

1.1
Location : createRounding
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:double_field()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding::createRounding → KILLED

61

1.1
Location : createRounding
Killed by : org.opensearch.sql.planner.physical.collector.RoundingTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.collector.RoundingTest]/[method:round_unknown_type()]
negated conditional → KILLED

62

1.1
Location : createRounding
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:minute_span()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding::createRounding → KILLED

64

1.1
Location : createRounding
Killed by : org.opensearch.sql.planner.physical.collector.RoundingTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.collector.RoundingTest]/[method:round_unknown_type()]
negated conditional → KILLED

65

1.1
Location : createRounding
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:millisecond_span()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding::createRounding → KILLED

67

1.1
Location : createRounding
Killed by : org.opensearch.sql.planner.physical.collector.RoundingTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.collector.RoundingTest]/[method:round_unknown_type()]
negated conditional → KILLED

68

1.1
Location : createRounding
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:day_span()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding::createRounding → KILLED

70

1.1
Location : createRounding
Killed by : org.opensearch.sql.planner.physical.collector.RoundingTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.collector.RoundingTest]/[method:round_unknown_type()]
negated conditional → KILLED

71

1.1
Location : createRounding
Killed by : org.opensearch.sql.planner.physical.collector.RoundingTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.collector.RoundingTest]/[method:time_rounding_illegal_span()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding::createRounding → KILLED

73

1.1
Location : createRounding
Killed by : org.opensearch.sql.planner.physical.collector.RoundingTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.collector.RoundingTest]/[method:round_unknown_type()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding::createRounding → KILLED

96

1.1
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:millisecond_span()]
removed call to org/opensearch/sql/planner/physical/collector/Rounding$TimestampRounding::updateRounded → KILLED

97

1.1
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:millisecond_span()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$TimestampRounding::round → KILLED

102

1.1
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:millisecond_span()]
negated conditional → KILLED

103

1.1
Location : createBuckets
Killed by : none
Replaced long subtraction with addition → TIMED_OUT

2.2
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:second_span()]
Replaced long multiplication with division → KILLED

3.3
Location : createBuckets
Killed by : none
Replaced long division with multiplication → SURVIVED

4.4
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:millisecond_span()]
Replaced integer addition with subtraction → KILLED

105

1.1
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:millisecond_span()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$TimestampRounding::createBuckets → KILLED

110

1.1
Location : createBuckets
Killed by : none
Replaced integer subtraction with addition → SURVIVED

2.2
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:year_span()]
Replaced integer multiplication with division → KILLED

3.3
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:year_span()]
Replaced integer addition with subtraction → KILLED

4.4
Location : createBuckets
Killed by : none
Replaced integer subtraction with addition → SURVIVED

111

1.1
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:quarter_span()]
Replaced integer multiplication with division → KILLED

2.2
Location : createBuckets
Killed by : none
Replaced integer division with multiplication → SURVIVED

3.3
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:year_span()]
Replaced integer addition with subtraction → KILLED

112

1.1
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:year_span()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$TimestampRounding::createBuckets → KILLED

118

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:millisecond_span()]
negated conditional → KILLED

120

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:millisecond_span()]
replaced Integer return value with 0 for org/opensearch/sql/planner/physical/collector/Rounding$TimestampRounding::locate → KILLED

122

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:millisecond_span()]
Replaced long subtraction with addition → KILLED

123

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:millisecond_span()]
Replaced long multiplication with division → KILLED

2.2
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:millisecond_span()]
Replaced long division with multiplication → KILLED

126

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:year_span()]
Replaced integer subtraction with addition → KILLED

2.2
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:year_span()]
Replaced integer multiplication with division → KILLED

3.3
Location : locate
Killed by : none
Replaced integer addition with subtraction → SURVIVED

127

1.1
Location : locate
Killed by : none
Replaced integer subtraction with addition → SURVIVED

128

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:year_span()]
Replaced long multiplication with division → KILLED

2.2
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:year_span()]
Replaced long division with multiplication → KILLED

3.3
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:year_span()]
replaced Integer return value with 0 for org/opensearch/sql/planner/physical/collector/Rounding$TimestampRounding::locate → KILLED

133

1.1
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:millisecond_span()]
negated conditional → KILLED

2.2
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:millisecond_span()]
negated conditional → KILLED

136

1.1
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:millisecond_span()]
negated conditional → KILLED

2.2
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:millisecond_span()]
negated conditional → KILLED

156

1.1
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:minute_span()]
removed call to org/opensearch/sql/planner/physical/collector/Rounding$DatetimeRounding::updateRounded → KILLED

157

1.1
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:minute_span()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DatetimeRounding::round → KILLED

162

1.1
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:minute_span()]
negated conditional → KILLED

165

1.1
Location : createBuckets
Killed by : none
Replaced long subtraction with addition → SURVIVED

2.2
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:minute_span()]
Replaced long multiplication with division → KILLED

3.3
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:minute_span()]
Replaced long division with multiplication → KILLED

4.4
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:minute_span()]
Replaced integer addition with subtraction → KILLED

166

1.1
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:minute_span()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DatetimeRounding::createBuckets → KILLED

171

1.1
Location : createBuckets
Killed by : none
Replaced integer subtraction with addition → SURVIVED

2.2
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:quarter_span()]
Replaced integer multiplication with division → KILLED

3.3
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:quarter_span()]
Replaced integer addition with subtraction → KILLED

4.4
Location : createBuckets
Killed by : none
Replaced integer subtraction with addition → SURVIVED

172

1.1
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:month_span()]
Replaced integer multiplication with division → KILLED

2.2
Location : createBuckets
Killed by : none
Replaced integer division with multiplication → SURVIVED

3.3
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:quarter_span()]
Replaced integer addition with subtraction → KILLED

173

1.1
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:quarter_span()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DatetimeRounding::createBuckets → KILLED

179

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:minute_span()]
negated conditional → KILLED

181

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:minute_span()]
replaced Integer return value with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DatetimeRounding::locate → KILLED

183

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:minute_span()]
Replaced long subtraction with addition → KILLED

184

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:minute_span()]
Replaced long multiplication with division → KILLED

2.2
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:minute_span()]
Replaced long division with multiplication → KILLED

186

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:quarter_span()]
Replaced integer subtraction with addition → KILLED

2.2
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:quarter_span()]
Replaced integer multiplication with division → KILLED

187

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:quarter_span()]
Replaced integer addition with subtraction → KILLED

2.2
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:quarter_span()]
Replaced integer subtraction with addition → KILLED

188

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:quarter_span()]
Replaced long multiplication with division → KILLED

2.2
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:quarter_span()]
Replaced long division with multiplication → KILLED

3.3
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:quarter_span()]
replaced Integer return value with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DatetimeRounding::locate → KILLED

193

1.1
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:minute_span()]
negated conditional → KILLED

2.2
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:minute_span()]
negated conditional → KILLED

197

1.1
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:minute_span()]
negated conditional → KILLED

2.2
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:minute_span()]
negated conditional → KILLED

218

1.1
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:day_span()]
removed call to org/opensearch/sql/planner/physical/collector/Rounding$DateRounding::updateRounded → KILLED

219

1.1
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:day_span()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DateRounding::round → KILLED

224

1.1
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:day_span()]
negated conditional → KILLED

227

1.1
Location : createBuckets
Killed by : none
Replaced long subtraction with addition → SURVIVED

2.2
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:day_span()]
Replaced long multiplication with division → KILLED

3.3
Location : createBuckets
Killed by : none
Replaced long division with multiplication → TIMED_OUT

4.4
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:day_span()]
Replaced integer addition with subtraction → KILLED

228

1.1
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:day_span()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DateRounding::createBuckets → KILLED

233

1.1
Location : createBuckets
Killed by : none
Replaced integer subtraction with addition → SURVIVED

2.2
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:month_span()]
Replaced integer multiplication with division → KILLED

3.3
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:month_span()]
Replaced integer addition with subtraction → KILLED

4.4
Location : createBuckets
Killed by : none
Replaced integer subtraction with addition → SURVIVED

234

1.1
Location : createBuckets
Killed by : none
Replaced integer multiplication with division → SURVIVED

2.2
Location : createBuckets
Killed by : none
Replaced integer division with multiplication → SURVIVED

3.3
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:month_span()]
Replaced integer addition with subtraction → KILLED

235

1.1
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:month_span()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DateRounding::createBuckets → KILLED

241

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:day_span()]
negated conditional → KILLED

243

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:day_span()]
replaced Integer return value with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DateRounding::locate → KILLED

245

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:day_span()]
Replaced long subtraction with addition → KILLED

246

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:day_span()]
Replaced long multiplication with division → KILLED

2.2
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:day_span()]
Replaced long division with multiplication → KILLED

248

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:month_span()]
Replaced integer subtraction with addition → KILLED

2.2
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:month_span()]
Replaced integer multiplication with division → KILLED

249

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:month_span()]
Replaced integer addition with subtraction → KILLED

2.2
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:month_span()]
Replaced integer subtraction with addition → KILLED

250

1.1
Location : locate
Killed by : none
Replaced long multiplication with division → SURVIVED

2.2
Location : locate
Killed by : none
Replaced long division with multiplication → SURVIVED

3.3
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:month_span()]
replaced Integer return value with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DateRounding::locate → KILLED

255

1.1
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:day_span()]
negated conditional → KILLED

2.2
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:day_span()]
negated conditional → KILLED

259

1.1
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:day_span()]
negated conditional → KILLED

2.2
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:day_span()]
negated conditional → KILLED

277

1.1
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:hour_span()]
changed conditional boundary → KILLED

2.2
Location : round
Killed by : org.opensearch.sql.planner.physical.collector.RoundingTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.collector.RoundingTest]/[method:time_rounding_illegal_span()]
negated conditional → KILLED

284

1.1
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:hour_span()]
removed call to org/opensearch/sql/planner/physical/collector/Rounding$TimeRounding::updateRounded → KILLED

285

1.1
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:hour_span()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$TimeRounding::round → KILLED

294

1.1
Location : createBuckets
Killed by : none
Replaced long subtraction with addition → SURVIVED

2.2
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:hour_span()]
Replaced long multiplication with division → KILLED

3.3
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:hour_span()]
Replaced long division with multiplication → KILLED

4.4
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:hour_span()]
Replaced integer addition with subtraction → KILLED

295

1.1
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:hour_span()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$TimeRounding::createBuckets → KILLED

301

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:hour_span()]
replaced Integer return value with 0 for org/opensearch/sql/planner/physical/collector/Rounding$TimeRounding::locate → KILLED

304

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:hour_span()]
Replaced long subtraction with addition → KILLED

2.2
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:minute_span()]
Replaced long multiplication with division → KILLED

3.3
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:hour_span()]
Replaced long division with multiplication → KILLED

309

1.1
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:hour_span()]
negated conditional → KILLED

2.2
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:hour_span()]
negated conditional → KILLED

313

1.1
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:hour_span()]
negated conditional → KILLED

329

1.1
Location : round
Killed by : none
Replaced long multiplication with division → SURVIVED

330

1.1
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:integer_field()]
removed call to org/opensearch/sql/planner/physical/collector/Rounding$LongRounding::updateRounded → KILLED

331

1.1
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:integer_field()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$LongRounding::round → KILLED

336

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:integer_field()]
Replaced long subtraction with addition → KILLED

2.2
Location : locate
Killed by : none
Replaced long division with multiplication → SURVIVED

3.3
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:integer_field()]
replaced Integer return value with 0 for org/opensearch/sql/planner/physical/collector/Rounding$LongRounding::locate → KILLED

341

1.1
Location : createBuckets
Killed by : none
Replaced long subtraction with addition → SURVIVED

2.2
Location : createBuckets
Killed by : none
Replaced long division with multiplication → SURVIVED

3.3
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:integer_field()]
Replaced integer addition with subtraction → KILLED

342

1.1
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:integer_field()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$LongRounding::createBuckets → KILLED

346

1.1
Location : updateRounded
Killed by : none
changed conditional boundary → SURVIVED

2.2
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:integer_field()]
negated conditional → KILLED

3.3
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:integer_field()]
negated conditional → KILLED

349

1.1
Location : updateRounded
Killed by : none
changed conditional boundary → SURVIVED

2.2
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:integer_field()]
negated conditional → KILLED

3.3
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:integer_field()]
negated conditional → KILLED

366

1.1
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:double_field()]
Replaced double division with multiplication → KILLED

2.2
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:double_field()]
Replaced double multiplication with division → KILLED

367

1.1
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:double_field()]
removed call to org/opensearch/sql/planner/physical/collector/Rounding$DoubleRounding::updateRounded → KILLED

368

1.1
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:double_field()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DoubleRounding::round → KILLED

373

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:double_field()]
Replaced double subtraction with addition → KILLED

2.2
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:double_field()]
Replaced double division with multiplication → KILLED

3.3
Location : locate
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:double_field()]
replaced Integer return value with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DoubleRounding::locate → KILLED

378

1.1
Location : createBuckets
Killed by : none
Replaced double subtraction with addition → SURVIVED

2.2
Location : createBuckets
Killed by : none
Replaced double division with multiplication → SURVIVED

3.3
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:double_field()]
Replaced integer addition with subtraction → KILLED

379

1.1
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:double_field()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DoubleRounding::createBuckets → KILLED

383

1.1
Location : updateRounded
Killed by : none
changed conditional boundary → SURVIVED

2.2
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:double_field()]
negated conditional → KILLED

3.3
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:double_field()]
negated conditional → KILLED

386

1.1
Location : updateRounded
Killed by : none
changed conditional boundary → SURVIVED

2.2
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:double_field()]
negated conditional → KILLED

3.3
Location : updateRounded
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:double_field()]
negated conditional → KILLED

402

1.1
Location : locate
Killed by : org.opensearch.sql.planner.physical.collector.RoundingTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.collector.RoundingTest]/[method:round_unknown_type()]
replaced Integer return value with 0 for org/opensearch/sql/planner/physical/collector/Rounding$UnknownRounding::locate → KILLED

407

1.1
Location : createBuckets
Killed by : org.opensearch.sql.planner.physical.collector.RoundingTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.collector.RoundingTest]/[method:round_unknown_type()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$UnknownRounding::createBuckets → KILLED

418

1.1
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:millisecond_span()]
Replaced long multiplication with division → KILLED

2.2
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:millisecond_span()]
replaced long return with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit$1::round → KILLED

426

1.1
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:second_span()]
Replaced long multiplication with division → KILLED

2.2
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:second_span()]
replaced long return with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit$2::round → KILLED

434

1.1
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:minute_span()]
Replaced long multiplication with division → KILLED

2.2
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:minute_span()]
replaced long return with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit$3::round → KILLED

442

1.1
Location : round
Killed by : none
Replaced long multiplication with division → SURVIVED

2.2
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:hour_span()]
replaced long return with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit$4::round → KILLED

450

1.1
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:day_span()]
Replaced long multiplication with division → KILLED

2.2
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:day_span()]
replaced long return with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit$5::round → KILLED

457

1.1
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:week_span()]
replaced long return with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit$6::round → KILLED

464

1.1
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:month_span()]
replaced long return with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit$7::round → KILLED

471

1.1
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:quarter_span()]
replaced long return with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit$8::round → KILLED

478

1.1
Location : round
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:year_span()]
replaced long return with 0 for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit$9::round → KILLED

497

1.1
Location : resolve
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:month_span()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit::resolve → KILLED

499

1.1
Location : resolve
Killed by : org.opensearch.sql.planner.physical.AggregationOperatorTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.AggregationOperatorTest]/[method:minute_span()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit::resolve → KILLED

501

1.1
Location : resolve
Killed by : org.opensearch.sql.planner.physical.collector.RoundingTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.collector.RoundingTest]/[method:time_rounding_illegal_span()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit::resolve → KILLED

502

1.1
Location : lambda$resolve$0
Killed by : org.opensearch.sql.planner.physical.collector.RoundingTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.collector.RoundingTest]/[method:time_rounding_illegal_span()]
replaced boolean return with false for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit::lambda$resolve$0 → KILLED

2.2
Location : lambda$resolve$0
Killed by : org.opensearch.sql.planner.physical.collector.RoundingTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.collector.RoundingTest]/[method:resolve()]
replaced boolean return with true for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit::lambda$resolve$0 → KILLED

504

1.1
Location : lambda$resolve$1
Killed by : org.opensearch.sql.planner.physical.collector.RoundingTest.[engine:junit-jupiter]/[class:org.opensearch.sql.planner.physical.collector.RoundingTest]/[method:resolve()]
replaced return value with null for org/opensearch/sql/planner/physical/collector/Rounding$DateTimeUnit::lambda$resolve$1 → KILLED

Active mutators

Tests examined


Report generated by PIT 1.9.0