Expand description
The LoonFS server.
Hosts an embedded loonfs runtime behind the v0 HTTP API for
remote-mode clients, with per-namespace write batching in front of the
commit protocol. Embedded-mode callers skip this crate entirely and use
loonfs directly.
Structs§
- Grep
Config - The server’s
[grep]table. - Runtime
Cache Config Overrides - Server
Config - The server config file.
- TlsServer
Config - The server’s TLS identity: one certificate chain and its private key, both read at startup. A file that is missing, unreadable, or not the PEM it claims to be fails the process rather than degrading to plaintext.
Enums§
- Grep
Mode - What this server does about grep: answer queries, keep the index built, both, or neither.
- Maintenance
Mode - Whether this server maintains the namespaces it touches.
- Serve
Error - Failure starting or running the HTTP server.
- Server
Config Error - Store
Config - Provider selection plus credentials, as written in config files.
- TlsConfig
Error - Why the configured TLS identity could not be used. Every variant names the file it came from; none of them carry key material.
- Trace
Init Error
Functions§
- app
- Builds the HTTP application: the router that serves requests, and the writer whose background work its host must settle.
- init_
tracing_ from_ env - load_
server_ config - serve
- Serves until ctrl-c or SIGTERM, then shuts down gracefully: the listener stops accepting, in-flight requests drain, publisher work finishes, and writer maintenance — the runtime’s steps and grep’s alike — settles before this returns.
- serve_
with_ shutdown servewith a caller-supplied shutdown trigger instead of process signals, for hosts that manage their own lifecycle.