[
https://issues.apache.org/jira/browse/BEAM-7389?focusedWorklogId=293405&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-293405
]
ASF GitHub Bot logged work on BEAM-7389:
----------------------------------------
Author: ASF GitHub Bot
Created on: 12/Aug/19 21:36
Start Date: 12/Aug/19 21:36
Worklog Time Spent: 10m
Work Description: davidcavazos commented on pull request #9267:
[BEAM-7389] Add code examples for WithTimestamps page
URL: https://github.com/apache/beam/pull/9267#discussion_r313138101
##########
File path:
website/src/documentation/transforms/python/element-wise/withtimestamps.md
##########
@@ -19,10 +19,116 @@ limitations under the License.
-->
# WithTimestamps
+
+<script type="text/javascript">
+localStorage.setItem('language', 'language-py')
+</script>
+
Assigns timestamps to all the elements of a collection.
## Examples
-See [BEAM-7389](https://issues.apache.org/jira/browse/BEAM-7389) for updates.
-## Related transforms
-* [Reify]({{ site.baseurl
}}/documentation/transforms/python/elementwise/reify) converts between explicit
and implicit forms of Beam values.
\ No newline at end of file
+In the following examples, we create a pipeline with a `PCollection` and
attach a timestamp value to each of its elements.
+Timestamps are especially useful on streaming pipelines where windowing and
late data play a more important role.
+
+### Example 1: Timestamp by event time
+
+Often times, the elements themselves already contain a timestamp field that
can be used.
+`beam.window.TimestampedValue` will take a value and a timestamp in the form
of seconds, where a unix timestamp can be used.
Review comment:
Thanks, it's still accurate so changing it. I left the Unix part to make it
explicit.
----------------------------------------------------------------
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]
Issue Time Tracking
-------------------
Worklog Id: (was: 293405)
> Colab examples for element-wise transforms (Python)
> ---------------------------------------------------
>
> Key: BEAM-7389
> URL: https://issues.apache.org/jira/browse/BEAM-7389
> Project: Beam
> Issue Type: Improvement
> Components: website
> Reporter: Rose Nguyen
> Assignee: David Cavazos
> Priority: Minor
> Time Spent: 43h 10m
> Remaining Estimate: 0h
>
--
This message was sent by Atlassian JIRA
(v7.6.14#76016)