{"action":"created","issue":{"url":"https://api.github.com/repos/Tribler/dispersy/issues/442","labels_url":"https://api.github.com/repos/Tribler/dispersy/issues/442/labels{/name}","comments_url":"https://api.github.com/repos/Tribler/dispersy/issues/442/comments","events_url":"https://api.github.com/repos/Tribler/dispersy/issues/442/events","html_url":"https://github.com/Tribler/dispersy/issues/442","id":93989437,"number":442,"title":"Fix memory leakage Tribler.dispersy.candidate.Candidate","user":{"login":"synctext","id":325224,"avatar_url":"https://avatars.githubusercontent.com/u/325224?v=3","gravatar_id":"","url":"https://api.github.com/users/synctext","html_url":"https://github.com/synctext","followers_url":"https://api.github.com/users/synctext/followers","following_url":"https://api.github.com/users/synctext/following{/other_user}","gists_url":"https://api.github.com/users/synctext/gists{/gist_id}","starred_url":"https://api.github.com/users/synctext/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/synctext/subscriptions","organizations_url":"https://api.github.com/users/synctext/orgs","repos_url":"https://api.github.com/users/synctext/repos","events_url":"https://api.github.com/users/synctext/events{/privacy}","received_events_url":"https://api.github.com/users/synctext/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/Tribler/dispersy/labels/bug","name":"bug","color":"fc2929"}],"state":"open","locked":false,"assignee":{"login":"devos50","id":1707075,"avatar_url":"https://avatars.githubusercontent.com/u/1707075?v=3","gravatar_id":"","url":"https://api.github.com/users/devos50","html_url":"https://github.com/devos50","followers_url":"https://api.github.com/users/devos50/followers","following_url":"https://api.github.com/users/devos50/following{/other_user}","gists_url":"https://api.github.com/users/devos50/gists{/gist_id}","starred_url":"https://api.github.com/users/devos50/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/devos50/subscriptions","organizations_url":"https://api.github.com/users/devos50/orgs","repos_url":"https://api.github.com/users/devos50/repos","events_url":"https://api.github.com/users/devos50/events{/privacy}","received_events_url":"https://api.github.com/users/devos50/received_events","type":"User","site_admin":false},"milestone":null,"comments":15,"created_at":"2015-07-09T08:27:37Z","updated_at":"2015-12-01T16:08:40Z","closed_at":null,"body":"we have a _small_ memory leak.\r\n\r\n4000 Tribler.dispersy.candidate.Candidate objects are in memory after 30h.\r\n145313 Tribler.dispersy.candidate.Candidate objects are in memory after 784h.\r\n\r\nSuspects for memory leakage. Our automatic reports with difficult 60MByte traces: http://jenkins.tribler.org/job/Test_performance_Tribler_idle_24H_nightly_devel/605/artifact/output/memprof/2180/\r\n\r\nElric has some tools parsing this. These can identify the possible dictionary.\r\n\r\nUsing _Dowser_ we see the following suspects:\r\nTribler.dispersy.candidate.Candidate\r\nTribler.dispersy.candidate.WalkCandidate\r\nTribler.dispersy.member.Member\r\n (probably linked to their key: Tribler.dispersy.crypto.M2CryptoPK)\r\n\r\nTribler shows 1108 channels, Dowser stores \r\nTribler.Main.Utility.GuiDBTuples.Channel\r\n\r\nAt 11:00am, after running for 24hours:\r\n![dowser_1100am_dump](https://cloud.githubusercontent.com/assets/325224/8574189/b8d06cd6-2595-11e5-8109-b75330693cdc.png)\r\n\r\n8 hours later:\r\n![dowser_1700_dump](https://cloud.githubusercontent.com/assets/325224/8574367/93a3ee32-2596-11e5-9eaa-23a0e28b43d3.png)\r\n"},"comment":{"url":"https://api.github.com/repos/Tribler/dispersy/issues/comments/161015072","html_url":"https://github.com/Tribler/dispersy/issues/442#issuecomment-161015072","issue_url":"https://api.github.com/repos/Tribler/dispersy/issues/442","id":161015072,"user":{"login":"NielsZeilemaker","id":3777585,"avatar_url":"https://avatars.githubusercontent.com/u/3777585?v=3","gravatar_id":"","url":"https://api.github.com/users/NielsZeilemaker","html_url":"https://github.com/NielsZeilemaker","followers_url":"https://api.github.com/users/NielsZeilemaker/followers","following_url":"https://api.github.com/users/NielsZeilemaker/following{/other_user}","gists_url":"https://api.github.com/users/NielsZeilemaker/gists{/gist_id}","starred_url":"https://api.github.com/users/NielsZeilemaker/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/NielsZeilemaker/subscriptions","organizations_url":"https://api.github.com/users/NielsZeilemaker/orgs","repos_url":"https://api.github.com/users/NielsZeilemaker/repos","events_url":"https://api.github.com/users/NielsZeilemaker/events{/privacy}","received_events_url":"https://api.github.com/users/NielsZeilemaker/received_events","type":"User","site_admin":false},"created_at":"2015-12-01T16:08:40Z","updated_at":"2015-12-01T16:08:40Z","body":"Let's remove the communities one by one. \r\nVerify the memory usage afterwards\r\n```\r\nc = dispersy.get_communities()[0]\r\nc.unload_community()\r\n\r\nfor community in dispersy.get_communities():\r\n    print community.get_classification()\r\n\r\n```\r\nNot sure how Tribler will respond :smile: And remove them one by one."}}