transistorsoft/nativescript-background-geolocation-lt

Where is the database stored?

Closed this issue · 1 comments

Your Environment

  • Plugin version: 1.9.0-beta.4
  • Platform: Android and iOS
  • OS version: 8.1
  • Device manufacturer / model: Essential PH1
  • Nativescript version (tns info): 4.2.0
  • Plugin config: default

Expected Behavior

N/A

Actual Behavior

N/A

Steps to Reproduce

N/A

Context

We need to know where the database is stored on the device.

Debug logs

N/A

For iOS, you can see the plugin's SQLite database in XCode Window->Devices screen by double-clicking your app to view the container (/Library/Application Support/TSLocationManager)

For Android, you can view the plugin's database via $ adb shell

$ adb shell
sailfish:/ $ run-as com.your.app ls -al

drwx------  11 u0_a967 u0_a967          4096 2018-08-03 18:15 .
drwxrwx--x 214 system  system           8192 2018-08-08 12:00 ..
drwxrwx--x   2 u0_a967 u0_a967          4096 2018-06-20 10:52 app_database
drwxrwx--x   2 u0_a967 u0_a967          4096 2018-06-20 10:52 app_textures
drwxrwx--x   5 u0_a967 u0_a967          4096 2018-06-20 11:06 app_webview
drwxrws--x   4 u0_a967 u0_a967_cache    4096 2018-07-24 10:07 cache
drwxrws--x   2 u0_a967 u0_a967_cache    4096 2018-06-20 11:06 code_cache
drwx------   2 u0_a967 u0_a967          4096 2018-06-20 10:52 databases
drwxrwx--x   2 u0_a967 u0_a967          4096 2018-06-20 10:52 files
-rwxrwxrwx   1 u0_a967 u0_a967       2845040 2018-06-26 15:28 libperfa_arm64.so
drwxrwx--x   2 u0_a967 u0_a967          4096 2018-08-03 18:15 no_backup
-rw-rw-rw-   1 u0_a967 u0_a967         29374 2018-06-26 15:28 perfa.jar
-rwxrwxrwx   1 u0_a967 u0_a967       2614320 2018-06-26 15:28 perfd
drwxrwx--x   2 u0_a967 u0_a967          4096 2018-07-31 16:18 shared_prefs

You will find the plugin's SQLite database in the /databases folder:

sailfish:/ $ run-as com.your.app ls -al databases
total 51424
drwx------  2 u0_a967 u0_a967     4096 2018-06-20 10:52 .
drwx------ 11 u0_a967 u0_a967     4096 2018-08-03 18:15 ..
-rw-rw----  1 u0_a967 u0_a967    28672 2018-08-01 13:08 transistor_location_manager
-rw-rw----  1 u0_a967 u0_a967        0 2018-08-01 13:08 transistor_location_manager-journal
-rw-------  1 u0_a967 u0_a967 52592640 2018-08-01 23:06 transistor_logback.db
-rw-------  1 u0_a967 u0_a967        0 2018-08-01 23:06 transistor_logback.db-journal