src.bluetooth_sig.utils.prewarm¶
Registry pre-warming for eager YAML loading.
Consumers that run inside an event loop (e.g. Home Assistant) should call
prewarm_registries() in an executor thread during setup to avoid
blocking I/O on first access.
Attributes¶
Name | Description |
|---|---|
Functions¶
Name | Description |
|---|---|
|
Eagerly load all bluetooth-sig YAML registries. |
Module Contents¶
- src.bluetooth_sig.utils.prewarm.prewarm_registries() None¶
Eagerly load all bluetooth-sig YAML registries.
Triggers the lazy-load path for every registry so that subsequent lookups are lock-free and allocation-free. This function performs synchronous file I/O and should be called from an executor thread when used inside an async framework.
Covers: - Characteristic registry (all characteristic classes) - Service registry (all service classes) - Units registry (unit UUID → symbol mapping) - Company identifiers registry (manufacturer ID → name) - AD types registry (advertising data type codes)
- src.bluetooth_sig.utils.prewarm.logger¶