vendredi 21 août 2015

How can I write BLOBs in android FAST?

I have an app that downloads many images that are about 50k to 100k in size. The full database can be anywhere from 50MB to 500MB.

We are currently using sqlite, but it has slow inserts. We did a test writing files and that was slow as well. It seems to be taking about 300 to 800ms per image to write - which comes out to about 250kb/sec (slower than the network speed). I did a benchmark with A1 benchmark and it says my write speed is 14MB/sec, so i'm not sure why my app is so slow?

Here are the primary requirements: 1) Fast writes 2) Fast reads/lookups via an custom integer key (this can be converted a file path for individual files) 3) Prevents user from easily accessing the images (if we save as images they can connect the external storage to their computer and browser, but we can write the files in reverse byte order)

hopefully we can still use the sqllite solution, as i like one file, but either way it seems like a storage issue?

Aucun commentaire:

Enregistrer un commentaire