setup

package
v1.1.1 Latest Latest
Warning

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

Go to latest
Published: Mar 22, 2021 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type File

type File struct {
	Name string
	// contains filtered or unexported fields
}

File represents a query file and related metadata to keep it up to date and registered with the prometheus collector registry.

func (*File) IsModified

func (f *File) IsModified() (bool, error)

IsModified reports true if the file has been modified since the last call. The first call should almost always return false.

func (*File) Register

func (f *File) Register(c *sql.Collector) error

Register the given collector. If a collector was previously registered with this file, then it is unregistered first. If either registration or unregister fails, then the error is returned.

func (*File) Update

func (f *File) Update() error

Update runs the collector query again.

Jump to

Keyboard shortcuts

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