Github user alopresto commented on a diff in the pull request:
    --- Diff: 
    @@ -437,6 +451,16 @@ private void onTrigger(final ProcessContext context, 
final ProcessSession sessio
session.putAttribute(resultSetFlowFiles.get(i), "fragment.count", 
    +                    if(copyAttributtes)
    +                    {
    +                        for(Map.Entry<String, String> entry : 
fileToProcess.getAttributes().entrySet()) {
    --- End diff --
    The attributes on the original flowfile are static, but this logic is 
placed inside a loop which iterates over every resulting flowfile (there may be 
many) and performs the same extraction multiple times. Please move the 
retrieval of the original attributes outside of the loop and store them in a 
local variable, then use `session.putAllAttributes(resultSetFlowFiles.get(i), 
map);` inside the loop to copy all the original attributes into the new 


Reply via email to