{ "id": "115264", "key": "TIMOB-14059", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "10153", "key": "TIMOB", "name": "Titanium SDK/CLI", "projectCategory": { "id": "10100", "description": "Titanium and related SDKs used in application development", "name": "Client" } }, "fixVersions": [ { "id": "14982", "description": "Release 3.2.0", "name": "Release 3.2.0", "archived": false, "released": true, "releaseDate": "2013-12-19" } ], "resolution": { "id": "3", "description": "The problem is a duplicate of an existing issue.", "name": "Duplicate" }, "resolutiondate": "2013-06-03T22:57:52.000+0000", "created": "2013-05-31T02:25:26.000+0000", "priority": { "name": "Critical", "id": "1" }, "labels": [ "analytics", "qe-3.1.1", "qe-testadded" ], "versions": [], "issuelinks": [ { "id": "29206", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "outwardIssue": { "id": "113911", "key": "TIMOB-13776", "fields": { "summary": "ti.background events are not sent until the next app session start", "status": { "description": "This issue was once resolved, but the resolution was deemed incorrect. From here issues are either marked assigned or resolved.", "name": "Reopened", "id": "4", "statusCategory": { "id": 2, "key": "new", "colorName": "blue-gray", "name": "To Do" } }, "priority": { "name": "High", "id": "2" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } }, { "id": "29217", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "outwardIssue": { "id": "115265", "key": "TIMOB-14060", "fields": { "summary": "Parity: Backgrounding the app on Android does not send ti.end event ", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "priority": { "name": "High", "id": "2" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } } ], "assignee": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2014-02-24T23:12:57.000+0000", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "10202", "name": "Android", "description": "Android Platform" } ], "description": "Repro steps:\r\n\r\n1. Create a default app from appcelerator studio\r\n2. Install it on Android device\r\n3. Go to dashboard.appcelerator.com\r\n4. Look up your app and go to Analytics.Realtime tab\r\n5. Launch the app on the android device\r\n6. After few minutes, background the app on device and then go to settings->apps->select your app\r\n7. tap on Force stop \r\n8. Wait for few moments, look up dashboard and you will see the active session count go up by 1.\r\n9. Repeat the steps from 5 to 8 multiple times\r\n10. The active session count will go increasing with avg session length still N/A\r\n\r\n\r\nTo ensure this is not a bug in PEM or dashboard, I had a custom build which spits out analytics sent by SDK and I kept on seeing ti.start being sent when the app was relaunched after force stop but not ti.end.\r\n\r\n1. At first launch:\r\n\r\nTiAnalyticsSvc(26293): (Thread-896) [56,29758] ------------------------------ Sending :: [{\"id\":\"ab8e5597-8882-4454-8b26-94d99d22a0a4:df9547607f27ccd6\",\"sid\":\"a01e30a5-676d-41c8-8776-285ddf2d7976\",\"ts\":\"2013-05-31T01:00:50.288+0000\",\"event\":\"ti.enroll\",\"data\":{\"platform\":\"android\",\"osarch\":\"ARMv7 Processor rev 2 (v7l)\",\"model\":\"Nexus 4\",\"mac_addr\":\"10:68:3f:47:90:54\",\"previous_mid\":\"\",\"oscpu\":4,\"ostype\":\"32bit\",\"deploytype\":\"test\",\"app_id\":\"com.appcelerator.testAnalytics2\",\"app_name\":\"testAnalytics2\"},\"seq\":1,\"mid\":\"df9547607f27ccd6\",\"ver\":\"2\",\"type\":\"ti.enroll\",\"aguid\":\"d8504b70-8106-4423-b35a-128a56fb30db\"},{\"id\":\"fbb7b410-b8ed-49eb-b303-f0793bfdf370:df9547607f27ccd6\",\"sid\":\"a01e30a5-676d-41c8-8776-285ddf2d7976\",\"ts\":\"2013-05-31T01:00:50.312+0000\",\"event\":\"ti.start\",\"data\":{\"platform\":\"android\",\"os\":\"Android\",\"model\":\"Nexus 4\",\"tz\":-480,\"nettype\":\"WIFI\",\"deploytype\":\"test\",\"app_version\":\"1.0\",\"osver\":\"4.2.1\",\"version\":\"3.1.1\"},\"seq\":2,\"mid\":\"df9547607f27ccd6\",\"ver\":\"2\",\"type\":\"ti.start\",\"aguid\":\"d8504b70-8106-4423-b35a-128a56fb30db\"}] analytics events.\r\n\r\n2. After first stop and relaunch ( ignore the featureEvent.testButton custom event)\r\n\r\nAnalyticsSvc(26293): (Thread-901) [31,3353] ------------------------------ Sending :: [{\"id\":\"a44df8d1-2436-4a64-b938-7d2f70a67b87:df9547607f27ccd6\",\"sid\":\"5ab6425c-1aad-41eb-87ba-3f451c139c21\",\"ts\":\"2013-05-31T01:10:37.163+0000\",\"event\":\"ti.start\",\"data\":{\"platform\":\"android\",\"os\":\"Android\",\"model\":\"Nexus 4\",\"tz\":-480,\"nettype\":\"WIFI\",\"deploytype\":\"test\",\"app_version\":\"1.0\",\"osver\":\"4.2.1\",\"version\":\"3.1.1\"},\"seq\":6,\"mid\":\"df9547607f27ccd6\",\"ver\":\"2\",\"type\":\"ti.start\",\"aguid\":\"d8504b70-8106-4423-b35a-128a56fb30db\"},{\"id\":\"b5fc2594-889f-4345-badf-84a2a59c116d:df9547607f27ccd6\",\"sid\":\"5ab6425c-1aad-41eb-87ba-3f451c139c21\",\"ts\":\"2013-05-31T01:10:39.364+0000\",\"event\":\"featureEvent.testButton\",\"data\":{\"value\":\"\"},\"seq\":7,\"mid\":\"df9547607f27ccd6\",\"ver\":\"2\",\"type\":\"app.feature\",\"aguid\":\"d8504b70-8106-4423-b35a-128a56fb30db\"},{\"id\":\"48040511-a642-49db-8ddf-cec6f1d6c156:df9547607f27ccd6\",\"sid\":\"5ab6425c-1aad-41eb-87ba-3f451c139c21\",\"ts\":\"2013-05-31T01:10:54.915+0000\",\"event\":\"featureEvent.testButton\",\"data\":{\"value\":\"\"},\"seq\":8,\"mid\":\"df9547607f27ccd6\",\"ver\":\"2\",\"type\":\"app.feature\",\"aguid\":\"d8504b70-8106-4423-b35a-128a56fb30db\"}] analytics events.\r\n\r\n3. After second force stop and relaunch\r\n\r\nTiAnalyticsSvc(27929): (Thread-923) [51,29711] ------------------------------ Sending :: [{\"id\":\"3af41073-e621-4749-bd36-63ed5f823bbc:df9547607f27ccd6\",\"sid\":\"7b4861e2-a06f-4814-b8c8-21f218fd78ee\",\"ts\":\"2013-05-31T01:32:44.902+0000\",\"event\":\"ti.start\",\"data\":{\"platform\":\"android\",\"os\":\"Android\",\"model\":\"Nexus 4\",\"tz\":-480,\"nettype\":\"WIFI\",\"deploytype\":\"test\",\"app_version\":\"1.0\",\"osver\":\"4.2.1\",\"version\":\"3.1.1\"},\"seq\":10,\"mid\":\"df9547607f27ccd6\",\"ver\":\"2\",\"type\":\"ti.start\",\"aguid\":\"d8504b70-8106-4423-b35a-128a56fb30db\"}] analytics events.\r\n\r\n4. After third force stop and relaunch\r\n\r\nTiAnalyticsSvc(28357): (Thread-935) [29660,29660] Analytics Service Started\r\nI/TiAnalyticsSvc(28357): (Thread-935) [85,29745] ------------------------------ Sending :: [{\"id\":\"18dd716b-8cde-42e6-aaf9-5c21f39beb94:df9547607f27ccd6\",\"sid\":\"3ab44924-a342-427b-810c-b7273c28ae57\",\"ts\":\"2013-05-31T01:35:48.447+0000\",\"event\":\"ti.start\",\"data\":{\"platform\":\"android\",\"os\":\"Android\",\"model\":\"Nexus 4\",\"tz\":-480,\"nettype\":\"WIFI\",\"deploytype\":\"test\",\"app_version\":\"1.0\",\"osver\":\"4.2.1\",\"version\":\"3.1.1\"},\"seq\":14,\"mid\":\"df9547607f27ccd6\",\"ver\":\"2\",\"type\":\"ti.start\",\"aguid\":\"d8504b70-8106-4423-b35a-128a56fb30db\"}] analytics events.\r\n\r\n5. After fourth force stop and relaunch\r\n\r\nTiAnalyticsSvc(28785): (Thread-956) [57,29651] ------------------------------ Sending :: [{\"id\":\"59624ade-44c8-428a-99d0-b700d4c91c7f:df9547607f27ccd6\",\"sid\":\"e334d3f5-2440-4a27-a24f-5729a82e01eb\",\"ts\":\"2013-05-31T01:37:39.577+0000\",\"event\":\"ti.start\",\"data\":{\"platform\":\"android\",\"os\":\"Android\",\"model\":\"Nexus 4\",\"tz\":-480,\"nettype\":\"WIFI\",\"deploytype\":\"test\",\"app_version\":\"1.0\",\"osver\":\"4.2.1\",\"version\":\"3.1.1\"},\"seq\":15,\"mid\":\"df9547607f27ccd6\",\"ver\":\"2\",\"type\":\"ti.start\",\"aguid\":\"d8504b70-8106-4423-b35a-128a56fb30db\"}] analytics events.\r\n\r\n\r\nAs it can be seen, the ti.end events are not being sent successfully and hence dashboard does not know that the session has ended and hence messes up session results like active number of sessions, avg session length calculations. \r\n\r\n", "attachment": [], "flagged": false, "summary": "Analytics: Ti.end event not sent after killing and relaunching the app on Android", "creator": { "name": "mgadiya", "key": "mgadiya", "displayName": "Mukesh Gadiya", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "mgadiya", "key": "mgadiya", "displayName": "Mukesh Gadiya", "active": true, "timeZone": "America/Los_Angeles" }, "environment": "SDK : 3.1.1.v20130529114554\r\nAppcelerator Studio: 3.1.1.201305232424\r\n", "comment": { "comments": [ { "id": "255156", "author": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Some interesting commentary in http://stackoverflow.com/questions/11473849/android-app-doenst-call-ondestroy-when-killed-ics", "updateAuthor": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-05-31T13:09:26.000+0000", "updated": "2013-05-31T13:09:26.000+0000" }, { "id": "255194", "author": { "name": "pwang", "key": "pwang", "displayName": "Ping Wang", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Similar discussion: http://stackoverflow.com/questions/14375720/android-destroying-activities-killing-processes", "updateAuthor": { "name": "pwang", "key": "pwang", "displayName": "Ping Wang", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-05-31T17:41:14.000+0000", "updated": "2013-05-31T17:41:14.000+0000" }, { "id": "255654", "author": { "name": "srahim", "key": "srahim", "displayName": "Sabil Rahim", "active": true, "timeZone": "America/Los_Angeles" }, "body": "duplicate of TIMOB-14060", "updateAuthor": { "name": "srahim", "key": "srahim", "displayName": "Sabil Rahim", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-06-03T22:57:52.000+0000", "updated": "2013-06-03T22:57:52.000+0000" }, { "id": "280415", "author": { "name": "lokeshchdhry", "key": "lokeshchdhry", "displayName": "Lokesh Choudhary", "active": false, "timeZone": "America/Los_Angeles" }, "updateAuthor": { "name": "lokeshchdhry", "key": "lokeshchdhry", "displayName": "Lokesh Choudhary", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2013-11-20T22:38:38.000+0000", "updated": "2013-11-20T22:38:38.000+0000" } ], "maxResults": 4, "total": 4, "startAt": 0 } } }