TheNeuralBit commented on a change in pull request #11532:
URL: https://github.com/apache/beam/pull/11532#discussion_r427566080
##########
File path:
sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/spanner/SpannerIO.java
##########
@@ -1066,7 +1079,12 @@ public SpannerWriteResult
expand(PCollection<MutationGroup> input) {
spec.getBatchSizeBytes(),
spec.getMaxNumMutations(),
spec.getMaxNumRows(),
- spec.getGroupingFactor(),
+ // Do not group on streaming unless explicitly
set.
+ spec.getGroupingFactor()
+ .orElse(
+ input.isBounded() == IsBounded.BOUNDED
Review comment:
> They already can set groupingFactorb to 1 if they want...
Ha yeah sorry that was unclear. At the time I thought that groupingFactor =
1 enabled the optimization in https://github.com/apache/beam/pull/11529, so I
was wondering if this was really necessary since users could just enable them
by setting grouping factor manually. But I see now that grouping is separate
from batching. And its disabling batching that enables your other PR.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]