← Back to all blogsWhen building applications for live events, assuming stable internet connectivity is a guaranteed recipe for failure. During a major live convention in Manila, 15,000+ attendees completely saturated the local mobile cell towers and venue Wi-Fi routers within 30 minutes of doors opening.
### The Failure Mode of Standard Cloud APIs
Most client apps make direct POST requests to a cloud endpoint. When the network drops, they either show an error dialog, block the UI thread, or discard user submissions. In an interactive kiosk setup, an error dialog immediately breaks attendee trust.
### The Local SQLite Submission Queue
To solve this, we decoupled the user interaction lifecycle from the network sync lifecycle:
1. **Synchronous Local Write:** When an attendee taps "Submit", the payload is immediately written to an indexed, local SQLite database table with a `sync_status = 'pending'` flag.
2. **Immediate UI Feedback:** The user immediately sees their completion confirmation in under 16ms without waiting for a server handshake.
3. **Background Daemon Sync:** A resilient background service continuously monitors connectivity health using exponential backoff and synchronizes pending rows in FIFO batches once a stable uplink is detected.
```dart
// Queue submission locally before any network interaction
Future<void> submitSurvey(SurveyResponse response) async {
await localDb.into(localDb.surveys).insert(
SurveysCompanion.insert(
id: response.id,
payload: jsonEncode(response.data),
createdAt: DateTime.now(),
synced: const Value(false),
),
);
}
```
### Key Takeaway
Design event software under the constraint that the network is always down. Treat cloud synchronization as an asynchronous eventual consistency luxury rather than a synchronous blocker.
Offline-First Architecture for Unreliable Event Venues
Aug 18, 2026·4 min read·
#Architecture#Offline-First#SQLite#Flutter