Skip to content

/search endpoint timing out (524) while core ingestion pipeline is healthy #2965

Description

@JakubIvacek

The /search endpoint on the public API (api.opendota.com/api/search) hangs indefinitely for any query longer than 2 characters, instead of returning results or an error. Eventually Cloudflare times out the connection with a 524 (Origin Timeout).

Steps to reproduce

curl -s --max-time 30 "https://api.opendota.com/api/search?q=Miracle"

never returns, even after 30s

curl -s -D - "https://api.opendota.com/api/search?q=Miracle" --max-time 60

eventually: HTTP/2 524, body: "error code: 524"

Compare with a 1-2 character query, which returns instantly:
curl -s "https://api.opendota.com/api/search?q=ab"

-> [] (200 OK, near-instant)

Additional testing

Reproduced consistently (8+ attempts over several minutes) across multiple query strings: Miracle, abc, kuro, sumail, puppey — all hang/timeout. Other endpoints on the same API are unaffected and respond normally in the same timeframe:

curl -s -o /dev/null -w "%{http_code} %{time_total}\n" "https://api.opendota.com/api/heroStats"

200, ~0.8s

curl -s -o /dev/null -w "%{http_code} %{time_total}\n" "https://api.opendota.com/api/players/1"

200, ~0.15s

curl -s -o /dev/null -w "%{http_code} %{time_total}\n" "https://api.opendota.com/api/explorer?sql=SELECT%201"

200, ~0.3s

This isolates the problem specifically to /search, not the API/Cloudflare/rate limiting in general.

Expected behavior

/search?q= returns matching players (or an empty array) within a reasonable time, as it does for short queries.

Actual behavior

Any query longer than 2 characters hangs and never returns a response, ultimately surfacing as a Cloudflare 524.

Environment


Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions