This is an automated email from the ASF dual-hosted git repository.
gian pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/druid.git
The following commit(s) were added to refs/heads/master by this push:
new 761c2bcfe35 Fix OnheapIncrementalIndexTest error expectation. (#18882)
761c2bcfe35 is described below
commit 761c2bcfe35675534cd756f8579ced86acf29366
Author: Gian Merlino <[email protected]>
AuthorDate: Sat Jan 3 20:29:07 2026 -0800
Fix OnheapIncrementalIndexTest error expectation. (#18882)
The error message should expect minTimestampProjectionTimestamp,
not outOfRangeProjectionTimestamp. These are out of sync on Jan 1.
Also, now we use a specific timestamp rather than nowUtc, because using
nowUtc would lead the test to fail if run at exactly midnight UTC.
---
.../druid/segment/incremental/OnheapIncrementalIndexTest.java | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git
a/processing/src/test/java/org/apache/druid/segment/incremental/OnheapIncrementalIndexTest.java
b/processing/src/test/java/org/apache/druid/segment/incremental/OnheapIncrementalIndexTest.java
index fb4881c8517..b890bdc97ea 100644
---
a/processing/src/test/java/org/apache/druid/segment/incremental/OnheapIncrementalIndexTest.java
+++
b/processing/src/test/java/org/apache/druid/segment/incremental/OnheapIncrementalIndexTest.java
@@ -418,9 +418,9 @@ public class OnheapIncrementalIndexTest
)
.build();
- final DateTime minTimestamp = DateTimes.nowUtc();
- final DateTime outOfRangeTimestamp = DateTimes.nowUtc().minusDays(1);
- final DateTime outOfRangeProjectionTimestamp =
Granularities.YEAR.bucketStart(outOfRangeTimestamp);
+ final DateTime minTimestamp = DateTimes.of("2001-01-01T01:00:00");
+ final DateTime minTimestampProjectionTimestamp =
Granularities.YEAR.bucketStart(minTimestamp);
+ final DateTime outOfRangeTimestamp = minTimestamp.minusDays(1);
final IncrementalIndex index = IndexBuilder.create()
.schema(IncrementalIndexSchema.builder()
@@ -502,7 +502,7 @@ public class OnheapIncrementalIndexTest
"Cannot add row[{timestamp="
+ minTimestamp
+ ", event={string=hello, long=10}, dimensions=[string, long]}] to
projection[proj] because projection effective timestamp["
- + outOfRangeProjectionTimestamp
+ + minTimestampProjectionTimestamp
+ "] is below the minTimestamp["
+ minTimestamp + "]",
t.getMessage()
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]