{"action":"closed","issue":{"url":"https://api.github.com/repos/npm/newww/issues/475","labels_url":"https://api.github.com/repos/npm/newww/issues/475/labels{/name}","comments_url":"https://api.github.com/repos/npm/newww/issues/475/comments","events_url":"https://api.github.com/repos/npm/newww/issues/475/events","html_url":"https://github.com/npm/newww/issues/475","id":53074044,"number":475,"title":"timeouts when loading CouchDB views on home-page","user":{"login":"bcoe","id":194609,"avatar_url":"https://avatars.githubusercontent.com/u/194609?v=3","gravatar_id":"","url":"https://api.github.com/users/bcoe","html_url":"https://github.com/bcoe","followers_url":"https://api.github.com/users/bcoe/followers","following_url":"https://api.github.com/users/bcoe/following{/other_user}","gists_url":"https://api.github.com/users/bcoe/gists{/gist_id}","starred_url":"https://api.github.com/users/bcoe/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bcoe/subscriptions","organizations_url":"https://api.github.com/users/bcoe/orgs","repos_url":"https://api.github.com/users/bcoe/repos","events_url":"https://api.github.com/users/bcoe/events{/privacy}","received_events_url":"https://api.github.com/users/bcoe/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/npm/newww/labels/bug","name":"bug","color":"fc2929"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2014-12-29T21:41:10Z","updated_at":"2015-02-23T21:57:20Z","closed_at":"2015-02-23T21:57:20Z","body":"We were running into a bug with Catbox, causing CouchDB views to timeout on the homepage. Observed behavior:\r\n\r\n* After a few days of operation, the front-page would start timing out on `recently-updated-packages`.\r\n* We added a repl, and isolated this issue to a timeout in the cached method `registry.getUpdated`.\r\n* If we varied the parameters being passed to `registry.getUpdated`, e.g., asking for 13 packages, rather than 12 packages, the timeout does not occur. This suggests to me that the problem relates to a bad cached value for the specific endpoint.\r\n* We tried clearing the redis-cache, which does not solve the problem, the bad state seems to be stored in the running process itself.\r\n* We patched the problem over the holidays by circumventing the Catbox cache, which has solved the issue (further pointing towards the cache as the culprit):\r\n\r\nhttps://github.com/npm/newww/commit/88b16bead1dbbba2f63cb8bc27bdc0289fcad1ce"}}