From a642978e0ba47df3f5598cf657308fe5cf2f48e1 Mon Sep 17 00:00:00 2001 From: Jiang Zhu Date: Fri, 24 Jul 2026 04:44:01 +0000 Subject: [PATCH] fix(spanner): Fix the start timestamp > end timestamp issue for change stream initial query. --- .../cloud/executor/spanner/CloudClientExecutor.java | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/java-spanner/google-cloud-spanner-executor/src/main/java/com/google/cloud/executor/spanner/CloudClientExecutor.java b/java-spanner/google-cloud-spanner-executor/src/main/java/com/google/cloud/executor/spanner/CloudClientExecutor.java index 4657149a7cf0..bd6b96219a1c 100644 --- a/java-spanner/google-cloud-spanner-executor/src/main/java/com/google/cloud/executor/spanner/CloudClientExecutor.java +++ b/java-spanner/google-cloud-spanner-executor/src/main/java/com/google/cloud/executor/spanner/CloudClientExecutor.java @@ -2462,14 +2462,10 @@ private Status executeExecuteChangeStreamQuery( // For initial partition query (no partition token) we simulate precision of the timestamp // in nanoseconds as that's closer inlined with the production client code. - String startTime = - timestampToString( - !action.hasPartitionToken(), Timestamps.toMicros(action.getStartTime())); + String startTime = timestampToString(false, Timestamps.toMicros(action.getStartTime())); String endTime = "null"; if (action.hasEndTime()) { - endTime = - timestampToString( - !action.hasPartitionToken(), Timestamps.toMicros(action.getEndTime())); + endTime = timestampToString(false, Timestamps.toMicros(action.getEndTime())); } String heartbeat = "null"; if (action.hasHeartbeatMilliseconds()) {