usage

package
v2.51.0 Latest Latest
Warning

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

Go to latest
Published: Apr 15, 2024 License: Apache-2.0 Imports: 12 Imported by: 4

Documentation

Index

Constants

View Source
const (
	ReportUsagePrefix = "Usage Report:"
)

Variables

This section is empty.

Functions

func ShouldReportUsage

func ShouldReportUsage() (reportUsage bool)

Types

type ReportFeature

type ReportFeature struct {
	FeatureId  string
	ClientId   string
	Attributes []ReportUsageAttribute
}

type ReportUsageAttribute

type ReportUsageAttribute struct {
	AttributeName  string
	AttributeValue string
}

type UsageReporter

type UsageReporter struct {
	ProductId string
	// contains filtered or unexported fields
}

func NewUsageReporter

func NewUsageReporter(productId string, serverDetails *config.ServerDetails) *UsageReporter

func (*UsageReporter) Report

func (ur *UsageReporter) Report(features ...ReportFeature)

Report usage to Artifactory, Xray and Ecosystem

func (*UsageReporter) SetSendToArtifactory

func (ur *UsageReporter) SetSendToArtifactory(send bool) *UsageReporter

func (*UsageReporter) SetSendToEcosystem

func (ur *UsageReporter) SetSendToEcosystem(send bool) *UsageReporter

func (*UsageReporter) SetSendToXray

func (ur *UsageReporter) SetSendToXray(send bool) *UsageReporter

func (*UsageReporter) WaitForResponses

func (ur *UsageReporter) WaitForResponses() (err error)

Jump to

Keyboard shortcuts

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