analytics

package
v2.42.2 Latest Latest
Warning

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

Go to latest
Published: Jul 30, 2026 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const (
	BuildExecutionID    = "build_execution_id"
	WorkflowExecutionID = "workflow_execution_id"
	StepExecutionID     = "step_execution_id"

	ToolSnapshotEndOfWorkflowValue = "end_of_workflow"

	StepExecutionIDEnvKey = "BITRISE_STEP_EXECUTION_ID"
)
View Source
const (
	DisabledEnvKey = "BITRISE_ANALYTICS_DISABLED"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Input

type Input struct {
	Value         interface{} `json:"value"`
	OriginalValue string      `json:"original_value,omitempty"`
}

type StateChecker

type StateChecker interface {
	Enabled() bool
}

func NewStateChecker

func NewStateChecker(repository env.Repository) StateChecker

type StepInfo

type StepInfo struct {
	StepID      string
	StepTitle   string
	StepVersion string
	StepSource  string
	Skippable   bool
}

type StepResult

type StepResult struct {
	Info                     StepInfo
	Status                   models.StepRunStatus
	ErrorMessage             string
	Timeout, NoOutputTimeout time.Duration
	Runtime                  time.Duration
}

type Tracker

type Tracker interface {
	SendWorkflowStarted(properties analytics.Properties, name string, title string)
	SendWorkflowFinished(properties analytics.Properties, failed bool)
	SendStepStartedEvent(properties analytics.Properties, info StepInfo, activateDuration time.Duration, expandedInputs map[string]interface{}, originalInputs map[string]string)
	SendStepFinishedEvent(properties analytics.Properties, result StepResult)
	SendCLIWarning(message string)
	SendCommandInfo(command, subcommand string, flags []string)
	SendToolSetupEvent(provider string, request provider.ToolRequest, result provider.ToolInstallResult, is_successful bool, setupTime time.Duration)
	SendStepActivationEvent(stepExecutionID string, activationType activator.ActivationType, inventorySource activator.ActivationInventorySource, ref string, isSuccessful bool, duration time.Duration, didSteplibUpdate bool)
	SendToolkitPrepareEvent(stepExecutionID string, toolkitName string, stepID string, stepVersion string, result toolkits.PrepareForStepRunResult, err error)
	IsTracking() bool
	Wait()
}

func NewDefaultTracker

func NewDefaultTracker() Tracker

func NewTracker

func NewTracker(analyticsTracker analytics.Tracker, envRepository env.Repository, stateChecker StateChecker, logger utilslog.Logger) Tracker

Jump to

Keyboard shortcuts

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