scopeagent: Index | Files

package agent

import ""


Package Files

agent.go cache.go ci.go config.go container.go dependencies.go git.go ntp.go recorder.go remote_config.go report.go util.go

type Agent Uses

type Agent struct {
    // contains filtered or unexported fields

func NewAgent Uses

func NewAgent(options ...Option) (*Agent, error)

Creates a new Scope Agent instance

func (*Agent) Flush Uses

func (a *Agent) Flush()

Flush agent buffer

func (*Agent) Logger Uses

func (a *Agent) Logger() *log.Logger

func (*Agent) PrintReport Uses

func (a *Agent) PrintReport()

func (*Agent) Run Uses

func (a *Agent) Run(m *testing.M) int

Runs the test suite

func (*Agent) Stop Uses

func (a *Agent) Stop()

Stops the agent

func (*Agent) Tracer Uses

func (a *Agent) Tracer() opentracing.Tracer

type Config Uses

type Config struct {
    CurrentProfile string             `json:"currentProfile"`
    Profiles       map[string]Profile `json:"profiles"`

func GetConfig Uses

func GetConfig() *Config

type DiffFileItem Uses

type DiffFileItem struct {
    Path         string  `json:"path" msgpack:"path"`
    Added        int     `json:"added" msgpack:"added"`
    Removed      int     `json:"removed" msgpack:"removed"`
    Status       string  `json:"status" msgpack:"status"`
    PreviousPath *string `json:"previousPath" msgpack:"previousPath"`

type GitData Uses

type GitData struct {
    Repository string
    Commit     string
    SourceRoot string
    Branch     string

type GitDiff Uses

type GitDiff struct {
    Type    string         `json:"type" msgpack:"type"`
    Version string         `json:"version" msgpack:"version"`
    Uuid    string         `json:"uuid" msgpack:"uuid"`
    Files   []DiffFileItem `json:"files" msgpack:"files"`

type Option Uses

type Option func(*Agent)

func WithAgentType Uses

func WithAgentType(agentType string) Option

func WithApiEndpoint Uses

func WithApiEndpoint(apiEndpoint string) Option

func WithApiKey Uses

func WithApiKey(apiKey string) Option

func WithConfiguration Uses

func WithConfiguration(values map[string]interface{}) Option

func WithConfigurationKeys Uses

func WithConfigurationKeys(keys []string) Option

func WithDebugEnabled Uses

func WithDebugEnabled() Option

func WithGitInfo Uses

func WithGitInfo(repository string, commitSha string, sourceRoot string) Option

func WithGlobalPanicHandler Uses

func WithGlobalPanicHandler() Option

func WithHandlePanicAsFail Uses

func WithHandlePanicAsFail() Option

func WithMetadata Uses

func WithMetadata(values map[string]interface{}) Option

func WithRecorders Uses

func WithRecorders(recorders ...tracer.SpanRecorder) Option

func WithRetriesOnFail Uses

func WithRetriesOnFail(retriesCount int) Option

func WithServiceName Uses

func WithServiceName(service string) Option

func WithSetGlobalTracer Uses

func WithSetGlobalTracer() Option

func WithTestingModeEnabled Uses

func WithTestingModeEnabled() Option

func WithUserAgent Uses

func WithUserAgent(userAgent string) Option

type PayloadEvent Uses

type PayloadEvent map[string]interface{}

type PayloadSpan Uses

type PayloadSpan map[string]interface{}

type Profile Uses

type Profile struct {
    ApiEndpoint string `json:"apiEndpoint"`
    ApiKey      string `json:"apiKey"`
    OAuthToken  string `json:"oauthToken"`

func GetConfigCurrentProfile Uses

func GetConfigCurrentProfile() *Profile

type RecorderStats Uses

type RecorderStats struct {
    // contains filtered or unexported fields

type SpanRecorder Uses

type SpanRecorder struct {
    // contains filtered or unexported fields

func NewSpanRecorder Uses

func NewSpanRecorder(agent *Agent) *SpanRecorder

func (*SpanRecorder) Flush Uses

func (r *SpanRecorder) Flush() error

Flush recorder

func (*SpanRecorder) RecordSpan Uses

func (r *SpanRecorder) RecordSpan(span tracer.RawSpan)

Appends a span to the in-memory buffer for async processing

func (*SpanRecorder) Stop Uses

func (r *SpanRecorder) Stop()

Stop recorder

Package agent imports 39 packages (graph) and is imported by 2 packages. Updated 2020-06-30. Refresh now. Tools for package owners.