-
Notifications
You must be signed in to change notification settings - Fork 244
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make sure event is recorded whenever telemetry preference is changed (#…
…6842) * Add integration test highlighting the expectations * Use the cancellable context derived from 'cmd.Context' where needed * Introduce new 'wasTelemetryEnabled' telemetry property This is recorded before any command is run. And it will help determine if telemetry was changed (e.g., from enabled to disabled), so that we can record the event in this case. * Send telemetry if it was enabled previously or if it is currently enabled This is done by reading the actual telemetry setting (either from env vars or the preferences file) at the moment we want to record the telemetry event. This covers cases where a command ('odo preference set ConsentTelemetry') or an environment variable ('ODO_TRACKING_CONSENT') updated the telemetry consent for example.
- Loading branch information
Showing
5 changed files
with
156 additions
and
53 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters