Refresh emulator inactivity timeout on SDK-retried responses (blocked on SDK enhancement)

Aperta
#265 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
35/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
csharp
Ambito
cli

Direzione di ricerca

Read the shell's OperationProgressHandler implementation and how it is registered with the Cosmos SDK; the issue does not name file paths. First check whether the SDK enhancement Azure/azure-cosmos-dotnet-v3#6178 is available, since this work is explicitly blocked on it. Once available, implement per-attempt timeout refresh while excluding synthesized timeouts, then add a test with repeated 429 responses exceeding the timeout and verify the command completes.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Summary

OperationProgressHandler (added in #264) restarts the local-emulator inactivity timeout whenever the emulator returns a response. It is registered as a Cosmos SDK custom handler, and the SDK places custom handlers before its RetryHandler, so the handler sees only the final response of an operation, not the intermediate responses the SDK retries (for example 429).

Impact

A throttled operation against the local emulator can stay inside the SDK retry loop for longer than the 10-second inactivity limit. With the SDK's default rate-limit policy (up to 9 retries, up to 30 seconds of waiting), the shell can cancel the command and disconnect even though the emulator answered every attempt. Earlier writes remain committed. This only affects local-emulator connections; Azure accounts have no inactivity timeout.

Plan

  1. Request a supported per-attempt response notification from the SDK (Gateway and Direct, without changing custom-handler semantics): Azure/azure-cosmos-dotnet-v3#6178.
  2. Once it ships, use it in the shell to restart the inactivity timeout on each real response, still excluding SDK-synthesized timeouts, so stalled requests keep timing out.
  3. Add a test that simulates repeated 429 responses longer than the timeout and verifies the command completes.

This does not block current releases; integrate it in the first shell release after the SDK change is available.

Lingua principale
C#
Stelle
4
Fork
7
Merge medio
2g 4h
PR unite (30g)
26

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di Azure/CosmosDBShell

Tutte le issue di Azure/CosmosDBShell

Issue simili

Altre issue su C#

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.