fix(health): use fresh httpx client per qdrant check to avoid stale connection pool
Some checks failed
CI / build (push) Failing after 10s
Some checks failed
CI / build (push) Failing after 10s
This commit is contained in:
parent
01cb548f8f
commit
3c6b29563f
1 changed files with 5 additions and 4 deletions
|
|
@ -123,10 +123,11 @@ async def _check_neo4j() -> dict[str, Any]:
|
|||
|
||||
async def _check_qdrant() -> dict[str, Any]:
|
||||
try:
|
||||
client = await _get_http_client()
|
||||
resp = await client.get(f'{QDRANT_URL.rstrip(chr(47))}/collections')
|
||||
data = resp.json()
|
||||
collections = data.get("result", {}).get("collections", [])
|
||||
import httpx
|
||||
async with httpx.AsyncClient(timeout=5.0) as client:
|
||||
resp = await client.get(f"{QDRANT_URL.rstrip(chr(47))}/collections")
|
||||
data = resp.json()
|
||||
collections = data.get("result", {}).get("collections", [])
|
||||
return {
|
||||
"healthy": resp.status_code == 200,
|
||||
"details": {"collection_count": len(collections)},
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue