agent

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Sep 19, 2023 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DBNotificationThread

func DBNotificationThread(ctx context.Context, pool *pgxpool.Pool, jobQueue *JobChan)

func InitalizePrometheus

func InitalizePrometheus()

func PrometheusListenerThread

func PrometheusListenerThread()

func RegisterAgent

func RegisterAgent(pool *pgxpool.Pool, provider string)

func WorkerThread

func WorkerThread(ctx context.Context, w Worker)

Types

type JobChan

type JobChan chan job

func (*JobChan) Dequeue

func (j *JobChan) Dequeue() (string, strfmt.UUID)

func (*JobChan) Enqueue

func (j *JobChan) Enqueue(model string, id strfmt.UUID) error

type Worker

type Worker interface {
	ProcessServices(context.Context) error
	ProcessEndpoint(context.Context, strfmt.UUID) error
	GetJobQueue() *JobChan
}

Directories

Path Synopsis
f5
as3

Jump to

Keyboard shortcuts

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