Documentation
¶
Overview ¶
Package api implements the API server.
Index ¶
- type APIServer
- type APIServerConfig
- type APIServerOption
- func WithContext(ctx context.Context) APIServerOption
- func WithGRPCListener(listener net.Listener) APIServerOption
- func WithHTTPListener(listener net.Listener) APIServerOption
- func WithHTTPRegistrationFunc(fn HTTPRegistrationFunc) APIServerOption
- func WithLogger(log *zap.Logger) APIServerOption
- func WithPrometheusRegistry(reg *prometheus.Registry) APIServerOption
- func WithReflection(enabled bool) APIServerOption
- func WithRegistrationFunc(fn RegistrationFunc) APIServerOption
- func WithStreamInterceptors(interceptors ...grpc.StreamServerInterceptor) APIServerOption
- func WithUnaryInterceptors(interceptors ...grpc.UnaryServerInterceptor) APIServerOption
- type HTTPRegistrationFunc
- type RegistrationFunc
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APIServer ¶ added in v0.5.1
type APIServer struct {
// contains filtered or unexported fields
}
func NewAPIServer ¶
func NewAPIServer(opts ...APIServerOption) (*APIServer, error)
type APIServerConfig ¶ added in v0.5.1
type APIServerConfig struct {
Ctx context.Context
Log *zap.Logger
GRPCListener net.Listener
HTTPListener net.Listener
EnableReflection bool
RegistrationFunc RegistrationFunc
HTTPRegistrationFunc HTTPRegistrationFunc
PromRegistry *prometheus.Registry
UnaryInterceptors []grpc.UnaryServerInterceptor
StreamInterceptors []grpc.StreamServerInterceptor
}
type APIServerOption ¶ added in v0.5.1
type APIServerOption func(*APIServerConfig)
func WithContext ¶ added in v0.4.0
func WithContext(ctx context.Context) APIServerOption
func WithGRPCListener ¶ added in v0.5.0
func WithGRPCListener(listener net.Listener) APIServerOption
func WithHTTPListener ¶ added in v0.5.0
func WithHTTPListener(listener net.Listener) APIServerOption
func WithHTTPRegistrationFunc ¶ added in v0.4.0
func WithHTTPRegistrationFunc(fn HTTPRegistrationFunc) APIServerOption
func WithLogger ¶ added in v0.4.0
func WithLogger(log *zap.Logger) APIServerOption
func WithPrometheusRegistry ¶ added in v0.4.0
func WithPrometheusRegistry(reg *prometheus.Registry) APIServerOption
func WithReflection ¶ added in v0.4.0
func WithReflection(enabled bool) APIServerOption
func WithRegistrationFunc ¶ added in v0.4.0
func WithRegistrationFunc(fn RegistrationFunc) APIServerOption
func WithStreamInterceptors ¶ added in v0.5.0
func WithStreamInterceptors(interceptors ...grpc.StreamServerInterceptor) APIServerOption
func WithUnaryInterceptors ¶ added in v0.5.0
func WithUnaryInterceptors(interceptors ...grpc.UnaryServerInterceptor) APIServerOption
type HTTPRegistrationFunc ¶ added in v0.5.1
type HTTPRegistrationFunc func(gwmux *runtime.ServeMux, conn *grpc.ClientConn) error
type RegistrationFunc ¶ added in v0.1.1
Directories
¶
| Path | Synopsis |
|---|---|
|
Package message implements the replication API service.
|
Package message implements the replication API service. |
|
Package metadata implements the metadata API service.
|
Package metadata implements the metadata API service. |
|
Package payer implements the Payer API service.
|
Package payer implements the Payer API service. |
Click to show internal directories.
Click to hide internal directories.