Documentation ¶
Index ¶
- Constants
- type Handler
- type Registry
- type RegistryDefault
- func (r *RegistryDefault) Config(ctx context.Context) *config.Config
- func (r *RegistryDefault) Contextualizer() ketoctx.Contextualizer
- func (r *RegistryDefault) DetermineNetwork(ctx context.Context) (*networkx.Network, error)
- func (r *RegistryDefault) ExpandEngine() *expand.Engine
- func (r *RegistryDefault) GetVersion(_ context.Context, _ *acl.GetVersionRequest) (*acl.GetVersionResponse, error)
- func (r *RegistryDefault) HealthHandler() *healthx.Handler
- func (r *RegistryDefault) HealthServer() *health.Server
- func (r *RegistryDefault) Init(ctx context.Context) (err error)
- func (r *RegistryDefault) InitWithoutNetworkID(ctx context.Context) error
- func (r *RegistryDefault) Logger() *logrusx.Logger
- func (r *RegistryDefault) MetricsHandler() *prometheus.Handler
- func (r *RegistryDefault) MigrateDown(ctx context.Context) error
- func (r *RegistryDefault) MigrateUp(ctx context.Context) error
- func (r *RegistryDefault) MigrationBox(ctx context.Context) (*popx.MigrationBox, error)
- func (r *RegistryDefault) PermissionEngine() *check.Engine
- func (r *RegistryDefault) Persister() persistence.Persister
- func (r *RegistryDefault) PopConnection(ctx context.Context) (*pop.Connection, error)
- func (r *RegistryDefault) PopConnectionWithOpts(ctx context.Context, popOpts ...func(*pop.ConnectionDetails)) (*pop.Connection, error)
- func (r *RegistryDefault) PrometheusManager() *prometheus.MetricsManager
- func (r *RegistryDefault) ReadGRPCServer(ctx context.Context) *grpc.Server
- func (r *RegistryDefault) ReadRouter(ctx context.Context) http.Handler
- func (r *RegistryDefault) RelationTupleManager() relationtuple.Manager
- func (r *RegistryDefault) ServeAll(ctx context.Context) error
- func (r *RegistryDefault) ServeAllSQA(cmd *cobra.Command) error
- func (r *RegistryDefault) Tracer(ctx context.Context) *tracing.Tracer
- func (r *RegistryDefault) WriteGRPCServer(ctx context.Context) *grpc.Server
- func (r *RegistryDefault) WriteRouter(ctx context.Context) http.Handler
- func (r *RegistryDefault) Writer() herodot.Writer
Constants ¶
View Source
const ( LogrusHookContextKey contextKeys = "logrus hook" RegistryContextKey contextKeys = "registry" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Handler ¶
type Handler interface { RegisterReadRoutes(r *x.ReadRouter) RegisterWriteRoutes(r *x.WriteRouter) RegisterReadGRPC(s *grpc.Server) RegisterWriteGRPC(s *grpc.Server) }
type Registry ¶
type Registry interface { Init(context.Context) error config.Provider x.LoggerProvider x.WriterProvider relationtuple.ManagerProvider expand.EngineProvider check.EngineProvider persistence.Migrator persistence.Provider PopConnection(ctx context.Context) (*pop.Connection, error) PopConnectionWithOpts(ctx context.Context, f ...func(*pop.ConnectionDetails)) (*pop.Connection, error) HealthHandler() *healthx.Handler Tracer(ctx context.Context) *tracing.Tracer MetricsHandler() *prometheus.Handler PrometheusManager() *prometheus.MetricsManager ReadRouter(ctx context.Context) http.Handler WriteRouter(ctx context.Context) http.Handler ReadGRPCServer(ctx context.Context) *grpc.Server WriteGRPCServer(ctx context.Context) *grpc.Server ServeAll(ctx context.Context) error ServeAllSQA(cmd *cobra.Command) error }
type RegistryDefault ¶
type RegistryDefault struct {
// contains filtered or unexported fields
}
func NewSqliteTestRegistry ¶
func NewSqliteTestRegistry(t *testing.T, debugOnDisk bool) *RegistryDefault
func NewTestRegistry ¶
func NewTestRegistry(t *testing.T, dsn *dbx.DsnT) *RegistryDefault
func (*RegistryDefault) Config ¶
func (r *RegistryDefault) Config(ctx context.Context) *config.Config
func (*RegistryDefault) Contextualizer ¶
func (r *RegistryDefault) Contextualizer() ketoctx.Contextualizer
func (*RegistryDefault) DetermineNetwork ¶
func (*RegistryDefault) ExpandEngine ¶
func (r *RegistryDefault) ExpandEngine() *expand.Engine
func (*RegistryDefault) GetVersion ¶
func (r *RegistryDefault) GetVersion(_ context.Context, _ *acl.GetVersionRequest) (*acl.GetVersionResponse, error)
func (*RegistryDefault) HealthHandler ¶
func (r *RegistryDefault) HealthHandler() *healthx.Handler
func (*RegistryDefault) HealthServer ¶
func (r *RegistryDefault) HealthServer() *health.Server
func (*RegistryDefault) InitWithoutNetworkID ¶
func (r *RegistryDefault) InitWithoutNetworkID(ctx context.Context) error
func (*RegistryDefault) Logger ¶
func (r *RegistryDefault) Logger() *logrusx.Logger
func (*RegistryDefault) MetricsHandler ¶
func (r *RegistryDefault) MetricsHandler() *prometheus.Handler
func (*RegistryDefault) MigrateDown ¶
func (r *RegistryDefault) MigrateDown(ctx context.Context) error
func (*RegistryDefault) MigrationBox ¶
func (r *RegistryDefault) MigrationBox(ctx context.Context) (*popx.MigrationBox, error)
func (*RegistryDefault) PermissionEngine ¶
func (r *RegistryDefault) PermissionEngine() *check.Engine
func (*RegistryDefault) Persister ¶
func (r *RegistryDefault) Persister() persistence.Persister
func (*RegistryDefault) PopConnection ¶
func (r *RegistryDefault) PopConnection(ctx context.Context) (*pop.Connection, error)
PopConnection returns the standard connection that is kept for the whole time.
func (*RegistryDefault) PopConnectionWithOpts ¶
func (r *RegistryDefault) PopConnectionWithOpts(ctx context.Context, popOpts ...func(*pop.ConnectionDetails)) (*pop.Connection, error)
func (*RegistryDefault) PrometheusManager ¶
func (r *RegistryDefault) PrometheusManager() *prometheus.MetricsManager
func (*RegistryDefault) ReadGRPCServer ¶
func (r *RegistryDefault) ReadGRPCServer(ctx context.Context) *grpc.Server
func (*RegistryDefault) ReadRouter ¶
func (r *RegistryDefault) ReadRouter(ctx context.Context) http.Handler
func (*RegistryDefault) RelationTupleManager ¶
func (r *RegistryDefault) RelationTupleManager() relationtuple.Manager
func (*RegistryDefault) ServeAllSQA ¶
func (r *RegistryDefault) ServeAllSQA(cmd *cobra.Command) error
func (*RegistryDefault) Tracer ¶
func (r *RegistryDefault) Tracer(ctx context.Context) *tracing.Tracer
func (*RegistryDefault) WriteGRPCServer ¶
func (r *RegistryDefault) WriteGRPCServer(ctx context.Context) *grpc.Server
func (*RegistryDefault) WriteRouter ¶
func (r *RegistryDefault) WriteRouter(ctx context.Context) http.Handler
func (*RegistryDefault) Writer ¶
func (r *RegistryDefault) Writer() herodot.Writer
Source Files ¶
Click to show internal directories.
Click to hide internal directories.