You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@beam.apache.org by "Chamikara Jayalath (JIRA)" <ji...@apache.org> on 2017/08/18 22:09:00 UTC
[jira] [Resolved] (BEAM-2711)
ByteKeyRangeTracker.getFractionConsumed() fails when out of range positions
are claimed
[ https://issues.apache.org/jira/browse/BEAM-2711?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Chamikara Jayalath resolved BEAM-2711.
--------------------------------------
Resolution: Fixed
Fix Version/s: 2.2.0
> ByteKeyRangeTracker.getFractionConsumed() fails when out of range positions are claimed
> ---------------------------------------------------------------------------------------
>
> Key: BEAM-2711
> URL: https://issues.apache.org/jira/browse/BEAM-2711
> Project: Beam
> Issue Type: Bug
> Components: sdk-java-core
> Reporter: Chamikara Jayalath
> Assignee: Chamikara Jayalath
> Fix For: 2.2.0
>
>
> ByteKeyRangeTracker.getFractionConsumed() invokes range.estimateFractionForKey(position) at following location.
> https://github.com/apache/beam/blob/master/sdks/java/core/src/main/java/org/apache/beam/sdk/io/range/ByteKeyRangeTracker.java#L127
> This invocation fails for out of range positions.
> https://github.com/apache/beam/blob/master/sdks/java/core/src/main/java/org/apache/beam/sdk/io/range/ByteKeyRange.java#L170
> But ByteKeyRangeTracker may accept out of range positions at following location.
> https://github.com/apache/beam/blob/master/sdks/java/core/src/main/java/org/apache/beam/sdk/io/range/ByteKeyRangeTracker.java#L80
> We can fix this by updating ByteKeyRangeTracker.getFractionConsumed() to return 1.0 for positions that are larger than the stop position, similar to OffsetRangeTracker.
> https://github.com/apache/beam/blob/master/sdks/java/core/src/main/java/org/apache/beam/sdk/io/range/OffsetRangeTracker.java#L176
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)