-
Notifications
You must be signed in to change notification settings - Fork 61
PersistenceStrategy
interface PersistenceStrategy
The main strategy used to persist data between the moment it's tracked and created, and the moment it's uploaded to the intake.
abstract fun currentMetadata(): ByteArray?
the metadata of the current writeable batch
abstract fun dropAll()
Drop all data.
abstract fun lockAndReadNext(): PersistenceStrategy.Batch?
Reads the next batch of data and lock it so that it can't be read or written to by anyone.
abstract fun migrateData(targetStrategy: PersistenceStrategy)
Migrate the data to a different PersistenceStrategy. All readable and ongoing batches must be transferred to the given strategy.
abstract fun unlockAndDelete(batchId: String)
Marks the batch as unlocked and to be deleted. The corresponding batch should not be returned in any call to lockAndReadNext.
abstract fun unlockAndKeep(batchId: String)
Marks the batch as unlocked and to be kept to be read again later.
abstract fun write(event: RawBatchEvent, batchMetadata: ByteArray?, eventType: EventType): Boolean
Writes the content of the event to the current available batch.
true if event was written, false otherwise.
event | the event to write (content + metadata) |
batchMetadata | the optional updated batch metadata |
eventType | additional information about the event that can impact the way it is stored. Note: events with the CRASH type are being sent as part of the Crash Reporting feature, and implies that the process will exit soon, meaning that those event must be kept synchronously and in a way to be retrieved after the app restarts in a new process (e.g.: on the file system, or in a local database). |
- Datadog
- DatadogSite
- _InternalProxy
- InternalLogger
- SdkCore
- DatadogContext
- DeviceInfo
- DeviceType
- NetworkInfo
- ProcessInfo
- TimeInfo
- UserInfo
- Feature
- FeatureContextUpdateReceiver
- FeatureEventReceiver
- FeatureScope
- FeatureSdkCore
- StorageBackedFeature
- Request
- RequestFactory
- DataWriter
- EventBatchWriter
- EventType
- FeatureStorageConfiguration
- RawBatchEvent
- DataStoreHandler
- DataStoreReadCallback
- DataStoreWriteCallback
- InternalSdkCore
- SdkReference
- BackPressureMitigation
- BackPressureStrategy
- BatchProcessingLevel
- BatchSize
- Configuration
- HostsSanitizer
- UploadFrequency
- UploadSchedulerStrategy
- DataConstraints
- DatadogDataConstraints
- ThreadDump
- DefaultFirstPartyHostHeaderTypeResolver
- FirstPartyHostHeaderTypeResolver
- Deserializer
- BuildSdkVersionProvider
- JsonSerializer
- MethodCallSamplingRate
- PerformanceMetric
- TelemetryMetricType
- PersistenceStrategy
- Serializer
- DataStoreContent
- RateBasedSampler
- Sampler
- FlushableExecutorService
- EventMapper
- MapperSerializer
- NoOpEventMapper
- LogAttributes
- TrackingConsent
- TrackingConsentProviderCallback
- Encryption
- TracingHeaderType
- DdRumContentProvider
- GlobalRumMonitor
- Rum
- RumActionType
- RumAttributes
- RumConfiguration
- RumErrorSource
- RumMonitor
- RumPerformanceMetric
- RumResourceAttributesProvider
- RumResourceKind
- RumResourceMethod
- RumSessionListener
- _RumInternalProxy
- VitalsUpdateFrequency
- ViewEventMapper
- ResourceTiming
- AdvancedNetworkRumMonitor
- ResourceId
- RumResourceInputStream
- AcceptAllActivities
- AcceptAllDefaultFragment
- AcceptAllNavDestinations
- AcceptAllSupportFragments
- ActivityLifecycleTrackingStrategy
- ActivityViewTrackingStrategy
- ComponentPredicate
- FragmentViewTrackingStrategy
- InteractionPredicate
- MixedViewTrackingStrategy
- NavigationViewTrackingStrategy
- TrackingStrategy
- ViewAttributesProvider
- ViewTrackingStrategy
- DatadogDatabaseErrorHandler
- ActionEvent
- ErrorEvent
- LongTaskEvent
- ResourceEvent
- ViewEvent
- TelemetryConfigurationEvent
- TelemetryDebugEvent
- TelemetryErrorEvent
- ExtensionSupport
- ImagePrivacy
- MapperTypeWrapper
- SessionReplay
- SessionReplayConfiguration
- SessionReplayPrivacy
- MappingContext
- OptionSelectorDetector
- SystemInformation
- BaseAsyncBackgroundWireframeMapper
- BaseViewGroupMapper
- BaseWireframeMapper
- EditTextMapper
- TextViewMapper
- TraverseAllChildrenMapper
- WireframeMapper
- AndroidMDrawableToColorMapper
- AndroidQDrawableToColorMapper
- AsyncJobStatusCallback
- ColorStringFormatter
- DefaultColorStringFormatter
- DefaultViewBoundsResolver
- DefaultViewIdentifierResolver
- DrawableToColorMapper
- GlobalBounds
- ImageWireframeHelper
- LegacyDrawableToColorMapper
- ViewBoundsResolver
- ViewIdentifierResolver
- MobileSegment
- ResourceHashesEntry
- ResourceMetadata