handlers

package
v3.2.2 Latest Latest
Warning

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

Go to latest
Published: Sep 5, 2024 License: Apache-2.0 Imports: 30 Imported by: 0

Documentation

Index

Constants

View Source
const (
	SupervisorPath  = "./supervisor"
	NodeSelectorKey = "kubernetes.io/hostname"

	// Annotations for InterLink nodes
	InterLinkDNSPolicy          = "ClusterFirst"
	InterLinkRestartPolicy      = "OnFailure"
	InterLinkTolerationKey      = "virtual-node.interlink/no-schedule"
	InterLinkTolerationOperator = "Exists"
)

Variables

This section is empty.

Functions

func HealthHandler

func HealthHandler(c *gin.Context)

HealthHandler health handler for kubernetes deployment

func MakeConfigHandler

func MakeConfigHandler(cfg *types.Config) gin.HandlerFunc

MakeConfigHandler makes a handler for getting server's configuration

func MakeCreateHandler

func MakeCreateHandler(cfg *types.Config, back types.ServerlessBackend) gin.HandlerFunc

MakeCreateHandler makes a handler for creating services

func MakeDeleteHandler

func MakeDeleteHandler(cfg *types.Config, back types.ServerlessBackend) gin.HandlerFunc

MakeDeleteHandler makes a handler for deleting services

func MakeDeleteJobHandler

func MakeDeleteJobHandler(back types.ServerlessBackend, kubeClientset *kubernetes.Clientset, namespace string) gin.HandlerFunc

MakeDeleteJobHandler makes a handler for removing a job

func MakeDeleteJobsHandler

func MakeDeleteJobsHandler(back types.ServerlessBackend, kubeClientset *kubernetes.Clientset, namespace string) gin.HandlerFunc

MakeDeleteJobsHandler makes a handler for deleting all jobs created by the provided service. If 'all' querystring is set to 'true' pending, running and failed jobs will also be deleted

func MakeGetLogsHandler

func MakeGetLogsHandler(back types.ServerlessBackend, kubeClientset *kubernetes.Clientset, namespace string) gin.HandlerFunc

MakeGetLogsHandler makes a handler for getting logs from the 'oscar-container' inside the pod created by the specified job

func MakeInfoHandler

func MakeInfoHandler(kubeClientset kubernetes.Interface, back types.ServerlessBackend) gin.HandlerFunc

MakeInfoHandler makes a handler to retrieve system info

func MakeJobHandler

MakeJobHandler makes a han/home/slangarita/Escritorio/interlink-cluster/PodCern/PodCern.yamldler to manage async invocations

func MakeJobsInfoHandler

func MakeJobsInfoHandler(back types.ServerlessBackend, kubeClientset *kubernetes.Clientset, namespace string) gin.HandlerFunc

MakeJobsInfoHandler makes a handler for listing all existing jobs from a service and show their JobInfo

func MakeListHandler

func MakeListHandler(back types.ServerlessBackend) gin.HandlerFunc

MakeListHandler makes a handler for listing services

func MakeReadHandler

func MakeReadHandler(back types.ServerlessBackend) gin.HandlerFunc

MakeReadHandler makes a handler for reading a service

func MakeRunHandler

func MakeRunHandler(cfg *types.Config, back types.SyncBackend) gin.HandlerFunc

MakeRunHandler makes a handler to manage sync invocations sending them to the gateway of the ServerlessBackend

func MakeStatusHandler added in v3.1.0

func MakeStatusHandler(kubeClientset *kubernetes.Clientset, metricsClientset *versioned.MetricsV1beta1Client) gin.HandlerFunc

MakeStatusHandler Status handler for kubernetes deployment.

func MakeUpdateHandler

func MakeUpdateHandler(cfg *types.Config, back types.ServerlessBackend) gin.HandlerFunc

MakeUpdateHandler makes a handler for updating services

Types

type NodeInfo added in v3.1.0

type NodeInfo struct {
	NodeName         string `json:"nodeName"`
	CPUCapacity      string `json:"cpuCapacity"`
	CPUUsage         string `json:"cpuUsage"`
	CPUPercentage    string `json:"cpuPercentage"`
	MemoryCapacity   string `json:"memoryCapacity"`
	MemoryUsage      string `json:"memoryUsage"`
	MemoryPercentage string `json:"memoryPercentage"`
}

Jump to

Keyboard shortcuts

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