Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Persisted Events for event based architecture #512

Open
electronicbites opened this issue Jan 22, 2024 · 0 comments
Open

Persisted Events for event based architecture #512

electronicbites opened this issue Jan 22, 2024 · 0 comments

Comments

@electronicbites
Copy link
Collaborator

I confess, I am a fan of event based architectures (like event sourcing). In order to do so we need to persist events.
But I also believe conflict resolution is easier with these kind of events. If we have an agenda who did what action and when, we have a timeline and can rebuild everything. The order of events is the same for every user of the outliner. This means another layer of abstraction because we first have to create the events and then handle them. The handler takes the events in a determined order no matter of the source (api, script, app ...). Therefore I believe our building blocks get more loosely coupled with this approach.

We are using already events in the frontend-backend communication but we need specified persisted events in the backend only. Since we are using Elixir we do not need to use an external tool like Kafka. Currently I see only a small amount of event types:

  • Create Node
    -- time, content, editor

  • Update Node
    -- time, old content, new content, editor

  • Delete Node
    -- time, node id, editor

  • Move Node
    -- time, old parent node, new parent node, editor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant