beam-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kenneth Knowles (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (BEAM-1336) A StateSpec that doesn't care about the key shouldn't be forced to declare it as type Object
Date Mon, 24 Apr 2017 18:43:04 GMT

     [ https://issues.apache.org/jira/browse/BEAM-1336?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Kenneth Knowles updated BEAM-1336:
----------------------------------
    Labels:   (was: starter)

> A StateSpec that doesn't care about the key shouldn't be forced to declare it as type
Object
> --------------------------------------------------------------------------------------------
>
>                 Key: BEAM-1336
>                 URL: https://issues.apache.org/jira/browse/BEAM-1336
>             Project: Beam
>          Issue Type: Improvement
>          Components: sdk-java-core
>            Reporter: Kenneth Knowles
>            Assignee: Kenneth Knowles
>            Priority: Minor
>             Fix For: First stable release
>
>
> In the state API as it exists today, if (as is almost often the case) you are writing
a {{StateSpec<K, StateT>}} other than a {{KeyedCombiningState}} the key type is irrelevant
and the user just has to write {{Object}} there. This was carried over from {{StateTag}} and
is an artifact of the visitor pattern there and the difficulty of getting all the types to
line up.
> I think simplifying the visitor pattern to be more of just a syntax traversal might alleviate
the issue and allow us to drop this noise from the syntax.



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

Mime
View raw message