wolkenkit icon indicating copy to clipboard operation
wolkenkit copied to clipboard

Support dropping and recreating read models

Open goloroden opened this issue 5 years ago • 1 comments

What is this feature about?

Right now, when you don't need a read model anymore (or if you want to start over from scratch with an already existing read model), you can't do anything about it. Your only option is to stop using it, and create a second read model – which basically is quite cumbersome and annoying. We should change this, so that this gets possible. However, we first need to define how to notify wolkenkit about the user's wish.

What needs to be done to implement this feature?

  • [ ] Come up with a concept of how to drop / recreate a read model
  • [ ] Implement it

What else should we know?

This was requested by @jbeaudoin11 in Slack, so we should notify him once this has been implemented.

goloroden avatar Sep 16 '19 05:09 goloroden

After the implementation of the replay command in #1081 this is almost done. Via the replay command we can now reset a flow and replay it, thus reconstructing a read model. The only manual step in this is currently the resetting of the read model's state, since the wolkenkit does not manage this itself.

Since it is currently a developer's decision in which database to build the read model by implementing flows, this is not something the wolkenkit can do by itself. We could, however, add a convenience feature that lets developers define a reset function on flows which destroys the read model and can then be used with the replay --dangerously-reevaluate command.

yeldiRium avatar Feb 09 '21 15:02 yeldiRium