apache / apache/beam

Count should return a more specific type than PTransform

Open
#18,468 0 comments 0 reactions 0 assignees View on GitHub
core improvement java P3
Dominant language
Java
Stars
8.7k
Forks
4.7k
Avg merge
2d 2h
Merged PRs (30d)
205

Description

As `Count.globally()` and other static factory methods return objects of type `PTransform`, there is no way to communicate to the underlying `Combine` that we wish to have no default values, or to read the count as a `SingletonView` via the combiner.

Imported from Jira [BEAM-2501](https://issues.apache.org/jira/browse/BEAM-2501). Original Jira may contain additional context.
Reported by: tgroh.

Contributor guide

Open the contributing guide

Research direction

Start by examining Count.globally(), the other static factory methods, PTransform, and the underlying Combine behavior described in the issue. Determine the intended more-specific return type and how it should expose no-default-value and SingletonView behavior; done requires a decided API design and corresponding coverage for those use cases.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
data-engineering
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.