svc

package
v0.7.5 Latest Latest
Warning

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

Go to latest
Published: May 29, 2023 License: MIT Imports: 22 Imported by: 0

Documentation

Overview

package core

Index

Constants

This section is empty.

Variables

View Source
var ReportSchedule = "*/5 * * * * *"

ReportSchedule

View Source
var ReportSyncQueue []models.SyncReport

Functions

This section is empty.

Types

type Server

type Server struct {
	pb.UnimplementedStorageServer
	Config   *config.StorageConfig
	Schedule schedule.ScheduleManage
	Status   string
	G        *gin.Engine
	Driver   vo.Driver
}

Server

func NewSVC

func NewSVC() *Server

NewSVC

@return *Server

func (*Server) BeginSync added in v0.7.5

func (s *Server) BeginSync(sessions *models.SyncReport)

func (*Server) Download

func (s *Server) Download(ctx context.Context, in *pb.DownloadRequest) (*pb.DownloadReply, error)

func (*Server) HTTPServer

func (s *Server) HTTPServer()

HTTPServer

@receiver s

func (*Server) InitDriver

func (s *Server) InitDriver() error

func (*Server) ReportStatus

func (s *Server) ReportStatus()

func (*Server) RpcServer

func (s *Server) RpcServer()

RpcServer

@receiver s

func (*Server) Sync added in v0.7.5

func (s *Server) Sync(ctx context.Context, in *pb.SyncRequest) (*pb.SyncReply, error)

func (*Server) Upload

func (s *Server) Upload(ctx context.Context, in *pb.UploadRequest) (*pb.UploadReply, error)

Upload

@receiver s
@param ctx
@param in
@return *pb.UploadReply
@return error

Jump to

Keyboard shortcuts

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