16 lines
447 B
Go
16 lines
447 B
Go
package context
|
|
|
|
import (
|
|
"eino-project/internal/conf"
|
|
|
|
"github.com/go-kratos/kratos/v2/log"
|
|
"github.com/google/wire"
|
|
)
|
|
|
|
// ProviderSet is context providers.
|
|
var ProviderSet = wire.NewSet(NewContextManagerFromBootstrapConfig)
|
|
|
|
// NewContextManagerFromBootstrapConfig 从 Bootstrap 配置创建上下文管理器
|
|
func NewContextManagerFromBootstrapConfig(c *conf.Bootstrap, logger log.Logger) ContextManager {
|
|
return NewContextManager(logger)
|
|
} |