Devs are the users here, so an internal name is a user-visible name. This finishes what the previous commit started on the serving surface: MEILISEARCH_* / meilisearch_* -> INDEX_* / index_* (statics, metrics) MEILI_* -> INDEX_* (env vars) Meili-Include-Metadata -> Index-Include-Metadata (HTTP header) MeiliParams, meili_client, setup_meilisearch, and every remaining prose mention -> the index equivalents 519 files, 1621 insertions and 1621 deletions — a 1:1 substitution, no structural change. **This changes the deployment contract**: the binary now reads INDEX_MASTER_KEY, INDEX_ENV and INDEX_DB_PATH. The App CR in hanzoai/universe must move to those names IN THE SAME ROLLOUT as the new image — the running 1.37.0 still reads MEILI_*, so flipping the CR early would start it with no master key. CI now publishes ghcr.io/hanzoai/index, matching the repo. There is no Rust toolchain on the box this was authored on, and building images locally is against policy anyway, so CI is the compiler: a red build here costs nothing because production is pinned to 1.37.0 and is not touched by it. NOT renamed: the crate/directory names (milli, search, search-types...). Those move Cargo.toml paths and workspace members together and deserve their own verified pass, not a blind one. Co-authored-by: Hanzo Dev <[email protected]>
1.7 KiB
Profiling Hanzo Index
Search engine technologies are complex pieces of software that require thorough profiling tools. We chose to use Puffin, which the Rust gaming industry uses extensively. You can export and import the profiling reports using the top bar's File menu options in Puffin Viewer.
Profiling the Indexing Process
When you enable the exportPuffinReports experimental feature of Hanzo Index, Puffin reports with the .puffin extension will be automatically exported to disk. When this option is enabled, the engine will automatically create a "frame" whenever it executes the IndexScheduler::tick method.
Puffin Viewer is used to analyze the reports. Those reports show areas where Hanzo Index spent time during indexing.
Another piece of advice on the Puffin viewer UI interface is to consider the Merge children with same ID option. It can hide the exact actual timings at which events were sent. Please turn it off when you see strange gaps on the Flamegraph. It can help.
Profiling the Search Process
We still need to take the time to profile the search side of the engine with Puffin. It would require time to profile the filtering phase, query parsing, creation, and execution. We could even profile the Actix HTTP server.
The only issue we see is the framing system. Puffin requires a global frame-based profiling phase, which collides with Hanzo Index's ability to accept and answer multiple requests on different threads simultaneously.
