You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@beam.apache.org by "Beam JIRA Bot (Jira)" <ji...@apache.org> on 2020/08/18 17:07:34 UTC

[jira] [Commented] (BEAM-671) Update Read PTransform to implicitly use maxNumRecords and maxReadTime

    [ https://issues.apache.org/jira/browse/BEAM-671?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17179948#comment-17179948 ] 

Beam JIRA Bot commented on BEAM-671:
------------------------------------

This issue is P2 but has been unassigned without any comment for 60 days so it has been labeled "stale-P2". If this issue is still affecting you, we care! Please comment and remove the label. Otherwise, in 14 days the issue will be moved to P3.

Please see https://beam.apache.org/contribute/jira-priorities/ for a detailed explanation of what these priorities mean.


> Update Read PTransform to implicitly use maxNumRecords and maxReadTime
> ----------------------------------------------------------------------
>
>                 Key: BEAM-671
>                 URL: https://issues.apache.org/jira/browse/BEAM-671
>             Project: Beam
>          Issue Type: Improvement
>          Components: sdk-java-core
>            Reporter: Jean-Baptiste Onofré
>            Priority: P2
>              Labels: stale-P2
>
> Today, almost all IOs {{Read}} {{PTransform}}, when using an {{UnboundedSource}}, do the following in the {{apply()}}:
> {code:java}
>       org.apache.beam.sdk.io.Read.Unbounded<byte[]> unbounded =
>           org.apache.beam.sdk.io.Read.from(getSource());
>       PTransform<PBegin, PCollection<byte[]>> transform = unbounded;
>       if (maxNumRecords() < Long.MAX_VALUE || maxReadTime() != null) {
>         transform = unbounded.withMaxReadTime(maxReadTime()).withMaxNumRecords(maxNumRecords());
>       }
>       return input.getPipeline().apply(transform);
> {code}
> To avoid to duplicate this code bunch of time, it would make sense to do it by default in {{org.apache.beam.sdk.io.Read}}.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)