Documentation ¶
Index ¶
- Variables
- func GenerateRandomPort() string
- func NewCompressor(err error) compressor.Compressor
- func NewDatadogConfig() *opentracing.Config
- func NewGRPCClient(ctx context.Context, lc fx.Lifecycle, gcfg *tgrpc.Config, logger *zap.Logger, ...) *grpc.ClientConn
- func NewGRPCConfig() *grpc.Config
- func NewGRPCServer(lc fx.Lifecycle, logger *zap.Logger, cfg *opentracing.Config, verifyAuth bool, ...) (*grpc.Server, *tgrpc.Config)
- func NewHTTPClient(lc fx.Lifecycle, logger *zap.Logger, cfg *opentracing.Config) *http.Client
- func NewHTTPClientWithRoundTripper(lc fx.Lifecycle, logger *zap.Logger, cfg *opentracing.Config, ...) *http.Client
- func NewHTTPConfig() *http.Config
- func NewHTTPServer(lc fx.Lifecycle, logger *zap.Logger, cfg *opentracing.Config) (*shttp.Server, string)
- func NewJaegerConfig() *opentracing.Config
- func NewLogger(lc fx.Lifecycle) *zap.Logger
- func NewMarshaller(err error) marshaller.Marshaller
- func NewNSQConfig() *nsq.Config
- func NewPGConfig() *pg.Config
- func NewRedisCache(lc fx.Lifecycle, host string, logger *zap.Logger, ...) *cache.Cache
- func NewRistrettoCache(lc fx.Lifecycle) *ristretto.Cache
- type Generator
- type Handler
- type Migrator
- type Server
- type Shutdowner
- type Verifier
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrInvalidToken = errors.New("invalid token")
ErrInvalidToken ...
View Source
var Version = version.Version("1.0.0")
Version for test.
Functions ¶
func GenerateRandomPort ¶ added in v1.26.0
func GenerateRandomPort() string
GenerateRandomPort for test.
func NewCompressor ¶ added in v1.57.3
func NewCompressor(err error) compressor.Compressor
NewCompressor for test.
func NewDatadogConfig ¶ added in v1.59.0
func NewDatadogConfig() *opentracing.Config
NewDatadogConfig for test.
func NewGRPCClient ¶ added in v1.65.5
func NewGRPCClient( ctx context.Context, lc fx.Lifecycle, gcfg *tgrpc.Config, logger *zap.Logger, cfg *opentracing.Config, cred credentials.PerRPCCredentials, ) *grpc.ClientConn
NewGRPCClient for test.
func NewGRPCServer ¶ added in v1.65.5
func NewGRPCServer( lc fx.Lifecycle, logger *zap.Logger, cfg *opentracing.Config, verifyAuth bool, unary []grpc.UnaryServerInterceptor, stream []grpc.StreamServerInterceptor, ) (*grpc.Server, *tgrpc.Config)
NewGRPCServer for test.
func NewHTTPClient ¶ added in v1.30.0
NewHTTPClient for test.
func NewHTTPClientWithRoundTripper ¶ added in v1.30.0
func NewHTTPClientWithRoundTripper(lc fx.Lifecycle, logger *zap.Logger, cfg *opentracing.Config, roundTripper http.RoundTripper) *http.Client
NewHTTPClientWithRoundTripper for test.
func NewHTTPServer ¶ added in v1.65.5
func NewHTTPServer(lc fx.Lifecycle, logger *zap.Logger, cfg *opentracing.Config) (*shttp.Server, string)
NewHTTPServer for test.
func NewJaegerConfig ¶ added in v1.52.0
func NewJaegerConfig() *opentracing.Config
NewJaegerConfig for test.
func NewMarshaller ¶ added in v1.57.3
func NewMarshaller(err error) marshaller.Marshaller
NewMarshaller for test.
func NewRedisCache ¶ added in v1.65.4
func NewRedisCache(lc fx.Lifecycle, host string, logger *zap.Logger, compressor compressor.Compressor, marshaller marshaller.Marshaller) *cache.Cache
NewRedisCache for test.
Types ¶
type Generator ¶ added in v1.32.3
type Generator struct {
// contains filtered or unexported fields
}
Generator for test.
func NewGenerator ¶ added in v1.4.0
NewGenerator for test.
type Handler ¶ added in v1.14.0
type Handler struct {
// contains filtered or unexported fields
}
Handler for test.
type Migrator ¶ added in v1.66.4
type Migrator struct {
// contains filtered or unexported fields
}
Migrator for test.
type Server ¶
type Server struct { v1.UnimplementedGreeterServiceServer // contains filtered or unexported fields }
Server ...
func (*Server) SayHello ¶
func (s *Server) SayHello(ctx context.Context, req *v1.SayHelloRequest) (*v1.SayHelloResponse, error)
SayHello ...
func (*Server) SayStreamHello ¶
func (s *Server) SayStreamHello(stream v1.GreeterService_SayStreamHelloServer) error
SayStreamHello ...
type Shutdowner ¶
type Shutdowner struct {
// contains filtered or unexported fields
}
func NewShutdowner ¶
func NewShutdowner() *Shutdowner
func (*Shutdowner) Called ¶ added in v1.66.4
func (s *Shutdowner) Called() bool
func (*Shutdowner) Shutdown ¶
func (s *Shutdowner) Shutdown(...fx.ShutdownOption) error
Source Files ¶
Click to show internal directories.
Click to hide internal directories.