database

package
v2.0.2-rc.24 Latest Latest
Warning

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

Go to latest
Published: Mar 15, 2022 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Default number of cdn load limit
	DefaultCDNLoadLimit = 300

	// Default number of client load limit
	DefaultClientLoadLimit = 50

	// Default number of pieces to download in parallel
	DefaultClientParallelCount = 4
)

Variables

This section is empty.

Functions

func NewRedis

func NewRedis(cfg *config.RedisConfig) (*redis.Client, error)

Types

type Database

type Database struct {
	DB  *gorm.DB
	RDB *redis.Client
}

func New

func New(cfg *config.Config) (*Database, error)

Jump to

Keyboard shortcuts

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