Closed cairin closed 6 years ago
I reinstalled the app. Ran a function that updated the config with setConfig
, started the tracking service and restarted the app. Does calling setConfig
re-initialize all the configurations or does it just update the ones specified?
Here's the setConfig
function call:
let self = this
if (this.hashId !== '') {
this.bgGeo.setConfig({
extras: {hashId: self.hashId}
}, function () {
console.log('setConfig success')
}, function () {
console.warn('Failed to setConfig')
})
}
Here's the logs of this run:
T NULL, cos_latitude DOUBLE NOT NULL, longitude DOUBLE NOT NULL, sin_longitude DOUBLE NOT NULL, cos_longitude DOUBLE NOT NULL, radius DOUBLE NOT NULL, notifyOnEntry BOOLEAN NOT NULL DEFAULT 0, notifyOnExit BOOLEAN NOT NULL DEFAULT 0, notifyOnDwell BOOLEAN NOT NULL DEFAULT 0, loiteringDelay INTEGER NOT NULL DEFAULT 0, extras TEXT);
11-03 10:28:20.968 1881 2064 D TSLocationManager: [c.t.l.d.s.SQLiteLocationDAO dbh]
11-03 10:28:20.968 1881 2064 D TSLocationManager: ✅ Opened database
11-03 10:28:20.994 1881 2064 D TSLocationManager: [c.t.l.d.s.SQLiteLocationDAO prune]
11-03 10:28:20.994 1881 2064 D TSLocationManager: ℹ️ PRUNE -1 days
11-03 10:28:21.068 1881 2064 D TSLocationManager: [c.t.l.data.sqlite.GeofenceDAO dbh]
11-03 10:28:21.068 1881 2064 D TSLocationManager: ✅ Opened database
11-03 10:28:21.090 1881 2064 I TSLocationManager: [c.t.l.a.BackgroundGeolocation <init>]
11-03 10:28:21.090 1881 2064 I TSLocationManager: 🔵 Connecting to GooglePlayServices...
11-03 10:28:21.109 1881 2064 D TSLocationManager: $ addLocationListener()
11-03 10:28:21.113 1881 2064 D TSLocationManager: $ addMotionChangeListener()
11-03 10:28:21.115 1881 2064 D TSLocationManager: $ addActivityChangeListener()
11-03 10:28:21.118 1881 2064 D TSLocationManager: $ addProviderChangeListener()
11-03 10:28:21.124 1881 1881 I TSLocationManager: [c.t.l.a.BackgroundGeolocation onConnected]
11-03 10:28:21.124 1881 1881 I TSLocationManager: ✅ Google Play Services: connected (version code:11400000)
11-03 10:28:21.127 1881 2064 D TSLocationManager: $ addGeofenceListener()
11-03 10:28:21.130 1881 2064 D TSLocationManager: $ addGeofencesChangeListener()
11-03 10:28:21.132 1881 2064 D TSLocationManager: $ addHttpListener()
11-03 10:28:21.134 1881 2064 D TSLocationManager: $ addHeartbeatListener()
11-03 10:28:21.137 1881 2064 D TSLocationManager: $ addScheduleListener()
11-03 10:28:21.139 1881 2064 D TSLocationManager: $ addPowerSaveChangeListener()
11-03 10:28:21.149 1881 2064 D TSLocationManager: $ configure()
11-03 10:28:21.161 1881 1881 I TSLocationManager: - onPause
11-03 10:28:25.502 1881 2154 I TSLocationManager: [c.t.l.settings.Settings print]
11-03 10:28:25.502 1881 2154 I TSLocationManager: ╔═════════════════════════════════════════════
11-03 10:28:25.502 1881 2154 I TSLocationManager: ║ BackgroundGeolocation Settings
11-03 10:28:25.502 1881 2154 I TSLocationManager: ╠═════════════════════════════════════════════
11-03 10:28:25.502 1881 2154 I TSLocationManager: {
11-03 10:28:25.502 1881 2154 I TSLocationManager: "isMoving": false,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "enabled": false,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "odometer": 0,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "schedulerEnabled": false,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "trackingMode": "location",
11-03 10:28:25.502 1881 2154 I TSLocationManager: "distanceFilter": 10,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "desiredAccuracy": 0,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "desiredOdometerAccuracy": 100,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "locationUpdateInterval": 1000,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "fastestLocationUpdateInterval": 10000,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "locationTimeout": 60,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "deferTime": 0,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "disableElasticity": false,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "elasticityMultiplier": 1,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "activityRecognitionInterval": 10000,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "minimumActivityRecognitionConfidence": 75,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "triggerActivities": "in_vehicle, on_bicycle, on_foot, running, walking",
11-03 10:28:25.502 1881 2154 I TSLocationManager: "disableStopDetection": false,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "stationaryRadius": 25,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "stopTimeout": 5,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "stopOnStationary": false,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "url": "https:\/\/requestb.in\/1j0s82t1",
11-03 10:28:25.502 1881 2154 I TSLocationManager: "method": "POST",
11-03 10:28:25.502 1881 2154 I TSLocationManager: "autoSync": true,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "autoSyncThreshold": 0,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "batchSync": false,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "maxBatchSize": -1,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "params": {},
11-03 10:28:25.502 1881 2154 I TSLocationManager: "headers": {},
11-03 10:28:25.502 1881 2154 I TSLocationManager: "extras": {},
11-03 10:28:25.502 1881 2154 I TSLocationManager: "httpRootProperty": "location",
11-03 10:28:25.502 1881 2154 I TSLocationManager: "locationTemplate": "",
11-03 10:28:25.502 1881 2154 I TSLocationManager: "geofenceTemplate": "",
11-03 10:28:25.502 1881 2154 I TSLocationManager: "persist": true,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "maxDaysToPersist": 1,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "maxRecordsToPersist": -1,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "locationsOrderDirection": "ASC",
11-03 10:28:25.502 1881 2154 I TSLocationManager: "httpTimeout": 60000,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "geofenceProximityRadius": 1000,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "geofenceInitialTriggerEntry": true,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "stopOnTerminate": false,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "startOnBoot": false,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "heartbeatInterval": 60,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "foregroundService": false,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "notificationPriority": 0,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "notificationTitle": "Sportraxs Tracking",
11-03 10:28:25.502 1881 2154 I TSLocationManager: "notificationText": "Location services are working.",
11-03 10:28:25.502 1881 2154 I TSLocationManager: "notificationColor": "",
11-03 10:28:25.502 1881 2154 I TSLocationManager: "notificationIcon": "",
11-03 10:28:25.502 1881 2154 I TSLocationManager: "notificationSmallIcon": "INSERT ICON HERE",
11-03 10:28:25.502 1881 2154 I TSLocationManager: "notificationLargeIcon": "undefined",
11-03 10:28:25.502 1881 2154 I TSLocationManager: "forceReloadOnLocationChange": false,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "forceReloadOnMotionChange": false,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "forceReloadOnGeofence": false,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "forceReloadOnBoot": false,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "forceReloadOnHeartbeat": false,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "forceReloadOnSchedule": false,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "stopAfterElapsedMinutes": 0,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "schedule": [],
11-03 10:28:25.502 1881 2154 I TSLocationManager: "configureUrl": "",
11-03 10:28:25.502 1881 2154 I TSLocationManager: "configureInterval": -1,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "debug": false,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "logLevel": 5,
11-03 10:28:25.502 1881 2154 I TSLocationManager: "logMaxDays": 3
11-03 10:28:25.502 1881 2154 I TSLocationManager: }╚═════════════════════════════════════════════
11-03 10:28:25.507 1881 1881 I TSLocationManager: - onResume
11-03 10:28:25.532 1881 2156 D TSLocationManager: [c.t.l.http.HttpService flush]
11-03 10:28:25.532 1881 2156 D TSLocationManager: ╔═════════════════════════════════════════════
11-03 10:28:25.532 1881 2156 D TSLocationManager: ║ HTTP Service
11-03 10:28:25.532 1881 2156 D TSLocationManager: ╠═════════════════════════════════════════════
11-03 10:29:12.232 1881 2064 D TSLocationManager: $ setConfig()
11-03 10:29:12.242 1881 2154 I TSLocationManager: [c.t.l.settings.Settings print]
11-03 10:29:12.242 1881 2154 I TSLocationManager: ╔═════════════════════════════════════════════
11-03 10:29:12.242 1881 2154 I TSLocationManager: ║ BackgroundGeolocation Settings
11-03 10:29:12.242 1881 2154 I TSLocationManager: ╠═════════════════════════════════════════════
11-03 10:29:12.242 1881 2154 I TSLocationManager: {
11-03 10:29:12.242 1881 2154 I TSLocationManager: "isMoving": false,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "enabled": false,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "odometer": 0,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "schedulerEnabled": false,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "trackingMode": "location",
11-03 10:29:12.242 1881 2154 I TSLocationManager: "distanceFilter": 10,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "desiredAccuracy": 0,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "desiredOdometerAccuracy": 100,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "locationUpdateInterval": 1000,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "fastestLocationUpdateInterval": 10000,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "locationTimeout": 60,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "deferTime": 0,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "disableElasticity": false,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "elasticityMultiplier": 1,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "activityRecognitionInterval": 10000,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "minimumActivityRecognitionConfidence": 75,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "triggerActivities": "in_vehicle, on_bicycle, on_foot, running, walking",
11-03 10:29:12.242 1881 2154 I TSLocationManager: "disableStopDetection": false,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "stationaryRadius": 25,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "stopTimeout": 5,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "stopOnStationary": false,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "url": "https:\/\/requestb.in\/1j0s82t1",
11-03 10:29:12.242 1881 2154 I TSLocationManager: "method": "POST",
11-03 10:29:12.242 1881 2154 I TSLocationManager: "autoSync": true,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "autoSyncThreshold": 0,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "batchSync": false,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "maxBatchSize": -1,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "params": {},
11-03 10:29:12.242 1881 2154 I TSLocationManager: "headers": {},
11-03 10:29:12.242 1881 2154 I TSLocationManager: "extras": {
11-03 10:29:12.242 1881 2154 I TSLocationManager: "hashId": "Helloshd"
11-03 10:29:12.242 1881 2154 I TSLocationManager: },
11-03 10:29:12.242 1881 2154 I TSLocationManager: "httpRootProperty": "location",
11-03 10:29:12.242 1881 2154 I TSLocationManager: "locationTemplate": "",
11-03 10:29:12.242 1881 2154 I TSLocationManager: "geofenceTemplate": "",
11-03 10:29:12.242 1881 2154 I TSLocationManager: "persist": true,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "maxDaysToPersist": 1,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "maxRecordsToPersist": -1,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "locationsOrderDirection": "ASC",
11-03 10:29:12.242 1881 2154 I TSLocationManager: "httpTimeout": 60000,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "geofenceProximityRadius": 1000,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "geofenceInitialTriggerEntry": true,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "stopOnTerminate": false,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "startOnBoot": false,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "heartbeatInterval": 60,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "foregroundService": false,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "notificationPriority": 0,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "notificationTitle": "Sportraxs Tracking",
11-03 10:29:12.242 1881 2154 I TSLocationManager: "notificationText": "Location services are working.",
11-03 10:29:12.242 1881 2154 I TSLocationManager: "notificationColor": "",
11-03 10:29:12.242 1881 2154 I TSLocationManager: "notificationIcon": "",
11-03 10:29:12.242 1881 2154 I TSLocationManager: "notificationSmallIcon": "INSERT ICON HERE",
11-03 10:29:12.242 1881 2154 I TSLocationManager: "notificationLargeIcon": "undefined",
11-03 10:29:12.242 1881 2154 I TSLocationManager: "forceReloadOnLocationChange": false,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "forceReloadOnMotionChange": false,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "forceReloadOnGeofence": false,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "forceReloadOnBoot": false,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "forceReloadOnHeartbeat": false,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "forceReloadOnSchedule": false,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "stopAfterElapsedMinutes": 0,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "schedule": [],
11-03 10:29:12.242 1881 2154 I TSLocationManager: "configureUrl": "",
11-03 10:29:12.242 1881 2154 I TSLocationManager: "configureInterval": -1,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "debug": false,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "logLevel": 5,
11-03 10:29:12.242 1881 2154 I TSLocationManager: "logMaxDays": 3
11-03 10:29:12.242 1881 2154 I TSLocationManager: }╚═════════════════════════════════════════════
11-03 10:29:12.269 1881 2154 D TSLocationManager: [c.t.l.a.BackgroundGeolocation$p run]
11-03 10:29:12.269 1881 2154 D TSLocationManager: ✅ Updated config
11-03 10:29:19.557 1881 2064 D TSLocationManager: $ getState()
11-03 10:29:19.566 1881 2064 D TSLocationManager: $ start()
11-03 10:29:19.569 1881 2154 I TSLocationManager: - Enable: false → true, trackingMode: location
11-03 10:29:19.579 1881 1881 I TSLocationManager: [c.t.l.BackgroundGeolocationService onStartCommand]
11-03 10:29:19.579 1881 1881 I TSLocationManager: ╔═════════════════════════════════════════════
11-03 10:29:19.579 1881 1881 I TSLocationManager: ║ BackgroundGeolocation Service started
11-03 10:29:19.579 1881 1881 I TSLocationManager: ╠═════════════════════════════════════════════
11-03 10:29:19.603 1881 1881 I TSLocationManager: [c.t.l.BackgroundGeolocationService c]
11-03 10:29:19.603 1881 1881 I TSLocationManager: ✅ Started in foreground
11-03 10:29:19.619 1881 1881 W TSLocationManager: [c.t.l.BackgroundGeolocationService e] Failed to find notificationLargeIcon: undefined
11-03 10:29:19.636 1881 1881 I TSLocationManager: [c.t.l.a.BackgroundGeolocation requestActivityUpdates]
11-03 10:29:19.636 1881 1881 I TSLocationManager: 🎾 Start activity updates: 10000
11-03 10:29:19.653 1881 1881 I TSLocationManager: [c.t.l.BackgroundGeolocationService a]
11-03 10:29:19.653 1881 1881 I TSLocationManager: 🔵 setPace: null → false
11-03 10:29:19.670 1881 1881 I TSLocationManager: [c.t.l.BackgroundGeolocationService j]
11-03 10:29:19.670 1881 1881 I TSLocationManager: 🔴 Stop heartbeat
11-03 10:29:19.690 1881 1881 I TSLocationManager: [c.t.l.BackgroundGeolocationService a]
11-03 10:29:19.690 1881 1881 I TSLocationManager: 🎾 Start heartbeat (60)
11-03 10:29:19.759 1881 2157 D TSLocationManager: [c.t.l.BackgroundGeolocationService onActivityRecognitionResult] still (100%)
11-03 10:29:19.780 1881 2157 D TSLocationManager: [c.t.l.a.BackgroundGeolocation isMainActivityActive] YES
11-03 10:29:19.804 1881 2688 I TSLocationManager: [c.t.l.LocationService onLocation]
11-03 10:29:19.804 1881 2688 I TSLocationManager: ℹ️ Location availability: true
11-03 10:29:20.420 1881 2824 D TSLocationManager: [c.t.l.LocationService onLocation]
11-03 10:29:20.420 1881 2824 D TSLocationManager: ╔═════════════════════════════════════════════
11-03 10:29:20.420 1881 2824 D TSLocationManager: ║ LocationService: location:1001
11-03 10:29:20.420 1881 2824 D TSLocationManager: ╠═════════════════════════════════════════════
11-03 10:29:20.420 1881 2824 D TSLocationManager: ╟─ 📍 Location[fused -33.928288,18.458345 hAcc=22 et=+49m2s44ms vAcc=??? sAcc=??? bAcc=???], age: 51ms
11-03 10:29:20.453 1881 2824 I TSLocationManager: [c.t.l.l.TSLocationManager onSingleLocationResult]
11-03 10:29:20.453 1881 2824 I TSLocationManager: 🔵 Acquired motionchange position, isMoving: false
11-03 10:29:20.468 1881 2824 D TSLocationManager: [c.t.l.l.TSLocationManager calculateMedianAccuracy] 21.515
11-03 10:29:20.531 1881 2154 I TSLocationManager: [c.t.l.d.s.SQLiteLocationDAO persist]
11-03 10:29:20.531 1881 2154 I TSLocationManager: ✅ INSERT: 3d7d0b80-840e-4275-9e19-8eedd304f62b
11-03 10:29:20.563 1881 2154 D TSLocationManager: [c.t.l.http.HttpService flush]
11-03 10:29:20.563 1881 2154 D TSLocationManager: ╔═════════════════════════════════════════════
11-03 10:29:20.563 1881 2154 D TSLocationManager: ║ HTTP Service
11-03 10:29:20.563 1881 2154 D TSLocationManager: ╠═════════════════════════════════════════════
11-03 10:29:20.607 1881 2154 D TSLocationManager: [c.t.l.d.s.SQLiteLocationDAO first]
11-03 10:29:20.607 1881 2154 D TSLocationManager: ✅ Locked 1 records
11-03 10:29:20.623 1881 2154 I TSLocationManager: [c.t.l.http.HttpService createRequest]
11-03 10:29:20.623 1881 2154 I TSLocationManager: 🔵 HTTP POST: 3d7d0b80-840e-4275-9e19-8eedd304f62b
11-03 10:29:22.709 1881 2860 I TSLocationManager: [c.t.l.http.HttpService$a onResponse]
11-03 10:29:22.709 1881 2860 I TSLocationManager: 🔵 Response: 200
11-03 10:29:22.741 1881 2860 D TSLocationManager: [c.t.l.d.s.SQLiteLocationDAO destroy]
11-03 10:29:22.741 1881 2860 D TSLocationManager: ✅ DESTROY: 3d7d0b80-840e-4275-9e19-8eedd304f62b
11-03 10:29:26.770 1881 1881 I TSLocationManager: - onPause
11-03 10:29:28.214 1881 1881 I TSLocationManager: CDVBackgroundGeolocation#onDestoy
11-03 10:29:28.220 1881 1881 I TSLocationManager: [c.t.l.a.BackgroundGeolocation onActivityDestroy]
11-03 10:29:28.220 1881 1881 I TSLocationManager: ╔═════════════════════════════════════════════
11-03 10:29:28.220 1881 1881 I TSLocationManager: ║ MainActivity was destroyed
11-03 10:29:28.220 1881 1881 I TSLocationManager: ╠═════════════════════════════════════════════
11-03 10:29:28.220 1881 1881 I TSLocationManager: ╟─ stopOnTerminate: false
11-03 10:29:28.220 1881 1881 I TSLocationManager: ╟─ enabled: true
11-03 10:29:28.241 1881 1881 I TSLocationManager: [c.t.l.l.TSLocationManager stopWatchPosition]
11-03 10:29:28.241 1881 1881 I TSLocationManager: 🔴 watchPosition: OFF
11-03 10:29:28.256 1881 1881 D TSLocationManager: [c.t.l.a.BackgroundGeolocation e]
11-03 10:29:28.256 1881 1881 D TSLocationManager: 🔴 Cleared callbacks
11-03 10:29:41.280 1881 2064 D TSLocationManager: $ addLocationListener()
11-03 10:29:41.284 1881 2064 D TSLocationManager: $ addMotionChangeListener()
11-03 10:29:41.287 1881 2064 D TSLocationManager: $ addActivityChangeListener()
11-03 10:29:41.289 1881 2064 D TSLocationManager: $ addProviderChangeListener()
11-03 10:29:41.294 1881 2064 D TSLocationManager: $ addGeofenceListener()
11-03 10:29:41.297 1881 2064 D TSLocationManager: $ addGeofencesChangeListener()
11-03 10:29:41.307 1881 2064 D TSLocationManager: [c.t.locationmanager.geofence.a a]
11-03 10:29:41.307 1881 2064 D TSLocationManager: ╔═════════════════════════════════════════════
11-03 10:29:41.307 1881 2064 D TSLocationManager: ║ TSGeofenceManager found 0/0 within 1000 meters
11-03 10:29:41.307 1881 2064 D TSLocationManager: ╠═════════════════════════════════════════════
11-03 10:29:41.307 1881 2064 D TSLocationManager: ╚═════════════════════════════════════════════
11-03 10:29:41.330 1881 2064 D TSLocationManager: $ addHttpListener()
11-03 10:29:41.332 1881 2064 D TSLocationManager: $ addHeartbeatListener()
11-03 10:29:41.335 1881 2064 D TSLocationManager: $ addScheduleListener()
11-03 10:29:41.337 1881 2064 D TSLocationManager: $ addPowerSaveChangeListener()
11-03 10:29:41.348 1881 2064 D TSLocationManager: $ configure()
11-03 10:29:41.632 1881 1881 I TSLocationManager: - onPause
11-03 10:29:41.994 1881 1881 I TSLocationManager: CDVBackgroundGeolocation#onDestoy
11-03 10:29:42.000 1881 1881 I TSLocationManager: [c.t.l.a.BackgroundGeolocation onActivityDestroy]
11-03 10:29:42.000 1881 1881 I TSLocationManager: ╔═════════════════════════════════════════════
11-03 10:29:42.000 1881 1881 I TSLocationManager: ║ MainActivity was destroyed
11-03 10:29:42.000 1881 1881 I TSLocationManager: ╠═════════════════════════════════════════════
11-03 10:29:42.000 1881 1881 I TSLocationManager: ╟─ stopOnTerminate: true
11-03 10:29:42.000 1881 1881 I TSLocationManager: ╟─ enabled: true
11-03 10:29:42.021 1881 1881 I TSLocationManager: [c.t.l.l.TSLocationManager stopWatchPosition]
11-03 10:29:42.021 1881 1881 I TSLocationManager: 🔴 watchPosition: OFF
11-03 10:29:42.042 1881 1881 D TSLocationManager: [c.t.l.a.BackgroundGeolocation e]
11-03 10:29:42.042 1881 1881 D TSLocationManager: 🔴 Cleared callbacks
11-03 10:29:42.085 1881 1881 I TSLocationManager: [c.t.l.a.BackgroundGeolocation removeActivityUpdates]
11-03 10:29:42.085 1881 1881 I TSLocationManager: 🔴 Stop activity updates
11-03 10:29:42.170 1881 1881 D TSLocationManager: [c.t.l.BackgroundGeolocationService onDestroy]
11-03 10:29:42.170 1881 1881 D TSLocationManager: ╔═════════════════════════════════════════════
11-03 10:29:42.170 1881 1881 D TSLocationManager: ║ BackgroundGeolocationService destroyed
11-03 10:29:42.170 1881 1881 D TSLocationManager: ╠═════════════════════════════════════════════
11-03 10:29:42.205 1881 1881 I TSLocationManager: [c.t.l.BackgroundGeolocationService j]
11-03 10:29:42.205 1881 1881 I TSLocationManager: 🔴 Stop heartbeat
11-03 10:29:46.855 3235 3343 I TSLocationManager:
11-03 10:29:46.855 3235 3343 I TSLocationManager: ╔═════════════════════════════════════════════
11-03 10:29:46.855 3235 3343 I TSLocationManager: ║ License Validation Failure
11-03 10:29:46.855 3235 3343 I TSLocationManager: ╠═════════════════════════════════════════════
11-03 10:29:46.855 3235 3343 I TSLocationManager: ╟─ BackgroundGeolocation is running in evaluation mode.
11-03 10:29:46.872 3235 3343 I TSLocationManager: [c.t.l.util.Sensors print]
11-03 10:29:46.872 3235 3343 I TSLocationManager: ╔═════════════════════════════════════════════
11-03 10:29:46.872 3235 3343 I TSLocationManager: ║ DEVICE SENSORS
11-03 10:29:46.872 3235 3343 I TSLocationManager: ╠═════════════════════════════════════════════
11-03 10:29:46.872 3235 3343 I TSLocationManager: ╟─ ✅ ACCELEROMETER: {Sensor name="BMI160 accelerometer", vendor="Bosch", version=1, type=1, maxRange=78.4532, resolution=0.0023942017, power=0.001, minDelay=2500}
11-03 10:29:46.872 3235 3343 I TSLocationManager: ╟─ ✅ GYROSCOPE: {Sensor name="BMI160 gyroscope", vendor="Bosch", version=1, type=4, maxRange=17.453293, resolution=5.326322E-4, power=0.001, minDelay=2500}
11-03 10:29:46.872 3235 3343 I TSLocationManager: ╟─ ✅ MAGNETOMETER: {Sensor name="BMM150 magnetometer", vendor="Bosch", version=1, type=2, maxRange=1300.0, resolution=0.0, power=0.001, minDelay=20000}
11-03 10:29:46.872 3235 3343 I TSLocationManager: ╟─ ✅ SIGNIFICANT_MOTION: {Sensor name="Significant motion", vendor="Google", version=1, type=17, maxRange=1.0, resolution=1.0, power=0.001, minDelay=-1}
11-03 10:29:46.872 3235 3343 I TSLocationManager: ╚═════════════════════════════════════════════
11-03 10:29:46.925 3235 3343 I TSLocationManager: [c.t.l.a.BackgroundGeolocation <init>]
11-03 10:29:46.925 3235 3343 I TSLocationManager: ╔═════════════════════════════════════════════
11-03 10:29:46.925 3235 3343 I TSLocationManager: ║ BackgroundGeolocation adapter
11-03 10:29:46.925 3235 3343 I TSLocationManager: ╠═════════════════════════════════════════════
11-03 10:29:46.957 3235 3343 D TSLocationManager: [c.t.l.d.s.SQLiteLocationDAO dbh]
11-03 10:29:46.957 3235 3343 D TSLocationManager: ✅ Opened database
11-03 10:29:46.973 3235 3343 D TSLocationManager: [c.t.l.d.s.SQLiteLocationDAO prune]
11-03 10:29:46.973 3235 3343 D TSLocationManager: ℹ️ PRUNE -1 days
11-03 10:29:47.024 3235 3343 D TSLocationManager: [c.t.l.data.sqlite.GeofenceDAO dbh]
11-03 10:29:47.024 3235 3343 D TSLocationManager: ✅ Opened database
11-03 10:29:47.047 3235 3343 I TSLocationManager: [c.t.l.a.BackgroundGeolocation <init>]
11-03 10:29:47.047 3235 3343 I TSLocationManager: 🔵 Connecting to GooglePlayServices...
11-03 10:29:47.061 3235 3343 D TSLocationManager: $ addLocationListener()
11-03 10:29:47.064 3235 3343 D TSLocationManager: $ addMotionChangeListener()
11-03 10:29:47.067 3235 3343 D TSLocationManager: $ addActivityChangeListener()
11-03 10:29:47.070 3235 3343 D TSLocationManager: $ addProviderChangeListener()
11-03 10:29:47.075 3235 3343 D TSLocationManager: $ addGeofenceListener()
11-03 10:29:47.077 3235 3343 D TSLocationManager: $ addGeofencesChangeListener()
11-03 10:29:47.078 3235 3235 I TSLocationManager: [c.t.l.a.BackgroundGeolocation onConnected]
11-03 10:29:47.078 3235 3235 I TSLocationManager: ✅ Google Play Services: connected (version code:11400000)
11-03 10:29:47.079 3235 3343 D TSLocationManager: $ addHttpListener()
11-03 10:29:47.080 3235 3343 D TSLocationManager: $ addHeartbeatListener()
11-03 10:29:47.082 3235 3343 D TSLocationManager: $ addScheduleListener()
11-03 10:29:47.084 3235 3343 D TSLocationManager: $ addPowerSaveChangeListener()
11-03 10:29:47.090 3235 3343 D TSLocationManager: $ configure()
11-03 10:29:47.373 3235 3235 I TSLocationManager: - onPause
11-03 10:29:47.697 3235 3235 I TSLocationManager: CDVBackgroundGeolocation#onDestoy
11-03 10:29:47.715 3235 3235 I TSLocationManager: [c.t.l.a.BackgroundGeolocation onActivityDestroy]
11-03 10:29:47.715 3235 3235 I TSLocationManager: ╔═════════════════════════════════════════════
11-03 10:29:47.715 3235 3235 I TSLocationManager: ║ MainActivity was destroyed
11-03 10:29:47.715 3235 3235 I TSLocationManager: ╠═════════════════════════════════════════════
11-03 10:29:47.715 3235 3235 I TSLocationManager: ╟─ stopOnTerminate: true
11-03 10:29:47.715 3235 3235 I TSLocationManager: ╟─ enabled: true
11-03 10:29:47.740 3235 3235 I TSLocationManager: [c.t.l.l.TSLocationManager stopWatchPosition]
11-03 10:29:47.740 3235 3235 I TSLocationManager: 🔴 watchPosition: OFF
11-03 10:29:47.755 3235 3235 D TSLocationManager: [c.t.l.a.BackgroundGeolocation e]
11-03 10:29:47.755 3235 3235 D TSLocationManager: 🔴 Cleared callbacks
I've narrowed it down to the app crashing when calling trying to configure a second instance of BackgroundGeolocation. This was happening because the app wasn't storing the configuration on destroy.
Closing because this was an issue with my app and not the plugin.
Your Environment
cordova -v
): 7.1.0cordova platform ls
): android 6.3.0Expected Behavior
stopOnTerminate
should be set to false by config.Actual Behavior
stopOnTerminate
is still true in the logs. App keeps crashing if the tracking service is initialised and the app is closed and restarted.Context
The app keeps crashing when I restart it. And needs to be reinstalled to get it going again. Is there any way to check if the Android background service is running on application boot? I am using Vuejs so the BackgroundGeolocation object is not persistent after application restart. I can possibly store it in local storage, but that requires a lot more development as I would need to create mutators to change it (just the way vuex state management works).
Debug logs