pub fn set_global_db(
db: AnalyticsDatabase,
) -> Result<(), Arc<AnalyticsDatabase>>Expand description
Install the global analytics database. Called once from the CLI / server
startup when analytics is enabled. Returns Err(_) if it has already been
initialised — callers should treat that as a no-op (the first installation
wins).
Wrapping the AnalyticsDatabase in Arc lets recorders take cheap clones
without holding the global cell.