use of org.apache.druid.server.QueryPrioritizationStrategy in project druid by druid-io.
the class ThresholdBasedQueryPrioritizationStrategyTest method testPrioritizationPeriodThresholdInsidePeriod.
@Test
public void testPrioritizationPeriodThresholdInsidePeriod() {
QueryPrioritizationStrategy strategy = new ThresholdBasedQueryPrioritizationStrategy("P90D", null, null, adjustment);
DateTime startDate = DateTimes.nowUtc().minusDays(1);
DateTime endDate = DateTimes.nowUtc();
TimeseriesQuery query = queryBuilder.intervals(ImmutableList.of(new Interval(startDate, endDate))).granularity(Granularities.MINUTE).context(ImmutableMap.of()).build();
Assert.assertFalse(strategy.computePriority(QueryPlus.wrap(query), ImmutableSet.of()).isPresent());
}
Aggregations