[Fix] Hyperscan cache: use Lua backend for sync loading, load on worker startup
Two issues addressed:
1. Sync loading now uses Lua backend exclusively instead of duplicating
file loading logic in C. The Lua backend handles files, compression,
and future backends (redis, http) uniformly.
2. Workers now proactively load hyperscan on startup after Lua backend
is initialized. This fixes a race condition where workers spawned
after hs_helper broadcasts HYPERSCAN_LOADED would never receive the
notification and run without hyperscan acceleration.
Changes:
- Add rspamd_hs_cache_lua_load_sync() and rspamd_hs_cache_lua_exists_sync()
to call Lua backend's sync methods from C
- Remove duplicated C file loading code from re_cache.c (zstd decompress,
file path checking) - Lua backend handles this
- rspamd_re_cache_load_hyperscan() now requires Lua backend
- Workers try sync load on startup (best-effort, falls back to PCRE)