Offline & Batching
Learn how AppAmbit handles offline scenarios and batches data for efficient transmission.
Automatic Offline Support
If the device is offline, the SDK will store sessions, events, logs, and crashes locally. Once internet connectivity is restored, the SDK will automatically send the stored sessions, events, logs, and crashes in batches.
How It Works
The AppAmbit SDK provides automatic offline support across all platforms:
- Local Storage: When the device is offline, all data (sessions, events, logs, crashes) is persisted locally
- Automatic Detection: The SDK monitors network connectivity automatically
- Batch Transmission: Once connectivity is restored, all queued data is sent to AppAmbit servers in batches
- No Code Required: This behavior is built-in and requires no additional configuration
Benefits
- Data Integrity: No data is lost when the device goes offline
- Efficient Network Usage: Batching reduces the number of network requests
- Automatic Recovery: The SDK handles all retry logic automatically
- Cross-Platform: Works consistently across all supported platforms
Platform Notes
This functionality works identically across all platforms:
- .NET MAUI: Automatic offline support for iOS, Android, Windows, and macOS
- iOS: Leverages iOS local storage for data persistence
- Android: Uses Android local storage mechanisms
- Flutter: Cross-platform offline support through native bridges
- React Native: Unified offline behavior across iOS and Android
Info
The SDK automatically manages storage cleanup and size limits to prevent excessive local storage usage.