You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@nifi.apache.org by "Jacek Trocinski (Jira)" <ji...@apache.org> on 2022/06/27 13:35:00 UTC

[jira] [Updated] (NIFI-10171) LookupRecord Fails when No Match

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

Jacek Trocinski updated NIFI-10171:
-----------------------------------
    Description: 
When there is no match for a key in the DatabaseRecordLookupService it returns an error:

!https://community.cloudera.com/t5/image/serverpage/image-id/34689i23235965854C2D7D/image-size/medium?v=v2&px=400!

The lookup processor config:

!https://community.cloudera.com/t5/image/serverpage/image-id/34690i03D3A63AD902480E/image-size/medium?v=v2&px=400!

The input JSON has the following structure:
{code:java}
[
  {
    "id": 1,
    "name": "Bitcoin",
    "symbol": "BTC"
  },
  {
    "id": 2,
    "name": "Apecoin",
    "symbol": "Ape"
  }
] {code}
 

I expected the attribute value to be updated when there is a lookup match.

E.g., if there is a lookup match on symbol {{BTC}} then replace {{BTC}} with the lookup value.

I expected the attribute value to not be updated when there is no lookup match.

E.g., if there is no lookup match on symbol {{APE}} then *do not* replace {{APE}} with a lookup value.

  was:
When there is no match for a key in the DatabaseRecordLookupService it returns an error:

!https://community.cloudera.com/t5/image/serverpage/image-id/34689i23235965854C2D7D/image-size/medium?v=v2&px=400!

The lookup processor config:

!https://community.cloudera.com/t5/image/serverpage/image-id/34690i03D3A63AD902480E/image-size/medium?v=v2&px=400!

The input JSON has the following structure:
[
  \{
    "id": 1,
    "name": "Bitcoin",
    "symbol": "BTC"
  },
  \{
    "id": 2,
    "name": "Apecoin",
    "symbol": "Ape"
  }
]
 

I expected the attribute value is updated for a lookup match (e.g., if there is a lookup match for symbol BTC then replace BTC with the lookup value) and when there is no lookup match then don't update the attribute (e.g., there is no lookup match for the APE symbol which should leave the symbol as APE).


> LookupRecord Fails when No Match
> --------------------------------
>
>                 Key: NIFI-10171
>                 URL: https://issues.apache.org/jira/browse/NIFI-10171
>             Project: Apache NiFi
>          Issue Type: Bug
>          Components: Core Framework
>    Affects Versions: 1.16.2
>            Reporter: Jacek Trocinski
>            Priority: Minor
>
> When there is no match for a key in the DatabaseRecordLookupService it returns an error:
> !https://community.cloudera.com/t5/image/serverpage/image-id/34689i23235965854C2D7D/image-size/medium?v=v2&px=400!
> The lookup processor config:
> !https://community.cloudera.com/t5/image/serverpage/image-id/34690i03D3A63AD902480E/image-size/medium?v=v2&px=400!
> The input JSON has the following structure:
> {code:java}
> [
>   {
>     "id": 1,
>     "name": "Bitcoin",
>     "symbol": "BTC"
>   },
>   {
>     "id": 2,
>     "name": "Apecoin",
>     "symbol": "Ape"
>   }
> ] {code}
>  
> I expected the attribute value to be updated when there is a lookup match.
> E.g., if there is a lookup match on symbol {{BTC}} then replace {{BTC}} with the lookup value.
> I expected the attribute value to not be updated when there is no lookup match.
> E.g., if there is no lookup match on symbol {{APE}} then *do not* replace {{APE}} with a lookup value.



--
This message was sent by Atlassian Jira
(v8.20.7#820007)