-
Notifications
You must be signed in to change notification settings - Fork 1.3k
iOS, Android are not using the offline database #4362
Comments
It looks like the path, as well as the name, is different. |
I copied the Android SDK, which is doing the same thing: mbgl-cache.db, mbgl-offline.db. /cc @zugaldia |
On iOS, per #4371, the unified cache definitely shouldn’t go in the Caches directory, where the ambient cache currently resides. If we put it in the Documents directory, where the offline cache currently resides, a .db file will be listed in iTunes as a shareable document for every Mapbox-powered application, which is a poor user experience. As a compromise, we can put the unified cache in Application Support, but there are two caveats:
|
#4372 puts the OS X offline cache in a subfolder of Application Support, but neither caveat in #4362 (comment) applies to OS X. |
Per chat, on iOS, we’re going to place the offline cache in Application Support. If there’s an existing offline.db in Documents, we’ll move it; if there’s an existing caches.db in Caches, we’ll delete it. |
In Android after complete download of a region and switching off network connection the map is not using downloaded data - it shows nothing after move or zoom change. Moreover, if I switch network connection and then launch the app it is trying to load style data (and that is the style the region has been downloaded with) from Mapbox servers and it crashes with no exception but
It seems it is not using offline data at all. |
Fixed in the iOS and OS X SDKs in #4377. |
Android work is in #4383. |
…Manager, and change the name in JNI to match.
@NamtarR, the fix is now in the v3.2.0-beta.2 of the iOS SDK. Please let us know if you continue to see this issue. Thanks! |
Android fixed this in #4383 and the fix will be available in the next SNAPSHOT. |
iOS creates an offline database named "offline.db", but then uses the name "cache.db" for the actual map view. These need to be the same name, if not the same instance of
DefaultFileSource
.The text was updated successfully, but these errors were encountered: