From 617de3679ad70ee50f13307c66dc98fff8673744 Mon Sep 17 00:00:00 2001 From: Walker Carlson Date: Thu, 21 Jan 2021 14:31:28 -0800 Subject: [PATCH] system time change --- .../streams/integration/StandbyTaskEOSIntegrationTest.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/streams/src/test/java/org/apache/kafka/streams/integration/StandbyTaskEOSIntegrationTest.java b/streams/src/test/java/org/apache/kafka/streams/integration/StandbyTaskEOSIntegrationTest.java index a8d1663887348..88d3ae57c9f6b 100644 --- a/streams/src/test/java/org/apache/kafka/streams/integration/StandbyTaskEOSIntegrationTest.java +++ b/streams/src/test/java/org/apache/kafka/streams/integration/StandbyTaskEOSIntegrationTest.java @@ -176,6 +176,7 @@ private KafkaStreams buildStreamWithDirtyStateDir(final String stateDirPath, @Test @Deprecated public void shouldWipeOutStandbyStateDirectoryIfCheckpointIsMissing() throws Exception { + final long time = System.currentTimeMillis(); final String base = TestUtils.tempDirectory(appId).getPath(); IntegrationTestUtils.produceKeyValuesSynchronouslyWithTimestamp( @@ -189,7 +190,7 @@ public void shouldWipeOutStandbyStateDirectoryIfCheckpointIsMissing() throws Exc IntegerSerializer.class, new Properties() ), - 10L + 10L + time ); try ( @@ -248,7 +249,7 @@ public void shouldWipeOutStandbyStateDirectoryIfCheckpointIsMissing() throws Exc IntegerSerializer.class, new Properties() ), - 10L + 10L + time ); waitForCondition( () -> streamInstanceOne.state() == KafkaStreams.State.ERROR, @@ -307,7 +308,7 @@ public void shouldWipeOutStandbyStateDirectoryIfCheckpointIsMissing() throws Exc IntegerSerializer.class, new Properties() ), - 10L + 10L + time ); waitForCondition( () -> streamInstanceOneRecovery.state() == KafkaStreams.State.ERROR,