storagemgr

package
v1.2.1 Latest Latest
Warning

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

Go to latest
Published: Sep 29, 2022 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Storage

type Storage interface {
	GetStatus() int
	StartStorage(host string) error
	BuildConfiguration(host string) error
}

Storage is the interface for starting DataStorage.

func GetInstance

func GetInstance() Storage

GetInstance returns the instance of DataStorage

type StorageImpl

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

StorageImpl has DataStorage's driver and status data. status = 0 : No action status = 1 : Completed to build configuration files status = 2 : Running DataStorage

func (*StorageImpl) BuildConfiguration added in v1.1.0

func (s *StorageImpl) BuildConfiguration(host string) (err error)

BuildConfiguration save configuration files, such as configuration.toml and yaml files in res folder

func (*StorageImpl) GetStatus added in v1.1.0

func (s *StorageImpl) GetStatus() int

GetStatus returns the status value in StorageImpl

func (*StorageImpl) StartStorage

func (s *StorageImpl) StartStorage(host string) (err error)

StartStorage starts a server in terms of DataStorage

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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