import "golang.org/x/tools/internal/event/core"
Package core provides support for event based telemetry.
Export is called to deliver an event to the global exporter if set.
ExportPair is called to deliver a start event to the supplied exporter. It also returns a function that will deliver the end event to the same exporter. It will fill in the time.
Log1 takes a message and one label delivers a log event to the exporter. It is a customized version of Print that is faster and does no allocation.
Log2 takes a message and two labels and delivers a log event to the exporter. It is a customized version of Print that is faster and does no allocation.
Metric1 sends a label event to the exporter with the supplied labels.
Metric2 sends a label event to the exporter with the supplied labels.
SetExporter sets the global exporter function that handles all events. The exporter is called synchronously from the event call site, so it should return quickly so as not to hold up user code.
Start1 sends a span start event with the supplied label list to the exporter. It also returns a function that will end the span, which should normally be deferred.
Start2 sends a span start event with the supplied label list to the exporter. It also returns a function that will end the span, which should normally be deferred.
type Event struct {
// contains filtered or unexported fields
}
Event holds the information about an event of note that occurred.
CloneEvent event returns a copy of the event with the time adjusted to at.
Exporter is a function that handles events. It may return a modified context and event.
Package core imports 7 packages (graph) and is imported by 16 packages. Updated 2021-01-16. Refresh now. Tools for package owners.