Http4s Blaze Client wait queue full failure
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 25/100
- Tipo di issue
- Bug
- Chiarezza
- Da chiarire
- Stato di attività
- Ferma
- Stack tecnologico
- scala
- Ambito
- api, backend, networking
Direzione di ricerca
Inizia da BlazeClientBuilder e dalla sua configurazione withMaxWaitQueueLimit, quindi traccia PoolManager e WaitQueueFullFailure in presenza di molte richieste GET in uscita concorrenti. Riproduci lo stato di coda piena usando http4s-blaze-client 0.21.0-M6 e determina se le richieste lente o scadute impediscono il recupero. Il lavoro è completato quando sono disponibili una causa comprovata e una modifica chiaramente circoscritta per il recupero o la limitazione delle richieste.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
We have a use case where for a single incoming request, a microservice has to make many(in the order of 1000s) outgoing HTTP calls to other microservice to fetch GET some details. Our service is built using Scala, Http4s and Cats-Effect and is using http4s-blaze-client library for making outbound HTTP calls.
Currently in production we are seeing the failure org.http4s.client.WaitQueueFullFailure: Wait queue is full and org.http4s.client.PoolManager: Max wait queue limit of 1024 reached, not scheduling. Once the service goes into this state, its never recovering from it and we are completely blocked.
Below is the Blaze Client configuration we are using:
BlazeClientBuilder[F](global)
.withMaxWaitQueueLimit(1024)
.withRequestTimeout(20.seconds)
.resource
.map { client =>
ResponseLogger(logHeaders = false, logBody = true)(
RequestLogger(logHeaders = true, logBody = true, redactHeadersWhen = Middleware.SensitiveHeaders)(client)
)
}
Initially we were using the default setting of 256 for max wait queue limit but then decided to increase to 512 and then to 1024. Currently even the 1024 is not working.
I am not sure if this happens when the outbound HTTP request is slow or times out. There is a possibility that the API response is slow sometimes(but that will still return within 20seconds timeout that we set). But I do not have sufficient evidence to claim that it is the case here.
We are currently using the version http4s-blaze-client_2.13:0.21.0-M6.
I am not sure if increasing the wait queue size further would help. Is it possible to implement custom logic within the service to check the wait queue size and wait before submitting the request to the client? Please advise how to get around with this issue. Any help would be really appreciated.
- Lingua principale
- Scala
- Stelle
- 371
- Fork
- 63
- Merge medio
- 2g 5h
- PR unite (30g)
- 6
Preparare l'ambiente
- Nessun Dockerfile né 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 http4s/blaze
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 25/100
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 35/100
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 30/100
-
support
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 45/100
Tutte le issue di http4s/blaze
Issue simili
-
Bound wrong-magic P2P diagnostics to parsed header bytesForse già presa Una pull request collegata a questa issue è aperta o già unita. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
ergoplatform/ergo#2736 ·
I maintainer di solito rispondono entro 1 giorno
-
area:shuffle enhancement good first issue performance requires-triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
apache/datafusion-comet#7072 ·
I maintainer di solito rispondono entro 1 giorno
-
bug 🐞 CI/CD ⚒️
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
valkey-io/valkey-glide#7370 ·
I maintainer di solito rispondono entro 1 giorno
-
Improve UI text on confirmation page (at registration)Forse già presa @Arghyann l’ha presa oggi. Apertagood first issue improvement
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 72/100
lichess-org/lila#22126 · 2 commenti ·
I maintainer di solito rispondono entro 1 giorno
-
[VL] Remove the unused ShuffleSchema.hForse già presa Una pull request collegata a questa issue è aperta o già unita. Aperta
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 82/100
I maintainer di solito rispondono entro 2 giorni