Documentation ¶
Overview ¶
Package gateway implements an HTTP server that forwards JSON requests to an upstream SpiceDB gRPC server.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type CloserHandler ¶ added in v1.16.0
type CloserHandler struct {
// contains filtered or unexported fields
}
CloserHandler is a http.Handler and a io.Closer. Meant to keep track of resources to closer for a handler.
func NewHandler ¶ added in v1.2.0
func NewHandler(ctx context.Context, upstreamAddr, upstreamTLSCertPath string) (*CloserHandler, error)
NewHandler creates an REST gateway HTTP CloserHandler with the provided upstream configuration.
func (CloserHandler) Close ¶ added in v1.16.0
func (cdh CloserHandler) Close() error
func (CloserHandler) ServeHTTP ¶ added in v1.16.0
func (cdh CloserHandler) ServeHTTP(writer http.ResponseWriter, request *http.Request)
type HandlerRegisterer ¶ added in v1.16.0
type HandlerRegisterer func(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
HandlerRegisterer is a function that registers a Gateway Handler in a ServeMux
Click to show internal directories.
Click to hide internal directories.