dataloader

package
v0.24.1 Latest Latest
Warning

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

Go to latest
Published: Dec 9, 2019 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AlertLoader

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

func NewAlertLoader

func NewAlertLoader(ctx context.Context, store alert.Store) *AlertLoader

func (*AlertLoader) FetchOneAlert

func (l *AlertLoader) FetchOneAlert(ctx context.Context, id int) (*alert.Alert, error)

func (*AlertLoader) FetchOneAlertState

func (l *AlertLoader) FetchOneAlertState(ctx context.Context, alertID int) (*alert.State, error)

type CMLoader

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

CMLoader will load user contact methods from postgres.

func NewCMLoader

func NewCMLoader(ctx context.Context, store contactmethod.Store) *CMLoader

NewCMLoader will create a new CMLoader using the provided store for fetch operations.

func (*CMLoader) FetchOne

func (l *CMLoader) FetchOne(ctx context.Context, id string) (*contactmethod.ContactMethod, error)

FetchOne will fetch a single record from the store, batching requests to the store.

type HeartbeatMonitorLoader added in v0.24.0

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

func NewHeartbeatMonitorLoader added in v0.24.0

func NewHeartbeatMonitorLoader(ctx context.Context, store heartbeat.Store) *HeartbeatMonitorLoader

func (*HeartbeatMonitorLoader) FetchOne added in v0.24.0

type PolicyLoader

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

func NewPolicyLoader

func NewPolicyLoader(ctx context.Context, store escalation.Store) *PolicyLoader

func (*PolicyLoader) FetchOne

func (p *PolicyLoader) FetchOne(ctx context.Context, id string) (*escalation.Policy, error)

type RotationLoader

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

func NewRotationLoader

func NewRotationLoader(ctx context.Context, store rotation.Store) *RotationLoader

func (*RotationLoader) FetchOne

func (l *RotationLoader) FetchOne(ctx context.Context, id string) (*rotation.Rotation, error)

type ScheduleLoader

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

func NewScheduleLoader

func NewScheduleLoader(ctx context.Context, store schedule.Store) *ScheduleLoader

func (*ScheduleLoader) FetchOne

func (l *ScheduleLoader) FetchOne(ctx context.Context, id string) (*schedule.Schedule, error)

type ServiceLoader

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

func NewServiceLoader

func NewServiceLoader(ctx context.Context, store service.Store) *ServiceLoader

func (*ServiceLoader) FetchOne

func (l *ServiceLoader) FetchOne(ctx context.Context, id string) (*service.Service, error)

type UserLoader

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

func NewUserLoader

func NewUserLoader(ctx context.Context, store user.Store) *UserLoader

func (*UserLoader) FetchOne

func (l *UserLoader) FetchOne(ctx context.Context, id string) (*user.User, error)

Jump to

Keyboard shortcuts

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