Skip to content

Extract common class for WithTimestamps.AddTimestampsDoFn and Create.TimestampedValues.ConvertTimestamps #18350

Description

@kennknowles

It seems like these APIs are predominantly duplicative of each other and, that it's hard to find one of them if you knew about the other.

public void processElement(ProcessContext c) {

c.outputWithTimestamp(c.element().getValue(), c.element().getTimestamp());

What would make the most sense to me is if TimestampedValues were implemented in terms of both Values and WithTimestamps. I'm still learning about Beam though -- would this approach cause some kind of performance problem?

Imported from Jira BEAM-1811. Original Jira may contain additional context.
Reported by: wtanaka.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions