[
https://issues.apache.org/jira/browse/BEAM-5675?focusedWorklogId=157142&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-157142
]
ASF GitHub Bot logged work on BEAM-5675:
----------------------------------------
Author: ASF GitHub Bot
Created on: 22/Oct/18 19:54
Start Date: 22/Oct/18 19:54
Worklog Time Spent: 10m
Work Description: kanterov commented on a change in pull request #6772:
[BEAM-5675] Fix RowCoder#verifyDeterministic
URL: https://github.com/apache/beam/pull/6772#discussion_r227069426
##########
File path:
sdks/java/core/src/main/java/org/apache/beam/sdk/coders/RowCoder.java
##########
@@ -123,28 +124,31 @@ public void verifyDeterministic()
private void verifyDeterministic(Schema schema)
throws org.apache.beam.sdk.coders.Coder.NonDeterministicException {
Review comment:
I've started looking into `RowCoder#verifyDeterministic` when I was
debugging pipeline that was failing due non-deterministic exception. It was
hard to figure out what is wrong without having a stack trace, and detailed
error message saying which field is causing the problem.
I didn't find two things:
- stack trace to the first coder violating determinism
- field name so that I can understand what is failing
- in case of SchemaCoder, I would propose to add a class name
There is a similar code in `StructuredCoder`, but it doesn't have field
names.
I agree to go with the most simple approach and improve error messages later.
----------------------------------------------------------------
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:
[email protected]
Issue Time Tracking
-------------------
Worklog Id: (was: 157142)
Time Spent: 1h 10m (was: 1h)
> RowCoder#verifyDeterministic isn't consistent with Beam coders
> --------------------------------------------------------------
>
> Key: BEAM-5675
> URL: https://issues.apache.org/jira/browse/BEAM-5675
> Project: Beam
> Issue Type: Bug
> Components: dsl-sql
> Affects Versions: 2.7.0
> Reporter: Gleb Kanterov
> Assignee: Gleb Kanterov
> Priority: Major
> Time Spent: 1h 10m
> Remaining Estimate: 0h
>
> For instance, `DoubleCoder#verifyDeterministic` throws an exception, but
> `RowCoder#verifyDeterministic` doesn't.
> Expected to throw NonDeterministicException
> {code:java}
> RowCoder.of(
> Schema
> .builder()
> .addField("foo", Schema.FieldType.DOUBLE)
> .build()
> ).verifyDeterministic();
> {code}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)