modulepackage
0.0.0-20230303081844-6a5c134c44e7
Repository: https://github.com/hiank/think.git
Documentation: pkg.go.dev
# README
Think
Provide globally unique utilset
Fat
: file coder for load bytes and decode configTODO
: base context for all utilsNats
: nats connDBS
: KvDB set. contains [Mem]/[Disk] database client
NOTE: do not use this package in think's child package
Set
- 提供部分资源的单例实现,如数据库客户端、消息中间件客户端等
- 暴露
package one
中的单例实现 - 可
Close
,关闭后当前进程中Set
将不再可用(无法重新初始化)
NOTE: package one
设计上期望只在frame
内部访问,如果项目中希望访问其中的资源,使用对应的Set
暴露的api
# Packages
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
# Functions
Set utils set NOTE: it would panic without call 'Init' method to generate an unique object.
WithDB DB use for dial to database and cache in set cfg.Tag use for cache in set.
WithNatsUrl nats url NOTE: if url is "", natsconn will be nil.
WithTODO base Context the todo will cancel when Destroy.
# Constants
No description provided by the author
# Type aliases
No description provided by the author