scheduled_task

package
v0.30.0-beta.0 Latest Latest
Warning

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

Go to latest
Published: Nov 8, 2024 License: MIT Imports: 12 Imported by: 0

Documentation

Rendered for windows/amd64

Index

Constants

View Source
const Name = "scheduled_task"

Variables

View Source
var ConfigDefaults = Config{
	TaskExclude: types.RegExpEmpty,
	TaskInclude: types.RegExpAny,
}

Functions

This section is empty.

Types

type Collector

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

func New

func New(config *Config) *Collector

func NewWithFlags

func NewWithFlags(app *kingpin.Application) *Collector

func (*Collector) Build

func (c *Collector) Build(_ *slog.Logger, _ *mi.Session) error

func (*Collector) Close

func (c *Collector) Close(_ *slog.Logger) error

func (*Collector) Collect

func (c *Collector) Collect(_ *types.ScrapeContext, logger *slog.Logger, ch chan<- prometheus.Metric) error

func (*Collector) GetName

func (c *Collector) GetName() string

func (*Collector) GetPerfCounter

func (c *Collector) GetPerfCounter(_ *slog.Logger) ([]string, error)

type Config

type Config struct {
	TaskExclude *regexp.Regexp `yaml:"task_exclude"`
	TaskInclude *regexp.Regexp `yaml:"task_include"`
}

type TaskResult

type TaskResult uint
const (
	SCHED_S_SUCCESS          TaskResult = 0x0
	SCHED_S_TASK_HAS_NOT_RUN TaskResult = 0x00041303
)

type TaskState

type TaskState uint

TaskState ... https://docs.microsoft.com/en-us/windows/desktop/api/taskschd/ne-taskschd-task_state

const (
	TASK_STATE_UNKNOWN TaskState = iota
	TASK_STATE_DISABLED
	TASK_STATE_QUEUED
	TASK_STATE_READY
	TASK_STATE_RUNNING
)

func (TaskState) String

func (t TaskState) String() string

Jump to

Keyboard shortcuts

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