Hi,

I make good use of wait-notify pairs in my nifi flow, and have several in
succession with other processors in between. I also make use of replays
during testing.

To reproduce this issue, all you need is a wait-notify pair followed by an
UpdateAttribute processor, and another wait-notify pair, with expiration
times in the Wait processors set to a minute or something. First run a file
through the complete flow, and it will come out the other end just fine.
Then wait until the expiration time of the first wait processor has passed,
and run a replay from the UpdateAttribute processor. In this case the
flowfile is routed directly to "expired" in the second wait processor.
Then, stop the UpdateAttribute processor, run a new file from the start of
the flow, wait until the expiration time has passed, start the
UpdateAttribute processor, and the file is once again routed directly to
"expired" in the second wait processor. Lastly, set the UpdateAttribute
processor to delete "wait.start.timestamp", do another replay, and the file
will pass through the second wait-notify pair just fine.

My conclusion is that the Wait processor is quite "stupid", not tracking
when it meets a flowfile for the first time, seemingly just checking
whether "wait.start.timestamp" is empty or not. This is of course fine, but
I suggest making the processor delete the timestamp before passing the
flowfile on to "success", and perhaps noting the current behaviour in the
documentation.

Regards,
Lars

Reply via email to