ptinput

package
v0.1.11 Latest Latest
Warning

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

Go to latest
Published: Mar 27, 2024 License: MIT Imports: 10 Imported by: 0

Documentation

Overview

Package ptinput impl ppl input interface

Index

Constants

View Source
const Originkey = "message"

Variables

View Source
var DoFeedNOP = func(name, category string, pt *point.Point) error { return nil }

Functions

This section is empty.

Types

type DoFeedCache

type DoFeedCache func(name, category string, pt *point.Point) error

type InputWithVarbMapR

type InputWithVarbMapR interface {
	Get(key string) (any, ast.DType, bool)
}

type InputWithVarbMapRW

type InputWithVarbMapRW interface {
	Get(key string) (any, ast.DType, bool)
	Set(key string, value any, dtype ast.DType) bool
	Delete(key string) bool
}

type InputWithoutVarbMap

type InputWithoutVarbMap interface{}

type KeyKind

type KeyKind uint
const (
	KindPtDefault KeyKind = iota
	KindPtTag
)

type PlInputPt

type PlInputPt interface {
	GetPtName() string
	SetPtName(m string)

	Get(key string) (any, ast.DType, error)
	GetWithIsTag(key string) (any, bool, bool)
	Set(key string, value any, dtype ast.DType) error
	Delete(key string)
	RenameKey(from, to string) error

	SetTag(key string, value any, dtype ast.DType) error

	PtTime() time.Time

	GetAggBuckets() *plmap.AggBuckets
	SetAggBuckets(*plmap.AggBuckets)

	AppendSubPoint(PlInputPt)
	GetSubPoint() []PlInputPt
	Category() point.Category

	KeyTime2Time()

	MarkDrop(bool)
	Dropped() bool
	Point() *point.Point

	GetIPDB() ipdb.IPdb
	SetIPDB(ipdb.IPdb)

	GetPlReferTables() refertable.PlReferTables
	SetPlReferTables(refertable.PlReferTables)

	Tags() map[string]string
	Fields() map[string]any
}

func NewPlPoint

func NewPlPoint(category point.Category, name string,
	tags map[string]string, fields map[string]any, ptTime time.Time,
) PlInputPt

func WrapPoint

func WrapPoint(cat point.Category, pt *point.Point) PlInputPt

type PlPoint

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

func (*PlPoint) AppendSubPoint

func (pt *PlPoint) AppendSubPoint(plpt PlInputPt)

func (*PlPoint) Category

func (pt *PlPoint) Category() point.Category

func (*PlPoint) Delete

func (pt *PlPoint) Delete(key string)

func (*PlPoint) Dropped

func (pt *PlPoint) Dropped() bool

func (*PlPoint) Fields

func (pt *PlPoint) Fields() map[string]any

func (*PlPoint) Get

func (pt *PlPoint) Get(key string) (any, ast.DType, error)

func (*PlPoint) GetAggBuckets

func (pt *PlPoint) GetAggBuckets() *plmap.AggBuckets

func (*PlPoint) GetIPDB

func (pt *PlPoint) GetIPDB() ipdb.IPdb

func (*PlPoint) GetPlReferTables

func (pt *PlPoint) GetPlReferTables() refertable.PlReferTables

func (*PlPoint) GetPtName

func (pt *PlPoint) GetPtName() string

func (*PlPoint) GetSubPoint

func (pt *PlPoint) GetSubPoint() []PlInputPt

func (*PlPoint) GetWithIsTag

func (pt *PlPoint) GetWithIsTag(key string) (any, bool, bool)

func (*PlPoint) KeyTime2Time

func (pt *PlPoint) KeyTime2Time()

func (*PlPoint) MarkDrop

func (pt *PlPoint) MarkDrop(drop bool)

func (*PlPoint) Point

func (pt *PlPoint) Point() *point.Point

func (*PlPoint) PtTime

func (pt *PlPoint) PtTime() time.Time

func (*PlPoint) RenameKey

func (pt *PlPoint) RenameKey(from, to string) error

func (*PlPoint) Set

func (pt *PlPoint) Set(key string, value any, dtype ast.DType) error

func (*PlPoint) SetAggBuckets

func (pt *PlPoint) SetAggBuckets(buks *plmap.AggBuckets)

func (*PlPoint) SetIPDB

func (pt *PlPoint) SetIPDB(db ipdb.IPdb)

func (*PlPoint) SetPlReferTables

func (pt *PlPoint) SetPlReferTables(refTable refertable.PlReferTables)

func (*PlPoint) SetPtName

func (pt *PlPoint) SetPtName(m string)

func (*PlPoint) SetTag

func (pt *PlPoint) SetTag(key string, value any, dtype ast.DType) error

func (*PlPoint) Tags

func (pt *PlPoint) Tags() map[string]string

type PlmapManager

type PlmapManager interface {
}

type PtFlag

type PtFlag uint
const (
	PtMeasurement PtFlag = iota
	PtTag
	PtField
	PtTFDefaulutOrKeep
	PtTime
)

Directories

Path Synopsis
Package funcs for pipeline
Package funcs for pipeline
Package ipdb define the interface for ip location or isp.
Package ipdb define the interface for ip location or isp.
geoip
Package geoip implement ipdb.
Package geoip implement ipdb.
iploc
Package iploc implement ipdb.
Package iploc implement ipdb.
Package plmap used to store data during pl script execution
Package plmap used to store data during pl script execution
Package refertable for saving external data
Package refertable for saving external data
Package utils wraps utilities used by pipeline
Package utils wraps utilities used by pipeline

Jump to

Keyboard shortcuts

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