Releases: microsoft/vscode-extension-telemetry
Better align telemetry reporters across desktop and web
Note: This release contains a breaking change to the typings.
The ability to log a raw Error
object has been removed. You will now have to use sendTelemetryErrorEvent
and break the error stack down into the properties you want due to the web app insights and 1DS library both not supporting this. We want the module to abstract the details away and offer a uniform experience across all platforms.
Also fixes a bug surrounding not logging events properly on shutdown.
Utilize the new telemetry API
Note: This breaks the .d.ts
file in that it removes some extension specific information from the constructor in favor of just supplying the key.
This module will now directly consume the VS Code telemetry API announced with the release of 1.75.0. This API should vastly improve the telemetry experience.
New Features
- Automatic error handling logged to your
sendTelemetryException
function. - A shared
Extension Telemetry
output channel that allows you to see and debug the flow of telemetry in product when log level is set to trace - PII cleaning which is automatically updated with the version of VS Code
- Support for the new
Error
telemetry level rather than a simple on off switch.
Skip bundling new 1DS SDK
Stops bundling the 1DS SDK due to issues with webpack. The hopes is to eventually stop bundling app insights as well as the weird bundling structure of mixing esbuild and webpack can cause issues for extensions.
1st Party 1DS SDK + Moving off old endpoint
Note: This release only addresses issues affecting 1st party extensions
- Adds support for 1DS SDK and Common Schema 4.0 with the deprecation of Common Schema 2.0
- Switches 1st party endpoints from vortex to collector++ (this allows for backwards compatibility of CS 2.0 so old extensions can still work)
Remove errorProps parameter
Note: This release breaks the .d.ts
by removing errorProps
as a parameter option from sendTelemetryErrorEvent
.
ErrorProps used to be used for certain environments that required special compliance. This parameter only affected first party extensions and led to a lot of confusion surrounding when errorProps applied. To help unify the first and third party experience the errorProps parameter has been removed.
Fix missing `extensionID` in telemetry error event
- Fixes missing extensionID prefix when using any of the
sendTelemetryErrorEvent
functions - Some community contributed README polish
Allow telemetry module to work in extension testing environments
Currently VS Code disables telemetry when developing an extension or running extension tests. In some cases one might want to send telemetry in these cases.
This releases adds a set of sendDangerous*
functions which will send telemetry without checking the user setting. As described in the name these functions are dangerous and should only be used in controlled environments such as extension tests or during development.
Support for custom regex replacements
Thanks to @aeisenberg we now support a set of replacement options which can be used for custom redaction.
The reporter will now check every event for the set of regular expressions and replace them with the defined replacement strings. As with anything regex related this has the opportunity to cause significant performance degradation due to inefficient regular expressions.
This change is backwards compatible with previous versions, but does introduce a new optional parameter to the TelemetryReporter
in the form of a ReplacementOption list. The new typings can be found in the bundled .d.ts
file.
Minor error messaging changes
Added more verbose error messages to help track down cases where the module fails to initialize or events fail to send.
Better support for web errors
- Previously errors were disabled on the web, but recent build changes within core VS Code and the extension have allowed us to now send error telemetry on the web. This release just serves to remove the safety guards previously preventing that.