Are you trying to see if all attributes from both FlowFiles match exactly or is their a specific attribute from each FlowFile you want to compare?
My initial thought would be to use the DetectDuplicate processor.
You could write the unique attribute to the DistributedMapCache service. Then compare new FlowFiles against that stored value and deleted any duplicates. That way only the first FlowFile would get passed on.
So, I've accomplished the comparisson of two flowfiles. Trying to complicate this a bit more, what about if I have more than two flowfiles to compare? Is there any processor for this? Other option would be to "play" with the DetectDuplicate and create different levels of comparisson... but I don't like it so much thus the DetectDuplicate itself is very clean.