This commit is contained in:
Shreyas Goenka 2024-11-29 02:02:18 +01:00
parent bfabca17a4
commit d14f4762e1
No known key found for this signature in database
GPG Key ID: 92A07DF49CCB0622
1 changed files with 1 additions and 1 deletions

View File

@ -51,7 +51,7 @@ var MaxAdditionalWaitTime = 2 * time.Second
// We make the API call to the /telemetry-ext endpoint to log the CLI telemetry events
// right about as the CLI command is about to exit. The API endpoint can handle
// payloads with ~1000 events easily. Thus we log all the events at once instead of
// batching the API calls.
// batching the logs across multiple API calls.
func Flush(ctx context.Context, apiClient DatabricksApiClient) {
// Set a maximum time to wait for the telemetry event to flush.
ctx, _ = context.WithTimeout(ctx, MaxAdditionalWaitTime)