telemetry

package
v1.0.63-beta.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 23, 2026 License: Apache-2.0 Imports: 14 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package telemetry hands completed CLI events to a short-lived sender process. The command process never initializes the SDK or waits for a network request.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func OptedOut

func OptedOut() bool

OptedOut preserves the existing DO_NOT_TRACK semantics, including "0".

func RunWorker

func RunWorker(args []string, input *os.File) bool

RunWorker handles only the private sender invocation, before command assembly. Even malformed input or an SDK panic must not become a business command.

func Submit

func Submit(event Event)

Submit waits only for a bounded local handoff. A successful handoff is not an acknowledgement of delivery. Incomplete handoffs are discarded by the worker.

Types

type Event

type Event struct {
	Protocol          int      `json:"protocol"`
	Version           string   `json:"version"`
	Command           string   `json:"command"`
	Path              string   `json:"path"`
	ExitCode          int      `json:"exitCode"`
	DurationMillis    int64    `json:"durationMillis"`
	CompletedAtMillis int64    `json:"completedAtMillis"`
	ErrorSummary      string   `json:"errorSummary,omitempty"`
	Identity          Identity `json:"identity"`
}

Event is a completed command, not the sender's own execution. No arguments, stdout, working directory, attribution, credentials, or arbitrary fields cross the process boundary.

type Identity

type Identity struct {
	UserID   string `json:"userId,omitempty"`
	UserName string `json:"userName,omitempty"`
	CorpID   string `json:"corpId,omitempty"`
}

Identity contains only the existing reviewed profile metadata projection.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL