Documentation ¶
Index ¶
- type UnlaunchClient
- func (c *UnlaunchClient) AwaitUntilReady(timeout time.Duration) error
- func (c *UnlaunchClient) Feature(featureKey string, identity string, attributes map[string]interface{}) *dtos.UnlaunchFeature
- func (c *UnlaunchClient) IsShutdown() bool
- func (c *UnlaunchClient) Shutdown()
- func (c *UnlaunchClient) Variation(featureKey string, identity string, attributes map[string]interface{}) string
- type UnlaunchClientConfig
- type UnlaunchFactory
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type UnlaunchClient ¶
type UnlaunchClient struct { FeatureStore service.FeatureStore // contains filtered or unexported fields }
UnlaunchClient is the main interface for interacting with Unlaunch
func (*UnlaunchClient) AwaitUntilReady ¶ added in v0.0.2
func (c *UnlaunchClient) AwaitUntilReady(timeout time.Duration) error
AwaitUntilReady blocks until the client initialization is done or timeout occurs, whichever comes first
func (*UnlaunchClient) Feature ¶
func (c *UnlaunchClient) Feature( featureKey string, identity string, attributes map[string]interface{}, ) *dtos.UnlaunchFeature
Feature ...
func (*UnlaunchClient) IsShutdown ¶
func (c *UnlaunchClient) IsShutdown() bool
func (*UnlaunchClient) Shutdown ¶
func (c *UnlaunchClient) Shutdown()
Shutdown shuts down the client, and all associated go routines
func (*UnlaunchClient) Variation ¶
func (c *UnlaunchClient) Variation( featureKey string, identity string, attributes map[string]interface{}, ) string
Variation evaluates and returns the variation (variation key) for this feature. Variations are defined using the Unlaunch console at https://app.unlaunch.io
type UnlaunchClientConfig ¶
type UnlaunchClientConfig struct { PollingInterval time.Duration MetricsFlushInterval time.Duration MetricsQueueSize int HTTPTimeout time.Duration Host string OfflineMode bool LoggerConfig *logger.LogOptions }
UnlaunchClientConfig contains configuration parameters to fine-tune the client
func DefaultConfig ¶
func DefaultConfig() *UnlaunchClientConfig
DefaultConfig for our users. Not used anywhere internally
type UnlaunchFactory ¶
type UnlaunchFactory struct {
// contains filtered or unexported fields
}
UnlaunchFactory ...
func NewUnlaunchClientFactory ¶
func NewUnlaunchClientFactory(SDKKey string, cfg *UnlaunchClientConfig) (*UnlaunchFactory, error)
NewUnlaunchClientFactory is a factory
Click to show internal directories.
Click to hide internal directories.