Mendix offline applications on iPhones - Image Sync

0
Hi everyone,I'm looking for some guidance regarding a synchronization issue we're experiencing in a Mendix offline application.The application contains an offline form where users can capture information and attach photos while working without an internet connection. Depending on the configuration defined by the administrator, a form can contain anywhere from 1 image to potentially hundreds of images, based on the number of components being inspected.The process is as follows:The user completes the form offline.The user captures and attaches images offline.All data and images are stored locally on the device.Once connectivity is available, the user presses a Sync button that executes the standard Mendix Synchronize activity to send the data and images to the online database.The interesting part is that this process works correctly on:DesktopiPad Pro Third Generation with a M1 ProcessorHowever, on iPhone 16 pro and 17 pro (I don't have any other models to do the tests, so i have tested this functionality with both of these devices i do have), synchronization fails when images are included. If the form only contains normal data (text, numbers, selections, etc.), synchronization completes successfully. The issue seems to occur specifically when image uploads are involved.Some questions for the community:Has anyone experienced image synchronization issues on iPhone while the same application works correctly on iPad and Desktop?Could this be related to iPhone memory (RAM) limitations, or even the proccesor when synchronizing large numbers of images?Are there known differences in how Safari on iPhone handles image files, blobs, or temporary storage compared to Safari on iPad?Could it be related to how offline data and files are stored and processed in SQLite on iOS?Does SQLite behave differently on iPhone versus iPad in a way that could affect file synchronization?Could iPhone camera settings, image size, image metadata, or HEIC image format be contributing factors?Has anyone seen cases where a single image upload results in multiple sync attempts or repeated failed requests during synchronization?Are there known best practices or limitations for handling large volumes of images in Mendix offline applications on iPhones?What makes this especially confusing is that the functionality behaves as expected on Desktop and iPad, and only fails on iPhone devices. We're trying to determine whether this is an iPhone-specific limitation, a Safari/iOS behavior, or something related to the way image files are handled during synchronization.Any insights or similar experiences would be greatly appreciated.Thank you! 🙏
asked
1 answers
0

Hi Christian,

Since this only happens on iPhone and works on iPad M1 and Desktop, I don't think it's a SQLite limitation. This looks more like an iOS memory/payload limitation during offline synchronization, especially when high-resolution iPhone photos are uploaded.


A few things I'd recommend trying:

  • Reduce the image size/quality in the Take Picture widget. iPhone 16/17 Pro captures very large HEIC images, which can consume a lot of memory during sync.
  • Sync images in batches (for example, 10–20 at a time) instead of sending hundreds in a single Synchronize activity.
  • Check whether HEIC images are being converted to JPEG during upload, as that can increase memory usage.
  • Use Safari Web Inspector on the iPhone while syncing to capture the exact error (out-of-memory, repeated upload attempts, or network failure).
  • Test with 5, 20, and 50 images. If it consistently fails after a certain number, that strongly points to an iPhone memory/payload threshold rather than an offline database issue.


Could you also confirm:

  • Are you using the Take Picture widget or selecting images from the Photo Library?
  • Approximately what is the average image size (2–5 MB, 10 MB+, etc.)?
  • Does the sync fail completely, or do some images upload before it stops?


Kindly mark this as the accepted answer if it helps.

answered