reconcile

package
v0.0.0-...-c0686e8 Latest Latest
Warning

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

Go to latest
Published: Dec 10, 2022 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 Metrics

type Metrics struct {
	ReconcileImplicitly      tally.Counter
	ReconcileImplicitlyFail  tally.Counter
	ReconcileExplicitly      tally.Counter
	ReconcileExplicitlyAbort tally.Counter
	ReconcileExplicitlyFail  tally.Counter
	ReconcileGetTasksFail    tally.Counter

	ExplicitTasksPerRun tally.Gauge
}

Metrics is a placeholder for all metrics in hostmgr reconciliation package.

func NewMetrics

func NewMetrics(scope tally.Scope) *Metrics

NewMetrics returns a new instance of Metrics.

type TaskReconciler

type TaskReconciler interface {
	Reconcile(running *atomic.Bool)
	SetExplicitReconcileTurn(flag bool)
}

TaskReconciler is the interface to initiate task reconciliation to mesos master.

func NewTaskReconciler

func NewTaskReconciler(
	client mpb.SchedulerClient,
	parent tally.Scope,
	frameworkInfoProvider hostmgr_mesos.FrameworkInfoProvider,
	activeJobsOps ormobjects.ActiveJobsOps,
	taskStore storage.TaskStore,
	cfg *TaskReconcilerConfig) TaskReconciler

NewTaskReconciler initialize the task reconciler.

type TaskReconcilerConfig

type TaskReconcilerConfig struct {
	// Initial delay before running reconciliation
	InitialReconcileDelaySec int `yaml:"initial_reconcile_delay_sec"`

	// Task reconciliation interval
	ReconcileIntervalSec int `yaml:"reconcile_interval_sec"`

	// Explicit reconcilication call interval between batches.
	ExplicitReconcileBatchIntervalSec int `yaml:"explicit_reconcile_batch_interval_sec"`

	// Explicit reconcile batch size.
	ExplicitReconcileBatchSize int `yaml:"explicit_reconcile_batch_size"`
}

TaskReconcilerConfig for task reconciler specific configuration

Jump to

Keyboard shortcuts

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