[ https://issues.apache.org/jira/browse/BEAM-3746?focusedWorklogId=138483&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-138483 ]
ASF GitHub Bot logged work on BEAM-3746: ---------------------------------------- Author: ASF GitHub Bot Created on: 27/Aug/18 17:21 Start Date: 27/Aug/18 17:21 Worklog Time Spent: 10m Work Description: stale[bot] commented on issue #5176: [BEAM-3746] Added error message for using Count.globally() on non-global windows URL: https://github.com/apache/beam/pull/5176#issuecomment-416300474 This pull request has been marked as stale due to 60 days of inactivity. It will be closed in 1 week if no further activity occurs. If you think that’s incorrect or this pull request requires a review, please simply write any comment. If closed, you can revive the PR at any time and @mention a reviewer or discuss it on the d...@beam.apache.org list. Thank you for your contributions. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org Issue Time Tracking ------------------- Worklog Id: (was: 138483) Time Spent: 1h 20m (was: 1h 10m) > Count.globally should override getIncompatibleGlobalWindowErrorMessage to > tell the user the usage that is currently only in javadoc > ----------------------------------------------------------------------------------------------------------------------------------- > > Key: BEAM-3746 > URL: https://issues.apache.org/jira/browse/BEAM-3746 > Project: Beam > Issue Type: Bug > Components: sdk-java-core > Reporter: Kenneth Knowles > Priority: Major > Labels: beginner, newbie, starter > Time Spent: 1h 20m > Remaining Estimate: 0h > > https://beam.apache.org/documentation/sdks/javadoc/2.3.0/org/apache/beam/sdk/transforms/Count.html#globally-- > "Note: if the input collection uses a windowing strategy other than > GlobalWindows, use Combine.globally(Count.<T>combineFn()).withoutDefaults() > instead." > But the actual crash a user gets is: > "java.lang.IllegalStateException: Default values are not supported in > Combine.globally() if the output PCollection is not windowed by > GlobalWindows. Instead, use Combine.globally().withoutDefaults() to output an > empty PCollection if the input PCollection is empty, or > Combine.globally().asSingletonView() to get the default output of the > CombineFn if the input PCollection is empty." > There is a method that exists solely to make this actually useful, so we > should use it! -- This message was sent by Atlassian JIRA (v7.6.3#76005)