500 euro offered for extremely urgent help with in-app downloading issue

djouce

Member
Licensed User
Longtime User
I urgently require help with a downloading issue on an otherwise finished app. On first install, the app must download a 250MB file from our website (I don't want to use Google expansion files for reasons I won't go into here). The problem is that it's unreliable. Sometimes the download times out before it's finished, and the app tries to run but then crashes of course. I have tried splitting the file into multiple files which are then patched together after downloading, which has helped a lot but it is still unreliable (I could also use Http ranges, but this just happened to be easier for me).

The weaker the wifi signal, the more likely it is to happen. Using phone KeepAlive and PartialLock hasn't solved it either.

I have used both the Google download service library and Httputils2 (which is currently implemented). As I am facing an extremely urgent deadline, I simply don't have any more time to spend on the issue, I have too much else to do, plus it's driving me crazy.

This is a job for someone who is very familiar with downloading from within an app. Quite possibly (in fact hopefully) you already have a library that will do the job reliably (and I must emphasise that word), in which case this would be easy money. There are a couple of other minor issues I could also do with some assistance, but that is separate to this request.

Please do not respond to this unless you know you can do it. I can't afford to waste time, which is why I am offering this sum. I know it's not a big problem and I'm most likely doing something incredibly stupid, but that's to your advantage :)

You can either reply in this thread or pm me if you need any more details.

I'm based in Dublin so someone on GMT would be preferable, but not essential. The important thing is this needs to be done very very fast. If you can solve it and take this problem off my plate, I will be most grateful, and you will definitely be considered for further work, as there is more to come.

Thanks.

Edit: Just to clarify re the timeout, this relates to the app itself, not the network. Increasing the HttpRequest.Timeout value has no effect on the reliability of the download.
 
Last edited:

barx

Well-Known Member
Licensed User
Longtime User
Maybe more reliable to download using ftp...
 

djouce

Member
Licensed User
Longtime User
Thanks for the suggestion, but I don't have time to experiment with ftp. There's no guarantee it will solve the issue, as the files seem to be downloading ok. The problem appears to be that the longer they take to download, the more likely the app is to crash, but even that isn't an absolute. Believe me, I've spent far more time trying to resolve this than on anything else and it has got the better of me. It's the one and only issue I can't seem to get beyond and now I'm out of time, hence this offer. Given the time, I've no doubt I would eventually work it out but time is a luxury I can't afford right now.

I'm quite sure I'm just overlooking something. This can't be that hard. A fresh pair of eyes could well spot my mistake very quickly.
 

djouce

Member
Licensed User
Longtime User
Thanks Peter but I already tried that, in fact it didn't matter how long I set to, even 3+ hours, it made no difference. I know what the problem is now, it's definitely due to the signal dropping on poor connections and/or inferior tablets (the app is an educational one and was designed to work on the cheapest tablet for affordability, but I would have approached it differently if I had realised just how bad some tablets can be). I'm pretty sure I know what the solution is but I'm out of time. I've had an offer of help so I'm hoping that works, otherwise I'll have to emigrate and change my identity lol.
 

keirS

Well-Known Member
Licensed User
Longtime User
I have this problem with 3g and WiFi connections. What I do is monitor the signal strength and the number of bytes received per second from a download. I also run a ping against the server at the same time. If the signal strength is below a given threshold (-70 dbm for WiFi) or bytes per second drops below a certain threshold or the ping goes above a packet loss threshold then I cancel the download and retry it when all tests are back within the thresholds.
 

sorex

Expert
Licensed User
Longtime User
Can you tell what that data is? text, images, mix of these?

If text why not zip it up, download it and extract to the device. it could be 5% of the size if it's just a database dump.

If images do an optimized resize serversize and download that, you could gain megabytes there aswell.
 

djouce

Member
Licensed User
Longtime User
Thanks, the files are already zipped. Most of the data is images, and they have to be 32-bit png, so it's kind of hard to optimize. Anyway, we're now looking at delivering the files in stages, as only a small percentage are initially required. That combined with previous suggestions should solve the problem, apart from the issue of having the time to complete the code.

This has been an object lesson for me in not relying on emulators when developing apps, the results can be deceptive. I should have tested more frequently on real devices. If I had, I wouldn't be in this situation. Hindsight is such a wonderful gift.
 

sorex

Expert
Licensed User
Longtime User
another way is fetch on demand and then store locally for faster access next time.

Who says they will even see 90+% of those images?

you could waste people's time for nothing if they uninstall it right after the download ;)
 

djouce

Member
Licensed User
Longtime User
Fetch on demand is a great idea, although it requires the tablet to be connected to the internet all the time. But yeah, I'm very much leaning towards a partial just-in-time approach. By the time kids will have reached any significant level of unlocks, all the required files should be already there. It's worth a shot.
 
Top