executor

package
v0.0.0-...-44c4069 Latest Latest
Warning

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

Go to latest
Published: Nov 28, 2024 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Overview

Copyright Axis Communications AB.

For a full list of individual contributors, please see the commit history.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Copyright Axis Communications AB.

For a full list of individual contributors, please see the commit history.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Index

Constants

This section is empty.

Variables

View Source
var (
	BACKOFFLIMIT int32 = 0
	PARALLEL     int32 = 1
	COMPLETIONS  int32 = 1
	SECRETMODE   int32 = 0600
)

Functions

This section is empty.

Types

type Executor

Executor is the common interface for test executor instances

func Kubernetes

func Kubernetes(namespace string) Executor

Kubernetes returns a new Kubernetes executor

type KubernetesExecutor

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

func (KubernetesExecutor) Alive

func (k KubernetesExecutor) Alive(ctx context.Context, logger *logrus.Entry, id string) (bool, error)

Alive checks that a Kubernetes pod running a test runner is still alive

func (KubernetesExecutor) Cancel

func (k KubernetesExecutor) Cancel(ctx context.Context, logger *logrus.Entry, id string) error

Cancel stops a Kubernetes job. Since Kubernetes has no queue concept, the cancel function does nothing else.

func (KubernetesExecutor) Name

func (k KubernetesExecutor) Name() string

Name returns the name of this executor

func (KubernetesExecutor) Start

func (k KubernetesExecutor) Start(ctx context.Context, logger *logrus.Entry, executorSpec *executionspace.ExecutorSpec) (string, error)

Start starts a test runner Kubernetes pod.

func (KubernetesExecutor) Stop

func (k KubernetesExecutor) Stop(ctx context.Context, logger *logrus.Entry, name string) error

Stop stops a test runner Kubernetes pod

func (KubernetesExecutor) Wait

func (k KubernetesExecutor) Wait(ctx context.Context, logger *logrus.Entry, name string, executorSpec *executionspace.ExecutorSpec) (string, string, error)

Wait waits for a Kubernetes pod to start

Jump to

Keyboard shortcuts

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