wolkenkit icon indicating copy to clipboard operation
wolkenkit copied to clipboard

The CLI replay command might run into issues if a flow is already replaying

Open yeldiRium opened this issue 4 years ago • 1 comments

What is this bug about?

The ConsumerProgressStore throws an exception when starting a replay for a consumer that is already replaying. The replay CLI command does not check whether the individual flows are already replaying before starting their replay.

What is the expected result?

After running the replay command, all flows mentioned in the command arguments should be replaying. If any of them is already replaying, its replay should either be restarted or keep going. Which is to be decided.

What is the actual result?

Not sure, this is just a theory. But the CLI command probably throws and fails if any of the flows it tries to replay is already replaying.

What steps are needed to reproduce the bug?

  • Create a flow
  • Let it process some domain events
  • Start a replay for it, without actually sending it the domain events again
  • Use the replay CLI command to replay the flow again

yeldiRium avatar Jul 26 '21 06:07 yeldiRium

@yeldiRium Just a few thoughts on this…

First of all, I wonder, whether it makes any difference. Maybe I don't have the right idea yet, but I don't see a situation where it actually is relevant whether we do A or B.

Assumed that it actually made a difference, then I'd say we should restart. If you weren't aware that the replay was already running, it doesn't matter, it just takes longer to complete. But if you actually had a good reason to request a replay again, I think, it should actually re-run the replay, and not just continue where it left off.

What do you think on this?

goloroden avatar Jul 26 '21 07:07 goloroden