You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: initialize telemetry asynchronously without blocking (#666)
## Problem
VSCode Q chat experiences ~60-second delays when the telemetry endpoint
`aws-language-servers.us-east-1.amazonaws.com` is not allowlisted in
corporate networks.
Root Cause:
- Telemetry initialization runs synchronously during LSP server startup
- OTLPMetricExporter and OTLPLogExporter each attempt HTTP connections
with timeouts
- Chat remains unresponsive until all telemetry timeouts complete
https://github.com/user-attachments/assets/88f89a4d-5321-4019-a3ec-8e6c87631d77
## Solution
Make telemetry initialization to be non-blocking.
Changes:
- Wrap telemetry setup in setImmediate() callback
- LSP initialization returns immediately with `{ capabilities: {} }`
- Telemetry initializes asynchronously in background
## Testing
Chat responds quickly even when telemetry URL is blocked
https://github.com/user-attachments/assets/463bff7f-df24-4daf-80e9-086b073551f2
<!---
REMINDER:
- Read CONTRIBUTING.md first.
- Add test coverage for your changes.
- Link to related issues/commits.
- Testing: how did you test your changes?
- Screenshots if applicable
-->
## License
By submitting this pull request, I confirm that my contribution is made
under the terms of the Apache 2.0 license.
0 commit comments