{ "id": "155889", "key": "TIMOB-20614", "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": [], "resolution": { "id": "7", "description": "", "name": "Invalid" }, "resolutiondate": "2016-04-27T20:27:22.000+0000", "created": "2016-03-22T10:05:53.000+0000", "priority": { "name": "High", "id": "2" }, "labels": [], "versions": [ { "id": "16997", "name": "Release 5.2.0", "archived": false, "released": true, "releaseDate": "2016-02-23" } ], "issuelinks": [], "assignee": { "name": "apetkov", "key": "apetkov", "displayName": "Angel Petkov", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2017-03-20T21:36:52.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": "10206", "name": "iOS", "description": "iOS Platform" } ], "description": "TiViewProxy (and general proxy) objects do not appear to be always removed from memory, and garbage collection (when it occurs) regularly misses proxy objects, even when they are explicitly removed from parent views and nulled. \r\n\r\n*Test Code:* Reporter’s sample [code|https://www.dropbox.com/s/3zjhjnk1fe27yc2/sampleApp%20%281%29.zip?dl=0].\r\n\r\n*Test Environment:*\r\n\r\nAppcelerator Command-Line Interface; 5.2.0\r\nMac OS X,10.11.1Xcode-7.2.1,iOS SDK: 9.1,iPad\r\nNode.js: 0.12.7\r\nnpm: 2.11.3\r\nAppcelerator CLI\r\n Installer = 4.2.3\r\n Core Package = 5.2.0\r\nTitanium CLI:5.0.6\r\nTI SDK:5.4.0.v20160307212310,5.20GA\r\n\r\n\r\n*Test Steps:*\r\n# Import the app\r\n# Run it in a IPad device/simulator.\r\n# Simply open Instruments 7.2.1 via an iOS 9.2. device \r\n# Go>Room with List View>Back to home. Same as Go>Room with View>Back to home.Watch the proxy object numbers go up and down inconsistently as we move back and forth within the same screens repeatedly. \r\n\r\n*Test Results:*\r\n\r\nCheck the [link|http://postimg.org/image/q7sz4rtcd/].\r\n", "attachment": [], "flagged": false, "summary": " iOS:Ti proxies are not always released from memory", "creator": { "name": "rmitro", "key": "rmitro", "displayName": "Rakhi Mitro", "active": false, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "rmitro", "key": "rmitro", "displayName": "Rakhi Mitro", "active": false, "timeZone": "America/Los_Angeles" }, "environment": null, "comment": { "comments": [ { "id": "381099", "author": { "name": "apetkov", "key": "apetkov", "displayName": "Angel Petkov", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Hello thank you for the well written ticket , i was able to reproduce the memory leaks. They were caused by a method inside our krollbridge class.\r\n\r\nPR:https://github.com/appcelerator/titanium_mobile/pull/7894/files", "updateAuthor": { "name": "apetkov", "key": "apetkov", "displayName": "Angel Petkov", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2016-03-30T22:11:01.000+0000", "updated": "2016-03-30T22:11:01.000+0000" }, { "id": "383149", "author": { "name": "apetkov", "key": "apetkov", "displayName": "Angel Petkov", "active": true, "timeZone": "America/Los_Angeles" }, "body": "[~rmitro] Hello, after further investigation there isn't a memory leak taking place, If you were to track all the proxy objects in memory you will see that once you switch back to the main view, they will be discarded. Sometimes it will take sometime longer to discard the items, never the less they will be garbage collected. The memory leaks I thought i was seeing before was actually the delayed data on instruments. ", "updateAuthor": { "name": "apetkov", "key": "apetkov", "displayName": "Angel Petkov", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2016-04-19T16:02:57.000+0000", "updated": "2016-04-19T16:02:57.000+0000" }, { "id": "383279", "author": { "name": "plancaster", "key": "plancaster", "displayName": "Peter Lancaster", "active": true, "timeZone": "Europe/London" }, "body": "Thanks for coming back to us on this - I thought after viewing this presentation by Rick Blalock: https://vimeo.com/29804284 though - this was something we should be able to see fairly immediately in iOS, via Instruments?\r\n\r\nWhen you say they are 'eventually' garbage collected - how long do / can objects take to be removed from memory?\r\n\r\nIf this is an issue with Instruments updating - how can we effectively debug memory leaks like this? Do native (swift / objective c) apps suffer from the same lag / delays?", "updateAuthor": { "name": "plancaster", "key": "plancaster", "displayName": "Peter Lancaster", "active": true, "timeZone": "Europe/London" }, "created": "2016-04-20T08:10:14.000+0000", "updated": "2016-04-20T08:10:36.000+0000" }, { "id": "383374", "author": { "name": "apetkov", "key": "apetkov", "displayName": "Angel Petkov", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Hello Peter, thank you for the feedback. When i say delayed i do mean only by the means of couple of seconds, if you were to track all the proxies enter one of the 2 views of the application and exit back. You will see that it does get garbage collected or if it doesn't straight away after one or two seconds it will be. Another way to test it, is to simulate a memory warning , if there was indeed a memory leek you would see more live views. Another factor is that this code is very old and has not been changed for years, so its not possible that a memory leak would appear ,without any new code being added. ", "updateAuthor": { "name": "apetkov", "key": "apetkov", "displayName": "Angel Petkov", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2016-04-20T16:40:26.000+0000", "updated": "2016-04-20T16:46:18.000+0000" }, { "id": "384115", "author": { "name": "penrique", "key": "penrique", "displayName": "Pedro Enrique", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Ticket is invalid.", "updateAuthor": { "name": "penrique", "key": "penrique", "displayName": "Pedro Enrique", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2016-04-27T20:27:17.000+0000", "updated": "2016-04-27T20:27:17.000+0000" }, { "id": "413995", "author": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Closing ticket as invalid.", "updateAuthor": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2017-03-20T21:36:52.000+0000", "updated": "2017-03-20T21:36:52.000+0000" } ], "maxResults": 10, "total": 10, "startAt": 0 } } }