[
https://issues.apache.org/jira/browse/NIFI-9653?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Pierre Villard resolved NIFI-9653.
----------------------------------
Resolution: Feedback Received
Apache NiFi 1.x is no longer maintained and no new release is planned on the
1.x release line. Marking as resolved as part of a cleanup operation. Please
open a new one with an updated description if this is still relevant for NiFi
2.x.
> PutSQL Duplicate Key Exception moves flowfile to retry
> ------------------------------------------------------
>
> Key: NIFI-9653
> URL: https://issues.apache.org/jira/browse/NIFI-9653
> Project: Apache NiFi
> Issue Type: Bug
> Components: Core Framework
> Affects Versions: 1.15.3
> Reporter: Ron Milne
> Assignee: Shubhra Jain Ksolves Nifi Expertise
> Priority: Major
> Labels: starter
> Time Spent: 1h
> Remaining Estimate: 0h
>
> When inserting data into the (postgreSQL) DB where a duplicate key exception
> will be raised. All records that fail are moved to the *retry* queue rather
> than the *failure* queue. This floods the app-log - is it usual practice to
> place the retry back onto PutSQL? This potentially leads to root cause
> analysis becoming difficult as no exception information is attached to the
> flowfile.
> 07:26:48 UTC
> ERROR
> 6dfd7bdd-d625-345e-66cc-ec710ddba59a
>
> PutSQL[id=6dfd7bdd-d625-345e-66cc-ec710ddba59a] Failed to update database for
> StandardFlowFileRecord[uuid=97c778c0-fe4e-4533-a9d1-e40daba227f7,claim=StandardContentClaim
> [resourceClaim=StandardResourceClaim[id=1643764574088-5, container=default,
> section=5], offset=69481, length=95],offset=0,name=incoming.csv,size=95] due
> to ERROR: current transaction is aborted, commands ignored until end of
> transaction block; it is possible that retrying the operation will succeed,
> so routing to retry: org.postgresql.util.PSQLException: ERROR: duplicate key
> value violates unique constraint "onboarding_pkey"
> Detail: Key (identifier)=(1625) already exists.
> ↳ causes: org.postgresql.util.PSQLException: ERROR: current transaction is
> aborted, commands ignored until end of transaction block
--
This message was sent by Atlassian Jira
(v8.20.10#820010)