[ https://issues.apache.org/jira/browse/BEAM-8537?focusedWorklogId=386966&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-386966 ]
ASF GitHub Bot logged work on BEAM-8537: ---------------------------------------- Author: ASF GitHub Bot Created on: 13/Feb/20 23:55 Start Date: 13/Feb/20 23:55 Worklog Time Spent: 10m Work Description: robertwb commented on pull request #10375: [BEAM-8537] Provide WatermarkEstimator to track watermark URL: https://github.com/apache/beam/pull/10375#discussion_r379136495 ########## File path: sdks/python/apache_beam/runners/common.py ########## @@ -323,6 +330,27 @@ def is_splittable_dofn(self): # type: () -> bool return self.get_restriction_provider() is not None + def is_tracking_watermark(self): + return self.get_watermark_estimator_provider() is not None + + def get_restriction_coder(self): + """Get coder for a restriction when processing an SDF. + + If the SDF uses an WatermarkEstimatorProvider, the restriction coder is a Review comment: This code assumes a watermark estimator is always available, if so update the docstring (and simplify the code elsewhere to not have a different branch for the no-watermark-estimator case). (Yes, this should be feasible for other SDKs as well, but each SDK can do their own thing.) ---------------------------------------------------------------- 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: us...@infra.apache.org Issue Time Tracking ------------------- Worklog Id: (was: 386966) Time Spent: 15h 10m (was: 15h) > Provide WatermarkEstimatorProvider for different types of WatermarkEstimator > ---------------------------------------------------------------------------- > > Key: BEAM-8537 > URL: https://issues.apache.org/jira/browse/BEAM-8537 > Project: Beam > Issue Type: Improvement > Components: sdk-py-core, sdk-py-harness > Reporter: Boyuan Zhang > Assignee: Boyuan Zhang > Priority: Major > Time Spent: 15h 10m > Remaining Estimate: 0h > > This is a follow up for in-progress PR: > https://github.com/apache/beam/pull/9794. > Current implementation in PR9794 provides a default implementation of > WatermarkEstimator. For further work, we want to let WatermarkEstimator to be > a pure Interface. We'll provide a WatermarkEstimatorProvider to be able to > create a custom WatermarkEstimator per windowed value. It should be similar > to how we track restriction for SDF: > WatermarkEstimator <---> RestrictionTracker > WatermarkEstimatorProvider <---> RestrictionTrackerProvider > WatermarkEstimatorParam <---> RestrictionDoFnParam -- This message was sent by Atlassian Jira (v8.3.4#803005)