Documentation ¶
Index ¶
- type AppBuilder
- type Application
- func (a *Application) ActorSystem() cfacade.IActorSystem
- func (a *Application) All() []cfacade.IComponent
- func (a *Application) Cluster() cfacade.ICluster
- func (a *Application) DieChan() chan bool
- func (a *Application) Discovery() cfacade.IDiscovery
- func (a *Application) Find(name string) cfacade.IComponent
- func (a *Application) IsFrontend() bool
- func (a *Application) NodeMode() NodeMode
- func (a *Application) OnShutdown(fn ...func())
- func (a *Application) Register(components ...cfacade.IComponent)
- func (a *Application) Remove(name string) cfacade.IComponent
- func (a *Application) Running() bool
- func (a *Application) Serializer() cfacade.ISerializer
- func (a *Application) SetCluster(cluster cfacade.ICluster)
- func (a *Application) SetDiscovery(discovery cfacade.IDiscovery)
- func (a *Application) SetNetParser(netParser cfacade.INetParser)
- func (a *Application) SetSerializer(serializer cfacade.ISerializer)
- func (a *Application) Shutdown()
- func (a *Application) StartTime() string
- func (a *Application) Startup()
- type NodeMode
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AppBuilder ¶ added in v1.3.0
type AppBuilder struct { *Application // contains filtered or unexported fields }
func Configure ¶ added in v1.1.5
func Configure(profileFilePath, nodeId string, isFrontend bool, mode NodeMode) *AppBuilder
func (*AppBuilder) AddActors ¶ added in v1.3.0
func (p *AppBuilder) AddActors(actors ...cfacade.IActorHandler)
func (*AppBuilder) NetParser ¶ added in v1.3.0
func (p *AppBuilder) NetParser() cfacade.INetParser
func (*AppBuilder) Register ¶ added in v1.3.0
func (p *AppBuilder) Register(component ...cfacade.IComponent)
func (*AppBuilder) SetNetParser ¶ added in v1.3.0
func (p *AppBuilder) SetNetParser(parser cfacade.INetParser)
func (*AppBuilder) Startup ¶ added in v1.3.0
func (p *AppBuilder) Startup()
type Application ¶
func NewApp ¶
func NewApp(profileFilePath, nodeId string, isFrontend bool, mode NodeMode) *Application
NewApp create new application instance
func (*Application) ActorSystem ¶ added in v1.3.0
func (a *Application) ActorSystem() cfacade.IActorSystem
func (*Application) All ¶
func (a *Application) All() []cfacade.IComponent
func (*Application) Cluster ¶ added in v1.3.0
func (a *Application) Cluster() cfacade.ICluster
func (*Application) DieChan ¶ added in v1.1.22
func (a *Application) DieChan() chan bool
func (*Application) Discovery ¶ added in v1.3.0
func (a *Application) Discovery() cfacade.IDiscovery
func (*Application) Find ¶
func (a *Application) Find(name string) cfacade.IComponent
func (*Application) IsFrontend ¶ added in v1.1.6
func (a *Application) IsFrontend() bool
func (*Application) NodeMode ¶ added in v1.1.6
func (a *Application) NodeMode() NodeMode
func (*Application) OnShutdown ¶ added in v1.1.0
func (a *Application) OnShutdown(fn ...func())
func (*Application) Register ¶ added in v1.1.5
func (a *Application) Register(components ...cfacade.IComponent)
func (*Application) Remove ¶
func (a *Application) Remove(name string) cfacade.IComponent
Remove component by name
func (*Application) Running ¶
func (a *Application) Running() bool
func (*Application) Serializer ¶ added in v1.3.0
func (a *Application) Serializer() cfacade.ISerializer
func (*Application) SetCluster ¶ added in v1.3.0
func (a *Application) SetCluster(cluster cfacade.ICluster)
func (*Application) SetDiscovery ¶ added in v1.3.0
func (a *Application) SetDiscovery(discovery cfacade.IDiscovery)
func (*Application) SetNetParser ¶ added in v1.3.1
func (a *Application) SetNetParser(netParser cfacade.INetParser)
func (*Application) SetSerializer ¶ added in v1.1.0
func (a *Application) SetSerializer(serializer cfacade.ISerializer)
func (*Application) Shutdown ¶
func (a *Application) Shutdown()
func (*Application) StartTime ¶ added in v1.1.0
func (a *Application) StartTime() string
func (*Application) Startup ¶
func (a *Application) Startup()
Startup load components before startup
Directories ¶
Path | Synopsis |
---|---|
components
|
|
cron
Module
|
|
data-config
Module
|
|
etcd
Module
|
|
gin
Module
|
|
gops
Module
|
|
gorm
Module
|
|
mongo
Module
|
|
examples
module
|
|
extend
|
|
base58
Package cherryBase58 file from https://github.com/akamensky/base58/blob/master/base58.go
|
Package cherryBase58 file from https://github.com/akamensky/base58/blob/master/base58.go |
map
Package cherryMap file from https://github.com/gogf/gf
|
Package cherryMap file from https://github.com/gogf/gf |
mapstructure
Package cherryMapStructure exposes functionality to convert one arbitrary Go type into another, typically to convert a map[string]interface{} into a native Go structure.
|
Package cherryMapStructure exposes functionality to convert one arbitrary Go type into another, typically to convert a map[string]interface{} into a native Go structure. |
queue
Package cherryQueue provides an efficient implementation of a multi-producer, single-consumer lock-free queue.
|
Package cherryQueue provides an efficient implementation of a multi-producer, single-consumer lock-free queue. |
regex
Package cherryRegex file from https://github.com/gogf/gf
|
Package cherryRegex file from https://github.com/gogf/gf |
slice
Package cherrySlice code from: https://github.com/beego/beego/blob/develop/core/utils/slice.go
|
Package cherrySlice code from: https://github.com/beego/beego/blob/develop/core/utils/slice.go |
snowflake
Package cherrySnowflake code from: https://github.com/bwmarrin/snowflake snowflake provides a very simple Twitter snowflake generator and parser.
|
Package cherrySnowflake code from: https://github.com/bwmarrin/snowflake snowflake provides a very simple Twitter snowflake generator and parser. |
sync
Package cherrySync cherrySync file from https://github.com/beego/beego/blob/develop/core/utils/safemap.go
|
Package cherrySync cherrySync file from https://github.com/beego/beego/blob/develop/core/utils/safemap.go |
time
Package cherryTime code from: https://github.com/golang-module/carbon
|
Package cherryTime code from: https://github.com/golang-module/carbon |
time_wheel
Package cherryTimeWheel file from https://github.com/RussellLuo/timingwheel
|
Package cherryTimeWheel file from https://github.com/RussellLuo/timingwheel |
utils
Package cherryUtils file from https://github.com/gogf/gf
|
Package cherryUtils file from https://github.com/gogf/gf |
rotatelogs
Package rotatelogs is a port of File-RotateLogs from Perl (https://metacpan.org/release/File-RotateLogs), and it allows you to automatically rotate output files when you write to them according to the filename pattern that you can specify.
|
Package rotatelogs is a port of File-RotateLogs from Perl (https://metacpan.org/release/File-RotateLogs), and it allows you to automatically rotate output files when you write to them according to the filename pattern that you can specify. |
net
|
|
Click to show internal directories.
Click to hide internal directories.