Versions in this module Expand all Collapse all v1 v1.0.0 Nov 13, 2023 Changes in this version + func BeDaemon(arg string) + func Bootstrap(serviceInfo *ServiceInfo) (*conf.Bootstrap, log.Logger, registry.Registrar) + func CreateGrpcClient(ctx context.Context, r registry.Discovery, serviceName string, ...) grpc.ClientConnInterface + func CreateGrpcServer(cfg *conf.Bootstrap, m ...middleware.Middleware) *kratosGrpc.Server + func CreateRestServer(cfg *conf.Bootstrap, m ...middleware.Middleware) *kratosRest.Server + func LoadBootstrapConfig(configPath string) error + func LoadRemoteConfigSourceConfigs(configPath string) (error, *conf.RemoteConfig) + func NewAliyunLogger(cfg *conf.Logger) log.Logger + func NewApolloConfigSource(c *conf.RemoteConfig) config.Source + func NewConfigProvider(configPath string) config.Config + func NewConsulConfigSource(c *conf.RemoteConfig) config.Source + func NewConsulRegistry(c *conf.Registry) *consulKratos.Registry + func NewDiscovery(cfg *conf.Registry) registry.Discovery + func NewEtcdConfigSource(c *conf.RemoteConfig) config.Source + func NewEtcdRegistry(c *conf.Registry) *etcdKratos.Registry + func NewEurekaRegistry(c *conf.Registry) *eurekaKratos.Registry + func NewFileConfigSource(filePath string) config.Source + func NewFluentLogger(cfg *conf.Logger) log.Logger + func NewKubernetesConfigSource(c *conf.RemoteConfig) config.Source + func NewKubernetesRegistry(_ *conf.Registry) *k8sRegistry.Registry + func NewLogger(cfg *conf.Logger) log.Logger + func NewLoggerProvider(cfg *conf.Logger, serviceInfo *ServiceInfo) log.Logger + func NewLogrusLogger(cfg *conf.Logger) log.Logger + func NewMinIoClient(conf *conf.OSS) *minio.Client + func NewNacosConfigSource(c *conf.RemoteConfig) config.Source + func NewNacosRegistry(c *conf.Registry) *nacosKratos.Registry + func NewOtlpGrpcExporter(ctx context.Context, endpoint string, insecure bool, ...) (traceSdk.SpanExporter, error) + func NewOtlpHttpExporter(ctx context.Context, endpoint string, insecure bool, ...) (traceSdk.SpanExporter, error) + func NewPolarisConfigSource(_ *conf.RemoteConfig) config.Source + func NewRedisClient(conf *conf.Data) *redis.Client + func NewRegistry(cfg *conf.Registry) registry.Registrar + func NewRemoteConfigSource(c *conf.RemoteConfig) config.Source + func NewServicecombRegistry(c *conf.Registry) *servicecombKratos.Registry + func NewStdLogger() log.Logger + func NewTencentLogger(cfg *conf.Logger) log.Logger + func NewTracerExporter(exporterName, endpoint string, insecure bool) (traceSdk.SpanExporter, error) + func NewTracerProvider(cfg *conf.Tracer, serviceInfo *ServiceInfo) error + func NewZapLogger(cfg *conf.Logger) log.Logger + func NewZipkinExporter(_ context.Context, endpoint string) (traceSdk.SpanExporter, error) + func NewZooKeeperRegistry(c *conf.Registry) *zookeeperKratos.Registry + func RegisterConfig(c interface{}) + type CommandFlags struct + Conf string + ConfigHost string + ConfigType string + Daemon bool + Env string + func NewCommandFlags() *CommandFlags + func (f *CommandFlags) Init() + type ConfigType string + const ConfigTypeApollo + const ConfigTypeConsul + const ConfigTypeEtcd + const ConfigTypeKubernetes + const ConfigTypeLocalFile + const ConfigTypeNacos + const ConfigTypePolaris + type LoggerType string + const LoggerTypeAliyun + const LoggerTypeFluent + const LoggerTypeLogrus + const LoggerTypeStd + const LoggerTypeTencent + const LoggerTypeZap + type RegistryType string + const LoggerTypeEtcd + const LoggerTypeEureka + const LoggerTypeKubernetes + const LoggerTypeNacos + const LoggerTypePolaris + const LoggerTypeServicecomb + const LoggerTypeZooKeeper + const RegistryTypeConsul + type ServiceInfo struct + Id string + Metadata map[string]string + Name string + Version string + func NewServiceInfo(name, version, id string) *ServiceInfo + func (s *ServiceInfo) GetInstanceId() string + func (s *ServiceInfo) SetMataData(k, v string)