mirakurun

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Nov 16, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MirakurunChannel

type MirakurunChannel struct {
	Type     string      `json:"type"`
	Services []*struct{} `json:"services"`
}

type MirakurunClient

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

func NewMirakurunClient

func NewMirakurunClient(baseURL string) *MirakurunClient

func (*MirakurunClient) GetChannels

func (c *MirakurunClient) GetChannels(ctx context.Context) ([]*MirakurunChannel, error)

func (*MirakurunClient) GetStatus

func (c *MirakurunClient) GetStatus(ctx context.Context) (*MirakurunStatus, error)

func (*MirakurunClient) GetTuners

func (c *MirakurunClient) GetTuners(ctx context.Context) ([]*MirakurunTuner, error)

type MirakurunStatus

type MirakurunStatus struct {
	Process *struct {
		MemoryUsage *struct {
			RSS          int `json:"rss"`
			HeapTotal    int `json:"heapTotal"`
			HeapUsed     int `json:"heapUsed"`
			External     int `json:"external"`
			ArrayBuffers int `json:"arrayBuffers"`
		} `json:"memoryUsage"`
	} `json:"process"`
	EPG *struct {
		StoredEvents int `json:"storedEvents"`
	} `json:"epg"`
	RPCCount    int `json:"rpcCount"`
	StreamCount *struct {
		TunerDevice int `json:"tunerDevice"`
		TSFilter    int `json:"tsFilter"`
		Decoder     int `json:"decoder"`
	} `json:"streamCount"`
	ErrorCount *struct {
		UncaughtException  int `json:"uncaughtException"`
		UnhandledRejection int `json:"unhandledRejection"`
		BufferOverflow     int `json:"bufferOverflow"`
		TunerDeviceRespawn int `json:"tunerDeviceRespawn"`
		DecoderRespawn     int `json:"decoderRespawn"`
	} `json:"errorCount"`
	TimerAccuracy *struct {
		Last float64 `json:"last"`
		M1   *struct {
			Avg float64 `json:"avg"`
			Min float64 `json:"min"`
			Max float64 `json:"max"`
		} `json:"m1"`
		M5 *struct {
			Avg float64 `json:"avg"`
			Min float64 `json:"min"`
			Max float64 `json:"max"`
		} `json:"m5"`
		M15 *struct {
			Avg float64 `json:"avg"`
			Min float64 `json:"min"`
			Max float64 `json:"max"`
		} `json:"m15"`
	} `json:"timerAccuracy"`
}

type MirakurunTuner

type MirakurunTuner struct {
	IsAvailable bool `json:"isAvailable"`
	IsRemote    bool `json:"isRemote"`
	IsFree      bool `json:"isFree"`
	IsUsing     bool `json:"isUsing"`
	IsFault     bool `json:"isFault"`
}

type Plugin

type Plugin struct {
	MirakurunBaseURL string `toml:"-" env:"MIRAKURUN_BASE_URL" envDefault:"http://localhost:40772"`
	// contains filtered or unexported fields
}

func (*Plugin) Gather

func (p *Plugin) Gather(accumulator telegraf.Accumulator) error

func (*Plugin) Init

func (p *Plugin) Init() error

func (*Plugin) SampleConfig

func (p *Plugin) SampleConfig() string

Jump to

Keyboard shortcuts

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