cronjob

package
v1.8.2 Latest Latest
Warning

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

Go to latest
Published: Jan 15, 2018 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FromCells

func FromCells(cells []dataselect.DataCell) []batch2.CronJob

func GetCronJobEvents

func GetCronJobEvents(client client.Interface, dsQuery *dataselect.DataSelectQuery, namespace, name string) (
	*common.EventList, error)

GetCronJobEvents gets events associated to cron job.

func GetCronJobJobs

func GetCronJobJobs(client client.Interface, metricClient metricapi.MetricClient,
	dsQuery *dataselect.DataSelectQuery, namespace, name string) (*job.JobList, error)

GetCronJobJobs returns list of jobs owned by cron job.

func ToCells

func ToCells(std []batch2.CronJob) []dataselect.DataCell

Types

type CronJob

type CronJob struct {
	ObjectMeta   api.ObjectMeta `json:"objectMeta"`
	TypeMeta     api.TypeMeta   `json:"typeMeta"`
	Schedule     string         `json:"schedule"`
	Suspend      *bool          `json:"suspend"`
	Active       int            `json:"active"`
	LastSchedule *metav1.Time   `json:"lastSchedule"`
}

CronJob is a presentation layer view of Kubernetes Cron Job resource.

type CronJobCell

type CronJobCell batch2.CronJob

func (CronJobCell) GetProperty

func (CronJobCell) GetResourceSelector

func (self CronJobCell) GetResourceSelector() *metricapi.ResourceSelector

type CronJobDetail

type CronJobDetail struct {
	ConcurrencyPolicy       string           `json:"concurrencyPolicy"`
	StartingDeadLineSeconds *int64           `json:"startingDeadlineSeconds"`
	ActiveJobs              job.JobList      `json:"activeJobs"`
	Events                  common.EventList `json:"events"`

	// Extends list item structure.
	CronJob `json:",inline"`

	// List of non-critical errors, that occurred during resource retrieval.
	Errors []error `json:"errors"`
}

CronJobDetail contains Cron Job details.

func GetCronJobDetail

func GetCronJobDetail(client k8sClient.Interface, dsQuery *dataselect.DataSelectQuery,
	metricClient metricapi.MetricClient, namespace, name string) (*CronJobDetail, error)

GetCronJobDetail gets Cron Job details.

type CronJobList

type CronJobList struct {
	ListMeta          api.ListMeta       `json:"listMeta"`
	CumulativeMetrics []metricapi.Metric `json:"cumulativeMetrics"`
	Items             []CronJob          `json:"items"`

	// Basic information about resources status on the list.
	Status common.ResourceStatus `json:"status"`

	// List of non-critical errors, that occurred during resource retrieval.
	Errors []error `json:"errors"`
}

CronJobList contains a list of CronJobs in the cluster.

func GetCronJobList

func GetCronJobList(client client.Interface, nsQuery *common.NamespaceQuery,
	dsQuery *dataselect.DataSelectQuery, metricClient metricapi.MetricClient) (*CronJobList, error)

GetCronJobList returns a list of all CronJobs in the cluster.

func GetCronJobListFromChannels

func GetCronJobListFromChannels(channels *common.ResourceChannels, dsQuery *dataselect.DataSelectQuery,
	metricClient metricapi.MetricClient) (*CronJobList, error)

GetCronJobListFromChannels returns a list of all CronJobs in the cluster reading required resource list once from the channels.

Jump to

Keyboard shortcuts

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