robertwb commented on code in PR #22834:
URL: https://github.com/apache/beam/pull/22834#discussion_r954117756


##########
sdks/python/apache_beam/transforms/util.py:
##########
@@ -541,15 +541,15 @@ def process(self, element):
     self._running_batch_size += self._element_size_fn(element)
     if self._running_batch_size >= self._target_batch_size:
       with self._batch_size_estimator.record_time(self._running_batch_size):
-        yield self._batch
+        yield window.GlobalWindows.windowed_value_at_end_of_window(self._batch)

Review Comment:
   We could allow configuration of this with a TimestampCombiner, but I'd 
consider that more a feature request than a bug fix. This seems, by default, 
the safest thing to do in the global window. (Even if we preserved the latest 
timestamp, there's no limit to how far back the earliest dropped timestamp 
might be.)



-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to