Running into "land mines" with Android app and large files
We've run into two problems with Android, and were wondering if there's a place where things like this are documented?
Downloading small files via Titanium.Network.createHTTPClient works. When trying to download a large file (6mb) the download hangs and crashes at about 54%. Setting a timeout value with c.setTimeout(99999999) has no effect. It still crashes in the same spot.
Opening and using a very small Sqlite database works great. If we replace that database with a larger one (10mb+) the app just crashes when trying to access a recordset.
Is there some sort of file size problem with Android? What other limitations are there that we should be aware of?
1 Answer
-
It looks like the problem with downloading large files is that the entire file is being stored in memory before being written to disk. Thus, once the app runs out of memory, it crashes.
Is there any way to download directly to a disk file?