Documentation
¶
Index ¶
- type MemoryStore
- func (m *MemoryStore) Close() error
- func (m *MemoryStore) Delete(ctx context.Context, key string) error
- func (m *MemoryStore) Get(ctx context.Context, key string) (*core.FeatureFlag, error)
- func (m *MemoryStore) GetAll(ctx context.Context) ([]core.FeatureFlag, error)
- func (m *MemoryStore) HealthCheck(ctx context.Context) error
- func (m *MemoryStore) Set(ctx context.Context, flag core.FeatureFlag) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MemoryStore ¶
type MemoryStore struct {
// contains filtered or unexported fields
}
MemoryStore implements the Store interface using in-memory storage It provides thread-safe operations using sync.RWMutex
func (*MemoryStore) Delete ¶
func (m *MemoryStore) Delete(ctx context.Context, key string) error
Delete removes a feature flag
func (*MemoryStore) Get ¶
func (m *MemoryStore) Get(ctx context.Context, key string) (*core.FeatureFlag, error)
Get retrieves a feature flag by key
func (*MemoryStore) GetAll ¶
func (m *MemoryStore) GetAll(ctx context.Context) ([]core.FeatureFlag, error)
GetAll retrieves all feature flags
func (*MemoryStore) HealthCheck ¶
func (m *MemoryStore) HealthCheck(ctx context.Context) error
HealthCheck verifies store connectivity (always healthy for memory store)
func (*MemoryStore) Set ¶
func (m *MemoryStore) Set(ctx context.Context, flag core.FeatureFlag) error
Set creates or updates a feature flag
Click to show internal directories.
Click to hide internal directories.