Abacn commented on code in PR #39090:
URL: https://github.com/apache/beam/pull/39090#discussion_r3675245271


##########
sdks/python/apache_beam/io/watch.py:
##########
@@ -32,7 +32,8 @@
 hashes each output's key: the output itself by default, or
 ``output_key_fn(output)`` when one is given. The key coder is inferred when
 not passed explicitly and converted to its deterministic form, so equal keys
-hash equally across workers and restarts.
+hash equally across workers and restarts. ``timestamp_cursor=True`` replaces

Review Comment:
   The last sentence sounds cryptic to users. How about this:
   
   (a new paragraph): By default, watch transform internally stores the hash of 
all items seen. If the incremented items returned by the poll function 
guarantees monotonic timestamp growth (new items on next poll have timestamp 
larger than the largest of the previous poll), consider set 
`timestamp_cursor=True` for better performance, as it replaces the hash dedup 
with an O(1) event-time cursor; see :class:`Watch`.



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