* Telemetry for a completed full index (see TELEMETRY.md). The bounded flush * keeps init/index responsive (these commands just ran for seconds anyway) * while delivering the event promptly.
(
cg: { getStats(): { filesByLanguage: Record<string, number> }; getBackend(): string },
result: IndexResult,
)
| 722 | * while delivering the event promptly. |
| 723 | */ |
| 724 | async function recordIndexTelemetry( |
| 725 | cg: { getStats(): { filesByLanguage: Record<string, number> }; getBackend(): string }, |
| 726 | result: IndexResult, |
| 727 | ): Promise<void> { |
| 728 | recordIndexEvent(cg, result); |
| 729 | await getTelemetry().flushNow(); |
| 730 | } |
| 731 | |
| 732 | // ============================================================================= |
| 733 | // Commands |
no test coverage detected