Documentation
¶
Index ¶
- func LoadValues() (values *common.Values, err error)
- func NewAPI() (*api.API, error)
- func UseDatabase(client *mongo.Client, values *common.Values) (db *mongo.Database)
- func UseHertz(values *common.Values) (h *server.Hertz, err error)
- func UseJetStream(nc *nats.Conn) (nats.JetStreamContext, error)
- func UseMongoDB(values *common.Values) (*mongo.Client, error)
- func UseNats(values *common.Values) (nc *nats.Conn, err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func LoadValues ¶ added in v0.2.0
LoadValues 加载配置
func UseDatabase ¶
UseDatabase 初始化数据库 配置文档 https://www.mongodb.com/docs/drivers/go/current/ https://pkg.go.dev/go.mongodb.org/mongo-driver/mongo
func UseHertz ¶ added in v0.2.0
UseHertz 使用 Hertz 配置文档 https://www.cloudwego.io/zh/docs/hertz/reference/config
func UseJetStream ¶ added in v0.3.0
func UseJetStream(nc *nats.Conn) (nats.JetStreamContext, error)
UseJetStream https://docs.nats.io/using-nats/developer/develop_jetstream
func UseMongoDB ¶
UseMongoDB 初始化 MongoDB 配置文档 https://www.mongodb.com/docs/drivers/go/current/ https://pkg.go.dev/go.mongodb.org/mongo-driver/mongo
func UseNats ¶ added in v0.3.0
UseNats https://docs.nats.io/using-nats/developer https://github.com/nats-io/nats.go
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.