Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterDriver ¶
RegisterDriver registers a driver for a database type. It is intended to be called from a package init() so drivers self-register. Panics on duplicate registration — init() code is expected to catch this early.
Types ¶
type Driver ¶
Driver opens a database connection, constructs its metadata store, and returns the resources needed to serve requests.
type DriverResources ¶
type DriverResources struct {
Meta metaStore
Factory ProviderFactory
Closer io.Closer
}
DriverResources holds the resources opened by a Driver. The caller is responsible for calling Closer.Close when done.
type ProviderFactory ¶
ProviderFactory creates a ledgerpb.Provider for a given store name (a table or collection).
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server wraps a gRPC server and its listener.
func (*Server) HTTPAddr ¶ added in v0.0.11
HTTPAddr returns the HTTP gateway address, or empty string if disabled.
func (*Server) ReloadHooks ¶ added in v0.0.10
ReloadHooks cancels the current hook set, waits for them to stop, then starts a new set from cfg.Hooks. The gRPC listener and backend connection are not affected. No-ops if Stop has already been called.