beam-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Aljoscha Krettek (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (BEAM-1335) ValueState could use an initial/default value
Date Thu, 02 Feb 2017 16:02:51 GMT

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

Aljoscha Krettek commented on BEAM-1335:
----------------------------------------

No, only the internal implementation is harder to get right. (One of the difficulties is that
Flink doesn't just have a {{Coder}} but a {{TypeInformation}} that can be asked to give a
{{TypeSerializer}}, where the latter is similar to a {{Coder}}. The {{TypeSeriailzer}} that
is returned can depend on pipeline-level configuration settings so it's hard to get that always
working correctly because of serialisation of the user function, where you also have to serialise
the state spec.)

Since we tend to put ease of use before ease of internal development I think it's good to
have this option, also since {{Coders}} are easier to deal with.

> ValueState could use an initial/default value
> ---------------------------------------------
>
>                 Key: BEAM-1335
>                 URL: https://issues.apache.org/jira/browse/BEAM-1335
>             Project: Beam
>          Issue Type: Improvement
>          Components: sdk-java-core
>            Reporter: Kenneth Knowles
>            Priority: Minor
>              Labels: starter
>
> In writing example state code with {{ValueState}} there is almost always a use of {{firstNonNull(state.read(),
defaultValue)}}. It would be nice to bake this into the declaration.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Mime
View raw message