Documentation ¶
Overview ¶
Package context is the runtime context of GlusterD
Any package that needs access to the GlusterD runtime context just needs to import this package.
Index ¶
Constants ¶
const ( MaxOpVersion = 40000 APIVersion = 1 GlusterdVersion = "4.0-dev" )
Various version constants that will be used by GD2
Variables ¶
var ( MyUUID uuid.UUID Rest *rest.GDRest TxnFw *transaction.GDTxnFw OpVersion int )
Any object that is a part of the GlusterD context and needs to be available to other packages should be declared here as exported global variables
var (
Store *store.GDStore
)
If someone needs to use the GD2 store, all they need to do is just import context and use context.Store
Functions ¶
func Init ¶
func Init()
Init initializes the GlusterD context. This should be called once before doing anything else.
func RegisterStorePrefix ¶
func RegisterStorePrefix(prefix string)
RegisterStorePrefix allows other packages to register prefixes to be initalized on the store. The prefixes will be created on the store during GD2 context intialization
Types ¶
This section is empty.