package
0.1.0
Repository: https://github.com/emc-cmd/libstorage.git
Documentation: pkg.go.dev

# Functions

Background returns a new context with logging capabilities.
Client returns the context's Client.
CustomHeaderKeys returns a channel on which can be received all the registered, custom header keys.
CustomLoggerKeys returns a channel on which can be received all the registered, custom logger keys.
Driver returns the context's storage driver.
GetLogLevel gets the context's log level.
InstanceID returns the context's InstanceID.
Join joins this context with another, such that value lookups will first first check the current context, and if no such value exist, a lookup will be performed against the right side.
LocalDevices returns the context's local devices map.
MustClient returns the context's Client and panics if the client is not available and/or not castable..
MustInstanceID returns the context's InstanceID and panics if it does not exist and/or cannot be type cast.
MustService returns the context's StorageService and panics if it does not exist and/or cannot be type cast.
MustTransaction returns the context's Transaction and will panic if the value is missing or not castable.
Profile returns the context's profile.
RegisterCustomKey registers a custom key with the context package.
RequireTX ensures a context has a transaction, and if it doesn't creates a new one.
Route returns the context's route.
Server returns the context's server name.
Service returns the context's storage service.
ServiceName returns the context's service name.
SetLogLevel sets the context's log level.
Transaction returns the context's Transaction.
Value returns the value associated with this context for key, or nil if no value is associated with key.
WithRequestRoute returns a new context with the injected *http.Request and Route.
WithStorageService returns a new context with the StorageService as the value and attempts to assign the service's associated InstanceID and LocalDevices (by way of the service's StorageDriver) to the context as well.
WithValue returns a copy of parent in which the value associated with key is val.

# Constants

AllInstanceIDsKey is the key for the map[string]*types.InstanceID value that maps all drivers to their instance IDs.
AllLocalDevicesKey is the key for the map[string]*types.LocalDevices value that maps all drivers to their instance IDs.
ClientKey is a context key.
CustomHeaderKey indicates a value set for this key should be sent along with HTTP requests as an HTTP header.
CustomLoggerKey indicates a value set for this key should be logged as a member of a log entry's fields collection when using the context's structured logger.
DriverKey is an alias for StorageDriver.
HostKey is a context key.
HTTPRequestKey is a context key.
InstanceIDKey is a context key.
LocalDevicesKey is a context key.
LoggerKey is a context key.
ProfileKey is a context key.
RouteKey is a context key.
ServerKey is a context key.
ServiceKey is an alias for StorageService.
StorageServiceKey is a context key.
TaskKey is a context key.
TLSKey is a context key.
TransactionKey is a context key.
UserKey is a context key.

# Type aliases

CustomKeyTypes is a bitmask used when registering a custom key with the context at runtime.
Key is the type used as a context key.