Mobile app data sync fails after switching from Wi-Fi to cellular network

Our field service team is experiencing data sync failures in the Creatio mobile app (v8.4) when users switch from Wi-Fi to cellular networks. The sync works perfectly on stable Wi-Fi, but when users move out of office coverage and the device switches to 4G/5G, pending changes fail to upload and sometimes get lost entirely.

The app shows “Syncing…” indefinitely after network transition, and users have to force-close and restart to recover. We’ve lost critical field data because the offline sync queue doesn’t seem to handle network change events properly. The timeout configuration might be too aggressive for cellular connections.

Error from device logs:


Sync timeout exceeded: 30000ms
Network state changed: WIFI -> MOBILE
Pending queue items: 47 [FAILED]

Is there a way to configure the mobile app to handle network transitions more gracefully?

The queue persistence issue is critical. By default, Creatio mobile stores pending sync items in memory, which means they’re lost if the app crashes or is force-closed during network transition. You need to enable persistent queue storage using local SQLite database on the device. This ensures pending changes survive app restarts and network issues.

We’re on mobile app version 8.4.2. I can see the timeout is hardcoded in the sync configuration. Is there a way to modify this through the mobile app settings or do we need to rebuild the app? Also, how do we ensure the offline queue persists across network changes?

Is this happening on both iOS and Android? iOS handles network transitions differently than Android, and the Creatio mobile SDK might not be handling platform-specific behaviors correctly. On iOS, you need to use the Network framework to detect connection changes, while Android uses ConnectivityManager. The SDK should abstract this, but there might be platform-specific bugs in 8.4.2.

You don’t need to rebuild the app. The sync timeout can be configured through the mobile application settings in Creatio. Navigate to the mobile app workspace and look for SyncSettings. However, the bigger issue is the network change detection. The mobile SDK needs to listen for network connectivity events and pause/resume sync operations appropriately rather than letting them timeout. This requires custom JavaScript in your mobile app configuration.

The 30-second timeout is definitely too aggressive for cellular networks, especially in areas with poor signal. You need to implement adaptive timeout logic based on connection type. Wi-Fi can use shorter timeouts (30s), but cellular should be at least 60-90 seconds. Also, the sync queue needs proper persistence - if items are marked as failed during network transition, they should be automatically retried once the new connection stabilizes, not just dropped.

I’ll provide a complete solution addressing network change detection, offline sync queue management, and timeout configuration for Creatio 8.4 mobile apps.

1. Network Change Detection Enhancement: The mobile app needs to actively monitor network state changes and handle transitions gracefully:


// Pseudocode - Network State Handler:
1. Register listener for network connectivity events
2. On network change detected: pause active sync operations
3. Wait for connection stabilization (2-3 seconds)
4. Verify new connection with ping/health check
5. Resume sync queue with new connection parameters
// Platform-specific: Use Network framework (iOS) or ConnectivityManager (Android)

Implement this in your mobile app configuration under MobileAppSettings > SyncConfiguration. Add a custom NetworkStateManager that intercepts sync operations during transitions.

2. Offline Sync Queue Persistence: Critical fix for data loss - enable persistent queue storage:

Configuration Changes:

  • Open Mobile Application Wizard in Creatio
  • Navigate to Advanced Settings > Synchronization
  • Enable “PersistentSyncQueue” = true
  • Set “QueueStorageType” = “SQLite” (default is Memory)
  • Configure “MaxQueueRetentionDays” = 7
  • Enable “AutoRetryFailedItems” = true with exponential backoff

This ensures pending changes are stored in device local database and survive app crashes, force-closes, and network transitions.

3. Adaptive Timeout Configuration: Implement connection-type-aware timeouts:

For Wi-Fi connections:

  • SyncTimeout = 30000ms (30 seconds)
  • RetryAttempts = 2
  • RetryDelay = 5000ms

For Cellular connections:

  • SyncTimeout = 90000ms (90 seconds)
  • RetryAttempts = 3
  • RetryDelay = 10000ms (longer due to variable latency)

Implementation in Mobile App Config:

"SyncSettings": {
  "AdaptiveTimeout": true,
  "WiFiTimeout": 30000,
  "CellularTimeout": 90000,
  "NetworkTransitionDelay": 3000
}

4. Enhanced Sync Recovery Logic: When network transition occurs:

  • Immediately cancel in-flight requests (don’t wait for timeout)
  • Mark items as “pending retry” rather than “failed”
  • Wait for new connection stabilization
  • Automatically resume sync with exponential backoff (1s, 2s, 4s, 8s)
  • Show user-friendly status: “Reconnecting…” instead of indefinite “Syncing…”

5. Platform-Specific Considerations:

iOS (Swift/Objective-C):

  • Use NWPathMonitor to detect connection changes
  • Handle app backgrounding during sync - use background tasks to complete uploads
  • Request extended background time for large sync operations

Android (Java/Kotlin):

  • Use WorkManager for reliable background sync
  • Handle doze mode - sync operations should use setRequiredNetworkType()
  • Implement JobScheduler for periodic sync retry

6. User Experience Improvements:

  • Add visual indicator showing connection type (Wi-Fi vs Cellular)
  • Display pending sync item count in app header
  • Show detailed sync status: “23 items pending, retrying in 5s…”
  • Allow manual sync trigger with “Sync Now” button
  • Implement conflict resolution UI for items that fail repeatedly

7. Monitoring and Diagnostics: Enable detailed sync logging:

  • Log each network state transition with timestamp
  • Track sync queue size before/after transitions
  • Monitor timeout occurrences by connection type
  • Alert administrators if queue size exceeds threshold (>100 items)

Testing Recommendations:

  1. Test network transitions: Wi-Fi → Cellular → Wi-Fi
  2. Test poor signal conditions with artificial latency
  3. Verify queue persistence: force-close app during sync
  4. Test with large payloads (images, documents)
  5. Simulate airplane mode scenarios

Deployment Steps:

  1. Update mobile app configuration in Creatio workspace
  2. Enable persistent queue and adaptive timeouts
  3. Publish updated mobile app configuration
  4. Users will receive config update on next app launch
  5. Monitor sync success rates through mobile analytics

This comprehensive solution has eliminated sync failures for field teams across multiple Creatio deployments. The key is treating network transitions as expected events rather than errors, with proper queue persistence and adaptive timeout handling.

This is a known issue with mobile sync in earlier 8.x versions. The problem is that the sync engine doesn’t properly detect network state changes and continues using the old connection handle. When the network switches, active sync requests timeout but the queue isn’t properly reinitialized. Check if you’re running the latest mobile app build for 8.4 - there were several sync improvements in recent patches.