Versions in this module Expand all Collapse all v8 v8.0.0 Nov 10, 2025 Changes in this version + type MockEventStorage struct + CountCall func() int64 + DropCall func(size *int64) error + EmptyCall func() bool + PopNCall func(n int64) ([]dtos.EventDTO, error) + PopNRawCall func(size int64) ([]string, int64, error) + PopNWithMetadataCall func(n int64) ([]dtos.QueueStoredEventDTO, error) + PushCall func(event dtos.EventDTO, size int) error + func (m MockEventStorage) Count() int64 + func (m MockEventStorage) Drop(size *int64) error + func (m MockEventStorage) Empty() bool + func (m MockEventStorage) PopN(n int64) ([]dtos.EventDTO, error) + func (m MockEventStorage) PopNRaw(size int64) ([]string, int64, error) + func (m MockEventStorage) PopNWithMetadata(n int64) ([]dtos.QueueStoredEventDTO, error) + func (m MockEventStorage) Push(event dtos.EventDTO, size int) error + type MockFilter struct + AddCall func(data string) + ClearCall func() + ContainsCall func(data string) bool + func (m MockFilter) Add(data string) + func (m MockFilter) Clear() + func (m MockFilter) Contains(data string) bool + type MockImpressionStorage struct + CountCall func() int64 + DropCall func(size *int64) error + EmptyCall func() bool + LogImpressionsCall func(impressions []dtos.Impression) error + PopNCall func(n int64) ([]dtos.Impression, error) + PopNRawCall func(int64) ([]string, int64, error) + PopNWithMetadataCall func(n int64) ([]dtos.ImpressionQueueObject, error) + func (m MockImpressionStorage) Count() int64 + func (m MockImpressionStorage) Drop(size *int64) error + func (m MockImpressionStorage) Empty() bool + func (m MockImpressionStorage) LogImpressions(impressions []dtos.Impression) error + func (m MockImpressionStorage) PopN(n int64) ([]dtos.Impression, error) + func (m MockImpressionStorage) PopNRaw(n int64) ([]string, int64, error) + func (m MockImpressionStorage) PopNWithMetadata(n int64) ([]dtos.ImpressionQueueObject, error) + type MockImpressionsCountStorage struct + GetImpressionsCountCall func() (dtos.ImpressionsCountDTO, error) + RecordImpressionsCountCall func(impressions dtos.ImpressionsCountDTO) error + func (m MockImpressionsCountStorage) GetImpressionsCount() (dtos.ImpressionsCountDTO, error) + func (m MockImpressionsCountStorage) RecordImpressionsCount(impressions dtos.ImpressionsCountDTO) error + type MockLargeSegmentStorage struct + ChangeNumberCall func(name string) int64 + CountCall func() int + IsInLargeSegmentCall func(name string, key string) (bool, error) + LargeSegmentsForUserCall func(userKey string) []string + SetChangeNumberCall func(name string, till int64) + TotalKeysCall func(name string) int + UpdateCall func(name string, userKeys []string, till int64) + func (m MockLargeSegmentStorage) ChangeNumber(name string) int64 + func (m MockLargeSegmentStorage) Count() int + func (m MockLargeSegmentStorage) IsInLargeSegment(name string, key string) (bool, error) + func (m MockLargeSegmentStorage) LargeSegmentsForUser(userKey string) []string + func (m MockLargeSegmentStorage) SetChangeNumber(name string, till int64) + func (m MockLargeSegmentStorage) TotalKeys(name string) int + func (m MockLargeSegmentStorage) Update(name string, userKeys []string, till int64) + type MockRuleBasedSegmentStorage struct + func (m *MockRuleBasedSegmentStorage) All() []dtos.RuleBasedSegmentDTO + func (m *MockRuleBasedSegmentStorage) ChangeNumber() (int64, error) + func (m *MockRuleBasedSegmentStorage) Contains(ruleBasedSegmentNames []string) bool + func (m *MockRuleBasedSegmentStorage) Count() int + func (m *MockRuleBasedSegmentStorage) FetchMany(rbsNames []string) map[string]*dtos.RuleBasedSegmentDTO + func (m *MockRuleBasedSegmentStorage) GetRuleBasedSegmentByName(name string) (*dtos.RuleBasedSegmentDTO, error) + func (m *MockRuleBasedSegmentStorage) GetSegments() *set.ThreadUnsafeSet + func (m *MockRuleBasedSegmentStorage) LargeSegments() *set.ThreadUnsafeSet + func (m *MockRuleBasedSegmentStorage) ReplaceAll(toAdd []dtos.RuleBasedSegmentDTO, changeNumber int64) error + func (m *MockRuleBasedSegmentStorage) RuleBasedSegmentNames() ([]string, error) + func (m *MockRuleBasedSegmentStorage) Segments() *set.ThreadUnsafeSet + func (m *MockRuleBasedSegmentStorage) SetChangeNumber(till int64) error + func (m *MockRuleBasedSegmentStorage) Update(toAdd []dtos.RuleBasedSegmentDTO, toRemove []dtos.RuleBasedSegmentDTO, ...) error + type MockSegmentStorage struct + ChangeNumberCall func(segmentName string) (int64, error) + KeysCall func(segmentName string) *set.ThreadUnsafeSet + SegmentContainsKeyCall func(segmentName string, key string) (bool, error) + SegmentKeysCountCall func() int64 + SetChangeNumberCall func(segmentName string, till int64) error + UpdateCall func(name string, toAdd *set.ThreadUnsafeSet, toRemove *set.ThreadUnsafeSet, ...) error + func (m MockSegmentStorage) ChangeNumber(segmentName string) (int64, error) + func (m MockSegmentStorage) Keys(segmentName string) *set.ThreadUnsafeSet + func (m MockSegmentStorage) SegmentContainsKey(segmentName string, key string) (bool, error) + func (m MockSegmentStorage) SegmentKeysCount() int64 + func (m MockSegmentStorage) SetChangeNumber(segmentName string, till int64) error + func (m MockSegmentStorage) Update(name string, toAdd *set.ThreadUnsafeSet, toRemove *set.ThreadUnsafeSet, ...) error + type MockSplitStorage struct + AllCall func() []dtos.SplitDTO + ChangeNumberCall func() (int64, error) + FetchManyCall func(splitNames []string) map[string]*dtos.SplitDTO + GetAllFlagSetNamesCall func() []string + GetNamesByFlagSetsCall func(sets []string) map[string][]string + KillLocallyCall func(splitName string, defaultTreatment string, changeNumber int64) + LargeSegmentNamesCall func() *set.ThreadUnsafeSet + RemoveCall func(splitName string) + ReplaceAllCall func(toAdd []dtos.SplitDTO, changeNumber int64) error + RuleBasedSegmentNamesCall func() *set.ThreadUnsafeSet + SegmentNamesCall func() *set.ThreadUnsafeSet + SetChangeNumberCall func(changeNumber int64) error + SplitCall func(splitName string) *dtos.SplitDTO + SplitNamesCall func() []string + TrafficTypeExistsCall func(trafficType string) bool + UpdateCall func(toAdd []dtos.SplitDTO, toRemove []dtos.SplitDTO, changeNumber int64) + func (m MockSplitStorage) All() []dtos.SplitDTO + func (m MockSplitStorage) ChangeNumber() (int64, error) + func (m MockSplitStorage) FetchMany(splitNames []string) map[string]*dtos.SplitDTO + func (m MockSplitStorage) GetAllFlagSetNames() []string + func (m MockSplitStorage) GetNamesByFlagSets(sets []string) map[string][]string + func (m MockSplitStorage) KillLocally(splitName string, defaultTreatment string, changeNumber int64) + func (m MockSplitStorage) LargeSegmentNames() *set.ThreadUnsafeSet + func (m MockSplitStorage) Remove(splitname string) + func (m MockSplitStorage) ReplaceAll(toAdd []dtos.SplitDTO, changeNumber int64) error + func (m MockSplitStorage) RuleBasedSegmentNames() *set.ThreadUnsafeSet + func (m MockSplitStorage) SegmentNames() *set.ThreadUnsafeSet + func (m MockSplitStorage) SetChangeNumber(changeNumber int64) error + func (m MockSplitStorage) Split(splitName string) *dtos.SplitDTO + func (m MockSplitStorage) SplitNames() []string + func (m MockSplitStorage) TrafficTypeExists(trafficType string) bool + func (m MockSplitStorage) Update(toAdd []dtos.SplitDTO, toRemove []dtos.SplitDTO, changeNumber int64) + type MockTelemetryStorage struct + AddTagCall func(tag string) + GetBURTimeoutsCall func() int64 + GetEventsStatsCall func(dataType int) int64 + GetImpressionsStatsCall func(dataType int) int64 + GetLastSynchronizationCall func() dtos.LastSynchronization + GetNonReadyUsagesCall func() int64 + GetSessionLengthCall func() int64 + PopAuthRejectionsCall func() int64 + PopExceptionsCall func() dtos.MethodExceptions + PopHTTPErrorsCall func() dtos.HTTPErrors + PopHTTPLatenciesCall func() dtos.HTTPLatencies + PopLatenciesCall func() dtos.MethodLatencies + PopStreamingEventsCall func() []dtos.StreamingEvent + PopTagsCall func() []string + PopTokenRefreshesCall func() int64 + PopUpdatesFromSSECall func() dtos.UpdatesFromSSE + RecordAuthRejectionsCall func() + RecordBURTimeoutCall func() + RecordConfigDataCall func(configData dtos.Config) error + RecordEventsStatsCall func(dataType int, count int64) + RecordExceptionCall func(method string) + RecordImpressionsStatsCall func(dataType int, count int64) + RecordLatencyCall func(method string, latency time.Duration) + RecordNonReadyUsageCall func() + RecordSessionLengthCall func(session int64) + RecordStreamingEventCall func(streamingEvent *dtos.StreamingEvent) + RecordSuccessfulSyncCall func(resource int, when time.Time) + RecordSyncErrorCall func(resource int, status int) + RecordSyncLatencyCall func(resource int, latency time.Duration) + RecordTokenRefreshesCall func() + RecordUniqueKeysCall func(uniques dtos.Uniques) error + RecordUpdatesFromSSECall func(updateType int) + func (m MockTelemetryStorage) AddTag(tag string) + func (m MockTelemetryStorage) GetBURTimeouts() int64 + func (m MockTelemetryStorage) GetEventsStats(dataType int) int64 + func (m MockTelemetryStorage) GetImpressionsStats(dataType int) int64 + func (m MockTelemetryStorage) GetLastSynchronization() dtos.LastSynchronization + func (m MockTelemetryStorage) GetNonReadyUsages() int64 + func (m MockTelemetryStorage) GetSessionLength() int64 + func (m MockTelemetryStorage) PopAuthRejections() int64 + func (m MockTelemetryStorage) PopExceptions() dtos.MethodExceptions + func (m MockTelemetryStorage) PopHTTPErrors() dtos.HTTPErrors + func (m MockTelemetryStorage) PopHTTPLatencies() dtos.HTTPLatencies + func (m MockTelemetryStorage) PopLatencies() dtos.MethodLatencies + func (m MockTelemetryStorage) PopStreamingEvents() []dtos.StreamingEvent + func (m MockTelemetryStorage) PopTags() []string + func (m MockTelemetryStorage) PopTokenRefreshes() int64 + func (m MockTelemetryStorage) PopUpdatesFromSSE() dtos.UpdatesFromSSE + func (m MockTelemetryStorage) RecordAuthRejections() + func (m MockTelemetryStorage) RecordBURTimeout() + func (m MockTelemetryStorage) RecordConfigData(configData dtos.Config) error + func (m MockTelemetryStorage) RecordEventsStats(dataType int, count int64) + func (m MockTelemetryStorage) RecordException(method string) + func (m MockTelemetryStorage) RecordImpressionsStats(dataType int, count int64) + func (m MockTelemetryStorage) RecordLatency(method string, latency time.Duration) + func (m MockTelemetryStorage) RecordNonReadyUsage() + func (m MockTelemetryStorage) RecordSessionLength(session int64) + func (m MockTelemetryStorage) RecordStreamingEvent(streamingEvent *dtos.StreamingEvent) + func (m MockTelemetryStorage) RecordSuccessfulSync(resource int, time time.Time) + func (m MockTelemetryStorage) RecordSyncError(resource int, status int) + func (m MockTelemetryStorage) RecordSyncLatency(resource int, latency time.Duration) + func (m MockTelemetryStorage) RecordTokenRefreshes() + func (m MockTelemetryStorage) RecordUniqueKeys(uniques dtos.Uniques) error + func (m MockTelemetryStorage) RecordUpdatesFromSSE(updateType int) + type MockUniqueKeysStorage struct + CountCall func() int64 + PopNRawCall func(n int64) ([]string, int64, error) + func (m MockUniqueKeysStorage) Count() int64 + func (m MockUniqueKeysStorage) PopNRaw(n int64) ([]string, int64, error) + type SplitStorageMock struct + func (m *SplitStorageMock) All() []dtos.SplitDTO + func (m *SplitStorageMock) ChangeNumber() (int64, error) + func (m *SplitStorageMock) FetchMany(splitNames []string) map[string]*dtos.SplitDTO + func (m *SplitStorageMock) GetAllFlagSetNames() []string + func (m *SplitStorageMock) GetNamesByFlagSets(sets []string) map[string][]string + func (m *SplitStorageMock) KillLocally(splitName string, defaultTreatment string, changeNumber int64) + func (m *SplitStorageMock) LargeSegmentNames() *set.ThreadUnsafeSet + func (m *SplitStorageMock) Remove(splitname string) + func (m *SplitStorageMock) ReplaceAll(toAdd []dtos.SplitDTO, changeNumber int64) error + func (m *SplitStorageMock) RuleBasedSegmentNames() *set.ThreadUnsafeSet + func (m *SplitStorageMock) SegmentNames() *set.ThreadUnsafeSet + func (m *SplitStorageMock) SetChangeNumber(changeNumber int64) error + func (m *SplitStorageMock) Split(splitName string) *dtos.SplitDTO + func (m *SplitStorageMock) SplitNames() []string + func (m *SplitStorageMock) TrafficTypeExists(trafficType string) bool + func (m *SplitStorageMock) Update(toAdd []dtos.SplitDTO, toRemove []dtos.SplitDTO, changeNumber int64) Other modules containing this package github.com/splitio/go-split-commons/v2 github.com/splitio/go-split-commons/v3 github.com/splitio/go-split-commons/v4 github.com/splitio/go-split-commons/v5 github.com/splitio/go-split-commons/v6 github.com/splitio/go-split-commons/v7