-
Notifications
You must be signed in to change notification settings - Fork 26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added telemetry support. #448
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
General comment: I was confused by the use of log
and GetLogger
for telemetry events. We use very similar names for functions that log things to stdout/stderr, for example. Could we use something like logTelemetryEvent
or telemetryEvent
to be more noticeably different?
See the comments from David's review explaining the rationale behind this. |
While I agree that "telemetry" isn't a verb, the verb shouldn't just be "log" for telemetry events; that's ambiguous. I'd prefer that |
@JasonWeill @dlqqq |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome work!
* Added telemetry support. * Fixed lint errors * Refactored to use a logger hook. * Corrected the handler and token names. * Corrected the plugin id to match the token. * Updated names for hook and handler
* Added telemetry support. * Fixed lint errors * Refactored to use a logger hook. * Corrected the handler and token names. * Corrected the plugin id to match the token. * Updated names for hook and handler
Description
This PR adds support for telemetry and emits data for different events in the Scheduler components. A new plugin is provided that receives the event data. Implementors can disable the default plugin and provide their own implementation that will pass the telemetry data to their handler.
Event log examples
Advanced options expanded
Create job cancel button clicked
Create job run on schedule option selected
Providing your implementation to process telemetry events
Create a new handler and a plugin that provides the handler.
Disable the default plugin in the
package.json
file of your extension package.Attaching new events to telemetry handler
A new hook
useLogger
is available that could be accessed in any component.Any event handler can then call the
log
to pass in the event name.