Documentation
¶
Index ¶
- type ClusterClient
- func (cc *ClusterClient) Close()
- func (cc *ClusterClient) ConnectionConfig(index int64) (*config.StorageServerConfig, error)
- func (cc *ClusterClient) MetaConnectionConfig() (*config.StorageServerConfig, error)
- func (cc *ClusterClient) RootConnectionConfig(index int64) (*config.StorageServerConfig, error)
- type ClusterClientConfig
- type ClusterClientFactory
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ClusterClient ¶
type ClusterClient struct {
// contains filtered or unexported fields
}
ClusterClient contains the cluster configuration, which gets reloaded based on incoming SIGHUP signals.
func NewClusterClient ¶
func NewClusterClient(cfg ClusterClientConfig, logger log.Logger) (*ClusterClient, error)
NewClusterClient creates a new cluster client
func (*ClusterClient) Close ¶
func (cc *ClusterClient) Close()
Close the open listen goroutine, which autoreloads the internal configuration, upon receiving a SIGHUP signal.
func (*ClusterClient) ConnectionConfig ¶
func (cc *ClusterClient) ConnectionConfig(index int64) (*config.StorageServerConfig, error)
ConnectionConfig returns a connection config, based on a given index, which will be morphed into a local index, based on the available (local) storage servers available.
func (*ClusterClient) MetaConnectionConfig ¶
func (cc *ClusterClient) MetaConnectionConfig() (*config.StorageServerConfig, error)
MetaConnectionConfig returns the connection config, used to connect to the meta storage server.
func (*ClusterClient) RootConnectionConfig ¶
func (cc *ClusterClient) RootConnectionConfig(index int64) (*config.StorageServerConfig, error)
RootConnectionConfig returns the root connection config, if available
type ClusterClientConfig ¶
ClusterClientConfig contains all configurable parameters used when creating a ClusterClient
type ClusterClientFactory ¶
type ClusterClientFactory struct {
// contains filtered or unexported fields
}
ClusterClientFactory allows for the creation of ClusterClients.
func NewClusterClientFactory ¶
func NewClusterClientFactory(configPath string, logger log.Logger) (*ClusterClientFactory, error)
NewClusterClientFactory creates a ClusterClientFactory.
func (*ClusterClientFactory) Listen ¶
func (f *ClusterClientFactory) Listen(ctx context.Context)
Listen to incoming creation requests (send by the NewClient method)
func (*ClusterClientFactory) NewClient ¶
func (f *ClusterClientFactory) NewClient(vdiskID string) (cc *ClusterClient, err error)
NewClient returns a new ClusterClient.