{"action":"created","issue":{"url":"https://api.github.com/repos/matteodem/meteor-easy-search/issues/419","repository_url":"https://api.github.com/repos/matteodem/meteor-easy-search","labels_url":"https://api.github.com/repos/matteodem/meteor-easy-search/issues/419/labels{/name}","comments_url":"https://api.github.com/repos/matteodem/meteor-easy-search/issues/419/comments","events_url":"https://api.github.com/repos/matteodem/meteor-easy-search/issues/419/events","html_url":"https://github.com/matteodem/meteor-easy-search/issues/419","id":125556726,"number":419,"title":"High CPU usage and pub-sub response times on version 2","user":{"login":"actooalizame","id":11241403,"avatar_url":"https://avatars.githubusercontent.com/u/11241403?v=3","gravatar_id":"","url":"https://api.github.com/users/actooalizame","html_url":"https://github.com/actooalizame","followers_url":"https://api.github.com/users/actooalizame/followers","following_url":"https://api.github.com/users/actooalizame/following{/other_user}","gists_url":"https://api.github.com/users/actooalizame/gists{/gist_id}","starred_url":"https://api.github.com/users/actooalizame/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/actooalizame/subscriptions","organizations_url":"https://api.github.com/users/actooalizame/orgs","repos_url":"https://api.github.com/users/actooalizame/repos","events_url":"https://api.github.com/users/actooalizame/events{/privacy}","received_events_url":"https://api.github.com/users/actooalizame/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/matteodem/meteor-easy-search/labels/waiting","name":"waiting","color":"eb6420"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":9,"created_at":"2016-01-08T07:19:57Z","updated_at":"2016-05-02T08:32:53Z","closed_at":"2016-05-02T08:32:53Z","body":"I'm rebuilding an app on React (previously used Blaze) and updated to version 2 of this package.\r\nI couldn't make it work without having <strong>several performance issues</strong> on a Digital Ocean 1GB droplet. \r\nI have a \"Professors\" collection that uses >6k documents.\r\n\r\nThe Kadira monitor showed a publication of your package  \"professors/easySearch\" taking <strong>several</strong> seconds to load.\r\n![cap-kadira-pubs-before](https://cloud.githubusercontent.com/assets/11241403/12192547/5432e0a6-b5be-11e5-99bc-3d9da376abaa.jpg)\r\n\r\nYou can see that implemented here:  http://reprofes.meteor.com/\r\n(search for a name like \"Hugo\")\r\nAt first it appears to work as expected, but after waiting some minutes without searching, it will take many seconds to display the results. <strong>This goes back to normal after hard reloading the page</strong>.\r\nAlso: The CPU usage peaked up to 100%\r\n<hr>\r\nOnce I downgraded the package to version 1.6.4, everything works really fast, without the \"professors/easySearch\" publication not even appearing, and with the CPU usage never reaching the 2% mark.\r\n![cap-kadira-pubs-after](https://cloud.githubusercontent.com/assets/11241403/12192530/1ad0a1ae-b5be-11e5-8e72-e6386bb6a2f0.jpg)\r\n\r\nYou can see that implemented here: http://webparaemprendedores.com/\r\n\r\nHere is a screen capture of the obvious performance difference being tracked down by Kadira, before and after going back to the previous version :\r\n![cap-kadira-easysearch](https://cloud.githubusercontent.com/assets/11241403/12192275/f237b78e-b5bb-11e5-8046-7e3f649650a7.jpg)\r\n\r\nPlease note that I'm not subscribing to any publication except for single-documents publications and your v.2 package generated pubs-subs.\r\nI really don't know what may be causing this, but I followed along your v.2 documentation, and made it work (as you can see on the v.2 meteor.com hosted example).\r\n<strong>Please correct these issues, as I want to use the up-to-date version of this useful package.</strong>\r\n\r\nThanks,"},"comment":{"url":"https://api.github.com/repos/matteodem/meteor-easy-search/issues/comments/216141650","html_url":"https://github.com/matteodem/meteor-easy-search/issues/419#issuecomment-216141650","issue_url":"https://api.github.com/repos/matteodem/meteor-easy-search/issues/419","id":216141650,"user":{"login":"matteodem","id":1301147,"avatar_url":"https://avatars.githubusercontent.com/u/1301147?v=3","gravatar_id":"","url":"https://api.github.com/users/matteodem","html_url":"https://github.com/matteodem","followers_url":"https://api.github.com/users/matteodem/followers","following_url":"https://api.github.com/users/matteodem/following{/other_user}","gists_url":"https://api.github.com/users/matteodem/gists{/gist_id}","starred_url":"https://api.github.com/users/matteodem/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/matteodem/subscriptions","organizations_url":"https://api.github.com/users/matteodem/orgs","repos_url":"https://api.github.com/users/matteodem/repos","events_url":"https://api.github.com/users/matteodem/events{/privacy}","received_events_url":"https://api.github.com/users/matteodem/received_events","type":"User","site_admin":false},"created_at":"2016-05-02T08:32:53Z","updated_at":"2016-05-02T08:32:53Z","body":"I'll close this story then as the leaderboard uses about 30k documents and seems to handle it very well too with v2."}}