services

package
v0.0.0-...-33f46c2 Latest Latest
Warning

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

Go to latest
Published: May 31, 2023 License: Apache-2.0 Imports: 38 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BaseLangService

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

func (*BaseLangService) DepSvc

func (svc *BaseLangService) DepSvc() (depSvc DependencyService)

func (*BaseLangService) GetInstalledList

func (svc *BaseLangService) GetInstalledList(searchQuery string, pagination *entity2.Pagination) (depsResults []entity.DependencyResult, total int, err error)

func (*BaseLangService) Init

func (svc *BaseLangService) Init()

func (*BaseLangService) Install

func (svc *BaseLangService) Install(payload entity.InstallPayload) (err error)

func (*BaseLangService) InstallDependency

func (svc *BaseLangService) InstallDependency(msg *grpc.StreamMessage, msgData entity.MessageData)

func (*BaseLangService) SaveDependencyList

func (svc *BaseLangService) SaveDependencyList(msg *grpc.StreamMessage, msgData entity.MessageData)

func (*BaseLangService) Start

func (svc *BaseLangService) Start()

func (*BaseLangService) Uninstall

func (svc *BaseLangService) Uninstall(payload entity.UninstallPayload) (err error)

func (*BaseLangService) UninstallDependency

func (svc *BaseLangService) UninstallDependency(msg *grpc.StreamMessage, msgData entity.MessageData)

func (*BaseLangService) Update

func (svc *BaseLangService) Update() (err error)

func (*BaseLangService) UpdateDependencyList

func (svc *BaseLangService) UpdateDependencyList(msg *grpc.StreamMessage, msgData entity.MessageData)

UpdateDependencyList get dependency list on local node and send them to master node

type DependencyService

type DependencyService interface {
	Init()
	GetRepoList(query string, pagination *entity2.Pagination) (deps []models.Dependency, total int, err error)
	GetDependencies(params entity.UpdateParams) (deps []models.Dependency, err error)
	InstallDependencies(params entity.InstallParams) (err error)
	UninstallDependencies(params entity.UninstallParams) (err error)
	GetLatestVersion(dep models.Dependency) (v string, err error)
}

type IBaseLangService

type IBaseLangService interface {
	Init()
	Start()
	DepSvc() (depSvc DependencyService)
	GetInstalledList(searchQuery string, pagination *entity2.Pagination) (res []entity.DependencyResult, total int, err error)
	Install(payload entity.InstallPayload) (err error)
	Uninstall(payload entity.UninstallPayload) (err error)
	Update() (err error)
	UpdateDependencyList(msg *grpc.StreamMessage, msgData entity.MessageData)
	SaveDependencyList(msg *grpc.StreamMessage, msgData entity.MessageData)
	InstallDependency(msg *grpc.StreamMessage, msgData entity.MessageData)
	UninstallDependency(msg *grpc.StreamMessage, msgData entity.MessageData)
}

type NodeService

type NodeService struct {
	*BaseLangService
}

func NewNodeService

func NewNodeService(parent *Service) (svc *NodeService)

func (*NodeService) GetDependencies

func (svc *NodeService) GetDependencies(params entity.UpdateParams) (deps []models.Dependency, err error)

func (*NodeService) GetLatestVersion

func (svc *NodeService) GetLatestVersion(dep models.Dependency) (v string, err error)

func (*NodeService) GetRepoList

func (svc *NodeService) GetRepoList(query string, pagination *entity2.Pagination) (deps []models.Dependency, total int, err error)

func (*NodeService) Init

func (svc *NodeService) Init()

func (*NodeService) InstallDependencies

func (svc *NodeService) InstallDependencies(params entity.InstallParams) (err error)

func (*NodeService) UninstallDependencies

func (svc *NodeService) UninstallDependencies(params entity.UninstallParams) (err error)

type PythonService

type PythonService struct {
	*BaseLangService
}

func NewPythonService

func NewPythonService(parent *Service) (svc *PythonService)

func (*PythonService) GetDependencies

func (svc *PythonService) GetDependencies(params entity.UpdateParams) (deps []models.Dependency, err error)

func (*PythonService) GetLatestVersion

func (svc *PythonService) GetLatestVersion(dep models.Dependency) (v string, err error)

func (*PythonService) GetRepoList

func (svc *PythonService) GetRepoList(query string, pagination *entity2.Pagination) (deps []models.Dependency, total int, err error)

func (*PythonService) Init

func (svc *PythonService) Init()

func (*PythonService) InstallDependencies

func (svc *PythonService) InstallDependencies(params entity.InstallParams) (err error)

func (*PythonService) UninstallDependencies

func (svc *PythonService) UninstallDependencies(params entity.UninstallParams) (err error)

type Service

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

func GetService

func GetService() *Service

func NewService

func NewService() *Service

func (*Service) ColD

func (svc *Service) ColD() *mongo2.Col

func (*Service) ColL

func (svc *Service) ColL() *mongo2.Col

func (*Service) ColS

func (svc *Service) ColS() *mongo2.Col

func (*Service) ColT

func (svc *Service) ColT() *mongo2.Col

func (*Service) Init

func (svc *Service) Init() (err error)

func (*Service) NodeSvc

func (svc *Service) NodeSvc() IBaseLangService

func (*Service) PythonSvc

func (svc *Service) PythonSvc() IBaseLangService

func (*Service) SettingSvc

func (svc *Service) SettingSvc() *SettingService

func (*Service) SpiderSvc

func (svc *Service) SpiderSvc() *SpiderService

func (*Service) Start

func (svc *Service) Start() (err error)

func (*Service) Stop

func (svc *Service) Stop() (err error)

func (*Service) TaskSvc

func (svc *Service) TaskSvc() *TaskService

type SettingService

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

func NewSettingService

func NewSettingService(parent *Service) (svc *SettingService)

func (*SettingService) Col

func (svc *SettingService) Col() *mongo2.Col

func (*SettingService) Init

func (svc *SettingService) Init()

type SpiderService

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

func NewSpiderService

func NewSpiderService(parent *Service) (svc *SpiderService)

func (*SpiderService) Init

func (svc *SpiderService) Init()

type TaskService

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

func NewTaskService

func NewTaskService(parent *Service) (svc *TaskService)

func (*TaskService) Init

func (svc *TaskService) Init()

Jump to

Keyboard shortcuts

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