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

Pierre Villard resolved NIFI-7510.
----------------------------------
    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.

> MergeRecords not working after RouteOnAttribute
> -----------------------------------------------
>
>                 Key: NIFI-7510
>                 URL: https://issues.apache.org/jira/browse/NIFI-7510
>             Project: Apache NiFi
>          Issue Type: Bug
>    Affects Versions: 1.11.4
>         Environment: MS Windows 10
>            Reporter: Shane Downey
>            Priority: Minor
>
> Here's the scenario:
> I need to process an arbitrary length spreadsheet or CSV file.
> For each row in the file, I need to extract a value from a column called 
> "Key" and pass it into a SQL Query. If the query returns 0 rows I need to 
> write the source "Key" into an exception file. 
> For the successful queries, I need to write the full output to a spreadsheet 
> file.
>  
> Setup:
> GetFile-->ConvertExceltoCSVProcessor-->SplitRecord(CSVReader/JSONRecordSetWriter)->
> ExtractText("Key"/Value)-->UpdateAttribute("arg.1"=value)->
> ExecuteSQLRecord()-->RouteOnAttribute(rowcount=0)->LogAttribute
> RouteOnAttribute(rowcount!=0)-->MergeRecords(Defragment)->PutFile
>  
> In the above scenario, the FlowFile blocks in the queue leading into 
> MergeRecords (never actually makes it into MergeRecords).
>  
> If I change the merge strategy to Bin then data does flow through to the 
> output file in "chunks" of rows.
> If I remove RouteOnAttribute from the flow, the solution works as expected 
> and my output file is created as expected.
>  
> Thus - there appears to be an issue using RouteOnAttribute within a 
> SplitRecord/MergeRecord block and using the defragment merge strategy. 
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to