meta

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Dec 30, 2024 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const ArgLiteral = "@ARG"
View Source
const (
	ProberEnvArg = "ARG"
)

Variables

View Source
var (
	ScriptCount       = metric.NewCounter("MetaScript")
	ProbeCount        = metric.NewCounter("MetaProbe")
	ProbeSuccessCount = metric.NewCounter("MetaProbeSuccess")
	ProbeFailureCount = metric.NewCounter("MetaProbeFailure")
)

Functions

This section is empty.

Types

type Data

type Data struct {
	// contains filtered or unexported fields
}

func NewData

func NewData(d map[string]any) *Data

func NewDataFromEnviron

func NewDataFromEnviron() *Data

func (Data) Get

func (d Data) Get(key string) (any, bool)

func (Data) MarshalJSON

func (d Data) MarshalJSON() ([]byte, error)

func (Data) MarshalYAML

func (d Data) MarshalYAML() (any, error)

func (*Data) Set

func (d *Data) Set(key string, value any)

func (Data) Unwrap

func (d Data) Unwrap() map[string]any

type Prober

type Prober interface {
	Probe(ctx context.Context, path string) (*Data, error)
}

type Reader

type Reader struct {
	// contains filtered or unexported fields
}

Reader parses Data jsonl.

func NewReader

func NewReader(r io.Reader) *Reader

func (Reader) Err

func (r Reader) Err() error

func (*Reader) Read

func (r *Reader) Read(ctx context.Context) chan *Data

type Script

type Script struct {
	// contains filtered or unexported fields
}

func NewScript

func NewScript(content, shell string, arg ...string) *Script

func (*Script) Close

func (s *Script) Close() error

func (*Script) Probe

func (s *Script) Probe(ctx context.Context, path string) (*Data, error)

Jump to

Keyboard shortcuts

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