db

package
v0.0.0-...-58e557b Latest Latest
Warning

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

Go to latest
Published: May 27, 2022 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	LevelDB *leveldb.DB
)

Functions

func AddRefPodInfo

func AddRefPodInfo(nicID, podName, namespace string) error

func CloseDB

func CloseDB()

func DeleteNetworkInfo

func DeleteNetworkInfo(nicID string) error

func DeleteRefPodInfo

func DeleteRefPodInfo(nicID, podName, namespace string) (err error)

set nic reference pod array empty here wait for Sync thread to release Nic resource

func GetActivePodsByRefNicID

func GetActivePodsByRefNicID(nicID string, podOnNodeMap map[string]bool) ([]string, error)

func GetPodUniName

func GetPodUniName(podName, namespace string) string

func Iterator

func Iterator(fn func(key, value []byte) error) error

func SetNetworkInfo

func SetNetworkInfo(key string, info *rpc.NICMMessage) error

func SetupLevelDB

func SetupLevelDB(opt *LevelDBOptions) error

Types

type LevelDBOptions

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

func NewLevelDBOptions

func NewLevelDBOptions() *LevelDBOptions

func (*LevelDBOptions) AddFlags

func (opt *LevelDBOptions) AddFlags()

Jump to

Keyboard shortcuts

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