Commit Graph

2 Commits

Author SHA1 Message Date
Sanaei 99e7c5a827 perf(sub): read the configured public host once per subscription request
An inbound with a wildcard listen and no node takes its link host from
subDomain, then webDomain. That lookup ran for every link, so a
subscription with N such links issued 2N extra settings queries on top of
the batched render settings (7 instead of 1 for three links).

Load both keys in the per-request settings batch and keep the resolved
host on the request's SubService. The order subDomain, webDomain, request
host is unchanged.
2026-11-25 17:20:10 +03:30
Hamed c12a4f72c7 perf(subscription): batch render settings per request (#7203)
Every raw, JSON and Clash subscription request read its eight presentation settings (host sort mode, datepicker, identity and info-node toggles, the expired and depleted templates, inclusive expiry and its timezone) with one query each.

Read them in one query per request preparation. Missing keys, stored empty strings, duplicate keys and malformed booleans resolve as the single-key getters did, and a failed batch falls back to those getters so a readable setting keeps its value.

Closes #7201
2026-11-25 15:01:54 +03:30