def

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Dec 5, 2024 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Overview

Package def @Title title @Description desc @Author pc 2024/11/5 @Update pc 2024/11/5

Package def @Title 常量定义 @Description desc @Author yr 2024/11/6 @Update yr 2024/11/6

Package def @Title title @Description desc @Author yr 2024/11/14 @Update yr 2024/11/14

Index

Constants

View Source
const (
	DefaultRpcConnNum           = 1
	DefaultRpcLenMsgLen         = 4
	DefaultRpcMinMsgLen         = 2
	DefaultMaxCheckCallRpcCount = 1000
	DefaultMaxPendingWriteNum   = 1000000

	DefaultConnectInterval             = 2 * time.Second
	DefaultCheckRpcCallTimeoutInterval = 1 * time.Second
	DefaultRpcTimeout                  = time.Second
)
View Source
const (
	ServiceStatusNormal int32 = iota
	ServiceStatusRetired
)
View Source
const (
	DefaultTimerSize          = 1024 // 默认定时器数量
	DefaultMailBoxSize        = 1024 // 默认事件队列数量
	DefaultGoroutineNum int32 = 1    // 默认协程数量
)
View Source
const (
	SvcStatusUnknown  int32 = iota // 未运行
	SvcStatusInit                  // 初始化
	SvcStatusStarting              // 启动中
	SvcStatusRunning               // 运行中
	SvcStatusClosing               // 关闭中
	SvcStatusClosed                // 关闭
	SvcStatusRetire                // 退休
)
View Source
const (
	DefaultRpcTypeLocal = "local"
	DefaultRpcTypeRpcx  = "rpcx"
)
View Source
const (
	DefaultPVPath           = "./cache"
	DefaultPVCPath          = "./data"
	DefaultLogPath          = "logs"
	DefaultAntsPoolSize     = 10000
	DefaultProfilerInterval = 10 * time.Second
)
View Source
const (
	DiscoveryConfUseLocal  = "local"
	DiscoveryConfUseRemote = "remote"
)
View Source
const (
	DefaultDiscoveryUse = "etcd"
)
View Source
const (
	DefaultModuleIdSeed = 1_000_000 // 默认的moduleId开始序号
)
View Source
const (
	DefaultServiceUse = "local"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type SelectType

type SelectType int // 选择类型 0随机 1哈希 2轮询 3加权轮询 4最少连接 5权重随机

Jump to

Keyboard shortcuts

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