Skip to content

Commit

Permalink
[#noissue] Check Range with given parameter
Browse files Browse the repository at this point in the history
Fixed because it was incorrect if checked after TimeWindow creation.
  • Loading branch information
intr3p1d committed May 3, 2024
1 parent 3c28d9c commit 74fd31d
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -169,8 +169,10 @@ public ExceptionTraceView getCollectedExceptionMetaDataByGivenRange(
) {
String groupName = (groupByList == null) ? "total error occurs" : "top5 error occurs";

TimeWindow timeWindow = new TimeWindow(Range.between(from, to), DEFAULT_TIME_WINDOW_SAMPLER);
rangeValidator.validate(timeWindow.getWindowRange());
Range range = Range.between(from, to);
rangeValidator.validate(range);
TimeWindow timeWindow = new TimeWindow(range, DEFAULT_TIME_WINDOW_SAMPLER);

ExceptionTraceQueryParameter queryParameter = new ExceptionTraceQueryParameter.Builder()
.setTableName(tableName)
.setTenantId(tenantProvider.getTenantId())
Expand Down

0 comments on commit 74fd31d

Please sign in to comment.