You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@samza.apache.org by "Hai Lu (Jira)" <ji...@apache.org> on 2019/11/07 00:06:03 UTC

[jira] [Updated] (SAMZA-2299) StreamTableJoin Operator should invoke user join function only once

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

Hai Lu updated SAMZA-2299:
--------------------------
    Fix Version/s: 1.3

> StreamTableJoin Operator should invoke user join function only once
> -------------------------------------------------------------------
>
>                 Key: SAMZA-2299
>                 URL: https://issues.apache.org/jira/browse/SAMZA-2299
>             Project: Samza
>          Issue Type: Bug
>            Reporter: Bharath Kumarasubramanian
>            Assignee: Bharath Kumarasubramanian
>            Priority: Major
>             Fix For: 1.3
>
>          Time Spent: 40m
>  Remaining Estimate: 0h
>
> In StreamTableJoinOperator, we currently invoke the user join function again with null record if the first call to join function returns a null. This is not desirable in use cases for anti-join where subsequent invocation of join function could result in different results.
>  
> {code:java}
> Optional.ofNullable(value)
>   .map(val -> (R) KV.of(key, val)
>   .map(record -> joinOpSpec.getJoinFn().apply(message, record))
>   .orElseGet(() -> joinOpSpec.getJoinFn().apply(message, null)); // this is the additional invocation that happens if the previous invocation returns a null{code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)