We recently upgraded the map file in our offline app to support an extra zoom level, but now the app can't find the resource in the raw folder.
The previous map was around 550MB.
The new one is 1.2GB.
The app crashes at this line now:
InputStream is = getResources().openRawResource(R.raw.fire_map);
With this line in the logcat:java.lang.RuntimeException: Unable to start activity ComponentInfo{org.ir.mobilemap/org.ir.mobilemap.IRMobileMapActivity}: android.content.res.Resources$NotFoundException: File res/raw/fire_map.mbtiles from drawable resource ID #0x7f060003
I tested it multiple times and I can't find the problem, reverting to the old map works perfectly fine. Is there any restriction I am not aware of, or is the problem somewhere else?
You're probably hitting the ceiling for maximum file size within an APK. You may be able to compile and package it, but reading it may not work.
A few solutions: