Archive of non-existent streams
I maintainer di solito rispondono entro 7 giorni
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 15/100
Direzione di ricerca
The issue describes archive and hot store behavior in Eventuous, with EventStoreDB (ESDB) and Elastic as the stores; it names no files or tests. Start by reading the archive loading and appending paths, then trace how unarchiving would interact with subscriptions and the archive connector. Done means choosing and implementing a strategy that preserves optimistic concurrency without duplicate archive reads or unwanted subscription effects.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Aiming to solve the following scenario:
- We are importing data from a legacy system directly to the events archive (Elastic)
- There's one event per aggregate in the archive, its version is zero
- When executing a command on an aggregate, events can only be found in the archive
- When appending the event to the hot store (ESDB), we provide the expected version = 1
- The append fails as ESDB doesn't have the stream
It doesn't work as the archive use case expected all the events to be first appended to the hot store (ESDB), and then archived rea time. The hot store stream gets truncated by time or size, so the stream version is kept although events are gone.
One thing we tried is to put the expected version to the meta. However, it effectively disables the native optimistic concurrency checks provided by ESDB or any other store that keeps the event number per stream as a unique constraint. In that case, this complexity moves to Eventuous code, which is not desirable.
Proposed solutions:
- Append dummy events to the imported streams when importing to the archive, then delete those streams. Pro: everything works as it should, no code changes are required in Eventuous. Cons: ESDB data set will include metadata for all the deleted streams. We are talking about hundreds of millions of streams, and most of them will never get new events, so having all those streams in ESDB is inefficient.
- When loading the aggregate, read events from the archive (as it works today) and append them to ESDB right after. Basically, it's an "unarchive on load" feature. Pros: little code change needed, everything will work as it should. Cons: there's no guarantee that any append will happen after load. It would work quite ok if the aggregate state is only loaded for executing commands, and not for queries.
- Unarchive the stream when appending new events. Pros: events will be appended to the hot store if the command execution produced new events. Cons: more code changes are required, as the aggregate needs to keep the collection of original events for unarchiving purposes.
Both unarchiving strategies have two potential issues:
- Unarchived events will get to all the subscriptions, potentially resulting in undesired side effects
- The connector will try to archive those events too, which will cause data duplication, and the next read will get the archived events twice (unless it fails with a duplicate message-id during the archive)
Potential solutions:
- Force delete stream after unarchive
- Annotate specific (import) events so they aren't archived. With this, we'll have a more generic function to prevent some events from being archived at all, which might be useful (but dangerous). It will also spread out to the connector.
- Lingua principale
- C#
- Stelle
- 512
- Fork
- 99
- Merge medio
- 5g 6h
- PR unite (30g)
- 5
Preparare l'ambiente
- Include un Dockerfile o un file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di Eventuous/eventuous
-
MongoDB integration tests fail on newer GitHub Actions runner kernelsForse già presa @nmummau l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
Eventuous/eventuous#626 · 2 commenti ·
I maintainer di solito rispondono entro 7 giorni
-
`dotnet format style --verify-no-changes` fails with naming violations and unnecessary importsForse già presa @nmummau l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 80/100
Eventuous/eventuous#624 · 1 commento ·
I maintainer di solito rispondono entro 7 giorni
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
Eventuous/eventuous#627 · 1 commento ·
I maintainer di solito rispondono entro 7 giorni
-
SQL Server: `append_events` does not need the `@inserted` table variableForse già presa @nmummau l’ha presa 6 giorni fa. Aperta
Difficoltà 3/5 1-2 giorni Idoneità per principianti 20/100
Eventuous/eventuous#619 · 1 commento ·
I maintainer di solito rispondono entro 7 giorni
-
SQL Server: stream reads do one key lookup per event, and `IDX_EventsStream` duplicates `UQ_StreamIdAndStreamPosition`Forse già presa @nmummau l’ha presa 6 giorni fa. Aperta
Difficoltà 3/5 1-2 giorni Idoneità per principianti 18/100
Eventuous/eventuous#618 · 1 commento ·
I maintainer di solito rispondono entro 7 giorni
Tutte le issue di Eventuous/eventuous
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 66/100
gavin-wolfe/wolfden#104 ·
I maintainer di solito rispondono entro 1 giorno
-
[BUG] Still libmicrohttpd dependency is not removed properly from External-Dependency-Info.txt fileApertatype/bug
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 72/100
I maintainer di solito rispondono entro 1 giorno
-
area:framework
Difficoltà 1/5 1-3 ore Idoneità per principianti 72/100
nunit/docs#1262 · 3 commenti ·
I maintainer di solito rispondono entro 1 giorno
-
[辞書] かんそうりつ->乾燥率Aperta辞書
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 62/100
I maintainer di solito rispondono entro 1 giorno
-
bug good first issue
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
thomhurst/TUnit#7201 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno