Skip to content

Commit 2b273f9

Browse files
add sync block
1 parent db5bf3c commit 2b273f9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

google-cloud-spanner/src/main/java/com/google/cloud/spanner/AsyncResultSetImpl.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -469,7 +469,7 @@ public void run() {
469469
// Non-streaming result sets do not trigger this callback, and for those result sets, we
470470
// need to eagerly start the ProduceRowsRunnable.
471471
synchronized (monitor) {
472-
if (!(state == State.STREAMING_INITIALIZED)) {
472+
if (state == State.RUNNING || state == State.CONSUMING) {
473473
return;
474474
}
475475
}

0 commit comments

Comments
 (0)