[Serverless] Ensure that only one subscription instance is active
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
- 20/100
- Tipo di issue
- Funzionalità
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Ferma
- Stack tecnologico
- csharp
- Ambito
- distributed-systems
Direzione di ricerca
Start by reading issue #161 for the proposed subscription position API, then trace how subscriptions are started and how their checkpoints are managed. The issue proposes an HTTP presence API and ongoing instance election, but leaves race conditions and the election design unresolved; done would require a decided approach that keeps one instance active and hands over activity when it shuts down.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
When a subscription is deployed as a serverless function or container, it's hard to control how many instances are currently active. It will inevitably lead to multiple instances running simultaneously, processing the same events (which could be a problem) and overriding the checkpoint (another potential problem).
#161 suggests adding an HTTP API to subscriptions to report their positions. Another API could also expose the subscription presence with some unique id. The id could be generated on startup and remains static for a given running instance.
It would allow creating a self-managed distributed control plane for subscription services. It could work like this:
- A newly instantiated service makes several calls to its own HTTP endpoint, assuming the endpoint is load balanced with a round-robin strategy
- It will collect all the responses from running instances and can understand how many are there
- If there's only one instance, the subscription will mark itself as active. This status is included in the API response.
- If there are multiple instances, and one of them is active, the subscription doesn't start
- If there are multiple instances, and none of them is active, the subscription decides to become active after gossiping with other instances
- When a subscription receives a gossip call from some instance that wants to activate, it will ensure that it is not active. Otherwise, the request should be denied.
This process needs to run continuously, so when one active subscription gets shut down, some other instance will become active.
I foresee some race conditions during the elections, but I am not sure yet if it's relevant.
- 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 3 giorni fa. 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 3 giorni fa. 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 9 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 9 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
-
bug mcp misleading small
Difficoltà 2/5 1-3 ore Idoneità per principianti 77/100
I maintainer di solito rispondono entro 1 giorno
-
accessibility help wanted macos
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
dorlugasigal/annotator#42 ·
I maintainer di solito rispondono entro 1 giorno
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
AvaloniaUI/Avalonia#22568 ·
I maintainer di solito rispondono entro 2 giorni
-
[bug] 截图失败日志冲爆硬盘Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 63/100
babalae/better-genshin-impact#3846 · 2 commenti ·
I maintainer di solito rispondono entro 2 giorni
-
[辞書] ブルアカ->ブルーアーカイブAperta要トリアージ 辞書
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 68/100
I maintainer di solito rispondono entro 1 giorno