services

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: May 8, 2021 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrApplicationNotFound error = errors.New("Application not found")
	ErrSessionNotFound     error = errors.New("Session not found")
	ErrSessionIsNotAlive   error = errors.New("Session is not alive")
)

Functions

This section is empty.

Types

type QueryService

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

func NewQueryService

func NewQueryService(environment utils.Environment, storage *storage.Session, applicationStorage *storage.Application) *QueryService

func (*QueryService) GetAliveSession

func (s *QueryService) GetAliveSession(uuid string) *models.Session

func (*QueryService) GetAllAliveSessions

func (s *QueryService) GetAllAliveSessions() []*models.Session

func (*QueryService) GetAllApplications

func (s *QueryService) GetAllApplications() []*models.Application

func (*QueryService) GetApplicationFailedSessions

func (s *QueryService) GetApplicationFailedSessions() []*models.Session

func (*QueryService) GetFailedSessionLogs

func (s *QueryService) GetFailedSessionLogs(uuid string) ([]models.Log, error)

func (*QueryService) GetMatchingCheckout

func (s *QueryService) GetMatchingCheckout(rawInput string) (checkout string, application string, path string, found bool)

GetMatchingCheckout The rawInput parameter is without prefix "/s/"

func (*QueryService) GetSessionLogsAndStatus

func (s *QueryService) GetSessionLogsAndStatus(uuid string, lastLogUUID string) ([]models.Log, models.SessionStatus, error)

func (*QueryService) GetSessionMetrics

func (s *QueryService) GetSessionMetrics(uuid string) ([]models.Metric, error)

func (*QueryService) GetSessionStatus

func (s *QueryService) GetSessionStatus(uuid string) (output.SessionStatus, error)

type RequestService

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

func NewRequestService

func NewRequestService(
	environment utils.Environment,
	sessionStorage *storage.Session,
	applicationStorage *storage.Application,
	mediator *background.Mediator) *RequestService

func (*RequestService) NewSession

func (s *RequestService) NewSession(checkout string, app string) (*queues.SessionBuildResult, error)

func (*RequestService) SessionDeletion

func (s *RequestService) SessionDeletion(uuid string) error

type StaticService

type StaticService struct {
	utils.RWLocker

	FileSystem http.FileSystem
	// contains filtered or unexported fields
}

func NewStaticService

func NewStaticService(environment utils.Environment) *StaticService

func (*StaticService) GetManager

func (s *StaticService) GetManager() []byte

func (*StaticService) GetSessionHelperContent

func (s *StaticService) GetSessionHelperContent() string

func (*StaticService) LoadSessionHelper

func (s *StaticService) LoadSessionHelper()

func (*StaticService) SetSessionHelperContent

func (s *StaticService) SetSessionHelperContent(helper string)

Jump to

Keyboard shortcuts

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