runtime

package
v1.4.0 Latest Latest
Warning

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

Go to latest
Published: Nov 16, 2021 License: Apache-2.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewRuntimeService

func NewRuntimeService(options ...ServiceOption) pb.RuntimeServiceServer

Types

type BundleService

type BundleService interface {
	CheckPermission(req *apistructs.PermissionCheckRequest) (*apistructs.PermissionCheckResponseData, error)
	GetCluster(name string) (*apistructs.ClusterInfo, error)
	InspectServiceGroupWithTimeout(namespace string, name string) (*apistructs.ServiceGroup, error)
	GetApp(id uint64) (*apistructs.ApplicationDTO, error)
}

func NewBundleService

func NewBundleService() BundleService

type DBService

type DBService interface {
	GetRuntimeAllowNil(id uint64) (*dbclient.Runtime, error)
	FindRuntime(id spec.RuntimeUniqueId) (*dbclient.Runtime, error)
	FindLastDeployment(id uint64) (*dbclient.Deployment, error)
	FindDomainsByRuntimeId(id uint64) ([]dbclient.RuntimeDomain, error)
	GetRuntime(id uint64) (*dbclient.Runtime, error)
	UpdateRuntime(runtime *dbclient.Runtime) error
}

func NewDBService

func NewDBService(orm *gorm.DB) DBService

type EventManagerService

type EventManagerService interface {
	EmitEvent(e *events.RuntimeEvent)
}

type Service

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

func (*Service) DelRuntime

func (r *Service) DelRuntime(ctx context.Context, req *pb.DelRuntimeRequest) (*pb.Runtime, error)

func (*Service) Delete

func (r *Service) Delete(operator user.ID, orgID uint64, runtimeID uint64) (*pb.Runtime, error)

Delete turn status of runtime to be Deleting

func (*Service) GetRuntime

func (r *Service) GetRuntime(ctx context.Context, request *pb.GetRuntimeRequest) (*pb.RuntimeInspect, error)

GetRuntime Get detail information of a single runtime

func (*Service) Healthz

func (r *Service) Healthz(ctx context.Context, req *cpb.VoidRequest) (*cpb.VoidResponse, error)

type ServiceOption

type ServiceOption func(*Service) *Service

func WithBundleService

func WithBundleService(s BundleService) ServiceOption

func WithDBService

func WithDBService(db DBService) ServiceOption

func WithEventManagerService

func WithEventManagerService(evMgr EventManagerService) ServiceOption

Directories

Path Synopsis
Package mock is a generated GoMock package.
Package mock is a generated GoMock package.

Jump to

Keyboard shortcuts

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