conf

package
v0.0.0-...-7e1aa58 Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2020 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Init

func Init() (err error)

Init init config.

Types

type Comet

type Comet struct {
	RoutineChan int
	RoutineSize int
}

Comet is comet config.

type Config

type Config struct {
	Env       *Env
	Kafka     *Kafka
	Discovery *naming.Config
	Comet     *Comet
	Room      *Room
}

Config is job config.

var (

	// Conf config
	Conf *Config
)

func Default

func Default() *Config

Default new a config with specified defualt value.

type Env

type Env struct {
	Region    string
	Zone      string
	DeployEnv string
	Host      string
}

Env is env config.

type Kafka

type Kafka struct {
	Topic   string
	Group   string
	Brokers []string
}

Kafka is kafka config.

type Room

type Room struct {
	Batch  int
	Signal xtime.Duration
	Idle   xtime.Duration
}

Room is room config.

Jump to

Keyboard shortcuts

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