{"action":"closed","number":330,"pull_request":{"url":"https://api.github.com/repos/Financial-Times/next-front-page/pulls/330","id":48750935,"html_url":"https://github.com/Financial-Times/next-front-page/pull/330","diff_url":"https://github.com/Financial-Times/next-front-page/pull/330.diff","patch_url":"https://github.com/Financial-Times/next-front-page/pull/330.patch","issue_url":"https://api.github.com/repos/Financial-Times/next-front-page/issues/330","number":330,"state":"closed","locked":false,"title":"Poll graphql for data","user":{"login":"adgad","id":1978880,"avatar_url":"https://avatars.githubusercontent.com/u/1978880?v=3","gravatar_id":"","url":"https://api.github.com/users/adgad","html_url":"https://github.com/adgad","followers_url":"https://api.github.com/users/adgad/followers","following_url":"https://api.github.com/users/adgad/following{/other_user}","gists_url":"https://api.github.com/users/adgad/gists{/gist_id}","starred_url":"https://api.github.com/users/adgad/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adgad/subscriptions","organizations_url":"https://api.github.com/users/adgad/orgs","repos_url":"https://api.github.com/users/adgad/repos","events_url":"https://api.github.com/users/adgad/events{/privacy}","received_events_url":"https://api.github.com/users/adgad/received_events","type":"User","site_admin":false},"body":"/cc @matthew-andrews @charypar @ironsidevsquincy @andygout \r\nPolls graphql every minute for front page data, instead of on request.\r\n\r\n* ~~`app.listen` and healthcheck polling waits for initial fetch to complete before starting. If we fail to get content on startup, then the app will not start up (and build won't pass etc).~~ Decided not to do this: if heroku restarts but fails to get any content, the new app won't ever start listening. \r\n* Stale polled content will remain in memory indefinitely (until the app next restarts) - with healthchecks that escalate as the content gets 10/30 minutes out of date. \r\n* Added a US top stories healthcheck\r\n* Set caching for FastFT Json to same as front page HTML (to cache on Fastly and stale on error)\r\n\r\nTODO\r\n- [x] Get mockFrontPage working\r\n- [x] Check error handling\r\n- [x] Add healthcheck that checks the freshness of content","created_at":"2015-10-26T15:05:43Z","updated_at":"2015-10-28T10:36:09Z","closed_at":"2015-10-28T10:36:09Z","merged_at":"2015-10-28T10:36:09Z","merge_commit_sha":"257f91a98dc5fc599be9379f8c8020e5580052ed","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/Financial-Times/next-front-page/pulls/330/commits","review_comments_url":"https://api.github.com/repos/Financial-Times/next-front-page/pulls/330/comments","review_comment_url":"https://api.github.com/repos/Financial-Times/next-front-page/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Financial-Times/next-front-page/issues/330/comments","statuses_url":"https://api.github.com/repos/Financial-Times/next-front-page/statuses/3c7e2ce1a5337459e42ce9fc7d4c81598d037b24","head":{"label":"Financial-Times:poller","ref":"poller","sha":"3c7e2ce1a5337459e42ce9fc7d4c81598d037b24","user":{"login":"Financial-Times","id":3502508,"avatar_url":"https://avatars.githubusercontent.com/u/3502508?v=3","gravatar_id":"","url":"https://api.github.com/users/Financial-Times","html_url":"https://github.com/Financial-Times","followers_url":"https://api.github.com/users/Financial-Times/followers","following_url":"https://api.github.com/users/Financial-Times/following{/other_user}","gists_url":"https://api.github.com/users/Financial-Times/gists{/gist_id}","starred_url":"https://api.github.com/users/Financial-Times/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Financial-Times/subscriptions","organizations_url":"https://api.github.com/users/Financial-Times/orgs","repos_url":"https://api.github.com/users/Financial-Times/repos","events_url":"https://api.github.com/users/Financial-Times/events{/privacy}","received_events_url":"https://api.github.com/users/Financial-Times/received_events","type":"Organization","site_admin":false},"repo":{"id":37079565,"name":"next-front-page","full_name":"Financial-Times/next-front-page","owner":{"login":"Financial-Times","id":3502508,"avatar_url":"https://avatars.githubusercontent.com/u/3502508?v=3","gravatar_id":"","url":"https://api.github.com/users/Financial-Times","html_url":"https://github.com/Financial-Times","followers_url":"https://api.github.com/users/Financial-Times/followers","following_url":"https://api.github.com/users/Financial-Times/following{/other_user}","gists_url":"https://api.github.com/users/Financial-Times/gists{/gist_id}","starred_url":"https://api.github.com/users/Financial-Times/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Financial-Times/subscriptions","organizations_url":"https://api.github.com/users/Financial-Times/orgs","repos_url":"https://api.github.com/users/Financial-Times/repos","events_url":"https://api.github.com/users/Financial-Times/events{/privacy}","received_events_url":"https://api.github.com/users/Financial-Times/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Financial-Times/next-front-page","description":"Next FT front page","fork":false,"url":"https://api.github.com/repos/Financial-Times/next-front-page","forks_url":"https://api.github.com/repos/Financial-Times/next-front-page/forks","keys_url":"https://api.github.com/repos/Financial-Times/next-front-page/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Financial-Times/next-front-page/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Financial-Times/next-front-page/teams","hooks_url":"https://api.github.com/repos/Financial-Times/next-front-page/hooks","issue_events_url":"https://api.github.com/repos/Financial-Times/next-front-page/issues/events{/number}","events_url":"https://api.github.com/repos/Financial-Times/next-front-page/events","assignees_url":"https://api.github.com/repos/Financial-Times/next-front-page/assignees{/user}","branches_url":"https://api.github.com/repos/Financial-Times/next-front-page/branches{/branch}","tags_url":"https://api.github.com/repos/Financial-Times/next-front-page/tags","blobs_url":"https://api.github.com/repos/Financial-Times/next-front-page/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Financial-Times/next-front-page/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Financial-Times/next-front-page/git/refs{/sha}","trees_url":"https://api.github.com/repos/Financial-Times/next-front-page/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Financial-Times/next-front-page/statuses/{sha}","languages_url":"https://api.github.com/repos/Financial-Times/next-front-page/languages","stargazers_url":"https://api.github.com/repos/Financial-Times/next-front-page/stargazers","contributors_url":"https://api.github.com/repos/Financial-Times/next-front-page/contributors","subscribers_url":"https://api.github.com/repos/Financial-Times/next-front-page/subscribers","subscription_url":"https://api.github.com/repos/Financial-Times/next-front-page/subscription","commits_url":"https://api.github.com/repos/Financial-Times/next-front-page/commits{/sha}","git_commits_url":"https://api.github.com/repos/Financial-Times/next-front-page/git/commits{/sha}","comments_url":"https://api.github.com/repos/Financial-Times/next-front-page/comments{/number}","issue_comment_url":"https://api.github.com/repos/Financial-Times/next-front-page/issues/comments{/number}","contents_url":"https://api.github.com/repos/Financial-Times/next-front-page/contents/{+path}","compare_url":"https://api.github.com/repos/Financial-Times/next-front-page/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Financial-Times/next-front-page/merges","archive_url":"https://api.github.com/repos/Financial-Times/next-front-page/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Financial-Times/next-front-page/downloads","issues_url":"https://api.github.com/repos/Financial-Times/next-front-page/issues{/number}","pulls_url":"https://api.github.com/repos/Financial-Times/next-front-page/pulls{/number}","milestones_url":"https://api.github.com/repos/Financial-Times/next-front-page/milestones{/number}","notifications_url":"https://api.github.com/repos/Financial-Times/next-front-page/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Financial-Times/next-front-page/labels{/name}","releases_url":"https://api.github.com/repos/Financial-Times/next-front-page/releases{/id}","created_at":"2015-06-08T16:43:12Z","updated_at":"2015-10-27T10:03:40Z","pushed_at":"2015-10-28T10:36:09Z","git_url":"git://github.com/Financial-Times/next-front-page.git","ssh_url":"git@github.com:Financial-Times/next-front-page.git","clone_url":"https://github.com/Financial-Times/next-front-page.git","svn_url":"https://github.com/Financial-Times/next-front-page","homepage":"","size":2675,"stargazers_count":24,"watchers_count":24,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":3,"mirror_url":null,"open_issues_count":22,"forks":3,"open_issues":22,"watchers":24,"default_branch":"master"}},"base":{"label":"Financial-Times:master","ref":"master","sha":"9cb867570ae2216a3abc574bef6def4ee08d9b52","user":{"login":"Financial-Times","id":3502508,"avatar_url":"https://avatars.githubusercontent.com/u/3502508?v=3","gravatar_id":"","url":"https://api.github.com/users/Financial-Times","html_url":"https://github.com/Financial-Times","followers_url":"https://api.github.com/users/Financial-Times/followers","following_url":"https://api.github.com/users/Financial-Times/following{/other_user}","gists_url":"https://api.github.com/users/Financial-Times/gists{/gist_id}","starred_url":"https://api.github.com/users/Financial-Times/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Financial-Times/subscriptions","organizations_url":"https://api.github.com/users/Financial-Times/orgs","repos_url":"https://api.github.com/users/Financial-Times/repos","events_url":"https://api.github.com/users/Financial-Times/events{/privacy}","received_events_url":"https://api.github.com/users/Financial-Times/received_events","type":"Organization","site_admin":false},"repo":{"id":37079565,"name":"next-front-page","full_name":"Financial-Times/next-front-page","owner":{"login":"Financial-Times","id":3502508,"avatar_url":"https://avatars.githubusercontent.com/u/3502508?v=3","gravatar_id":"","url":"https://api.github.com/users/Financial-Times","html_url":"https://github.com/Financial-Times","followers_url":"https://api.github.com/users/Financial-Times/followers","following_url":"https://api.github.com/users/Financial-Times/following{/other_user}","gists_url":"https://api.github.com/users/Financial-Times/gists{/gist_id}","starred_url":"https://api.github.com/users/Financial-Times/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Financial-Times/subscriptions","organizations_url":"https://api.github.com/users/Financial-Times/orgs","repos_url":"https://api.github.com/users/Financial-Times/repos","events_url":"https://api.github.com/users/Financial-Times/events{/privacy}","received_events_url":"https://api.github.com/users/Financial-Times/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Financial-Times/next-front-page","description":"Next FT front page","fork":false,"url":"https://api.github.com/repos/Financial-Times/next-front-page","forks_url":"https://api.github.com/repos/Financial-Times/next-front-page/forks","keys_url":"https://api.github.com/repos/Financial-Times/next-front-page/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Financial-Times/next-front-page/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Financial-Times/next-front-page/teams","hooks_url":"https://api.github.com/repos/Financial-Times/next-front-page/hooks","issue_events_url":"https://api.github.com/repos/Financial-Times/next-front-page/issues/events{/number}","events_url":"https://api.github.com/repos/Financial-Times/next-front-page/events","assignees_url":"https://api.github.com/repos/Financial-Times/next-front-page/assignees{/user}","branches_url":"https://api.github.com/repos/Financial-Times/next-front-page/branches{/branch}","tags_url":"https://api.github.com/repos/Financial-Times/next-front-page/tags","blobs_url":"https://api.github.com/repos/Financial-Times/next-front-page/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Financial-Times/next-front-page/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Financial-Times/next-front-page/git/refs{/sha}","trees_url":"https://api.github.com/repos/Financial-Times/next-front-page/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Financial-Times/next-front-page/statuses/{sha}","languages_url":"https://api.github.com/repos/Financial-Times/next-front-page/languages","stargazers_url":"https://api.github.com/repos/Financial-Times/next-front-page/stargazers","contributors_url":"https://api.github.com/repos/Financial-Times/next-front-page/contributors","subscribers_url":"https://api.github.com/repos/Financial-Times/next-front-page/subscribers","subscription_url":"https://api.github.com/repos/Financial-Times/next-front-page/subscription","commits_url":"https://api.github.com/repos/Financial-Times/next-front-page/commits{/sha}","git_commits_url":"https://api.github.com/repos/Financial-Times/next-front-page/git/commits{/sha}","comments_url":"https://api.github.com/repos/Financial-Times/next-front-page/comments{/number}","issue_comment_url":"https://api.github.com/repos/Financial-Times/next-front-page/issues/comments{/number}","contents_url":"https://api.github.com/repos/Financial-Times/next-front-page/contents/{+path}","compare_url":"https://api.github.com/repos/Financial-Times/next-front-page/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Financial-Times/next-front-page/merges","archive_url":"https://api.github.com/repos/Financial-Times/next-front-page/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Financial-Times/next-front-page/downloads","issues_url":"https://api.github.com/repos/Financial-Times/next-front-page/issues{/number}","pulls_url":"https://api.github.com/repos/Financial-Times/next-front-page/pulls{/number}","milestones_url":"https://api.github.com/repos/Financial-Times/next-front-page/milestones{/number}","notifications_url":"https://api.github.com/repos/Financial-Times/next-front-page/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Financial-Times/next-front-page/labels{/name}","releases_url":"https://api.github.com/repos/Financial-Times/next-front-page/releases{/id}","created_at":"2015-06-08T16:43:12Z","updated_at":"2015-10-27T10:03:40Z","pushed_at":"2015-10-28T10:36:09Z","git_url":"git://github.com/Financial-Times/next-front-page.git","ssh_url":"git@github.com:Financial-Times/next-front-page.git","clone_url":"https://github.com/Financial-Times/next-front-page.git","svn_url":"https://github.com/Financial-Times/next-front-page","homepage":"","size":2675,"stargazers_count":24,"watchers_count":24,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":3,"mirror_url":null,"open_issues_count":22,"forks":3,"open_issues":22,"watchers":24,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Financial-Times/next-front-page/pulls/330"},"html":{"href":"https://github.com/Financial-Times/next-front-page/pull/330"},"issue":{"href":"https://api.github.com/repos/Financial-Times/next-front-page/issues/330"},"comments":{"href":"https://api.github.com/repos/Financial-Times/next-front-page/issues/330/comments"},"review_comments":{"href":"https://api.github.com/repos/Financial-Times/next-front-page/pulls/330/comments"},"review_comment":{"href":"https://api.github.com/repos/Financial-Times/next-front-page/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Financial-Times/next-front-page/pulls/330/commits"},"statuses":{"href":"https://api.github.com/repos/Financial-Times/next-front-page/statuses/3c7e2ce1a5337459e42ce9fc7d4c81598d037b24"}},"merged":true,"mergeable":null,"mergeable_state":"unknown","merged_by":{"login":"adgad","id":1978880,"avatar_url":"https://avatars.githubusercontent.com/u/1978880?v=3","gravatar_id":"","url":"https://api.github.com/users/adgad","html_url":"https://github.com/adgad","followers_url":"https://api.github.com/users/adgad/followers","following_url":"https://api.github.com/users/adgad/following{/other_user}","gists_url":"https://api.github.com/users/adgad/gists{/gist_id}","starred_url":"https://api.github.com/users/adgad/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adgad/subscriptions","organizations_url":"https://api.github.com/users/adgad/orgs","repos_url":"https://api.github.com/users/adgad/repos","events_url":"https://api.github.com/users/adgad/events{/privacy}","received_events_url":"https://api.github.com/users/adgad/received_events","type":"User","site_admin":false},"comments":1,"review_comments":3,"commits":9,"additions":254,"deletions":214,"changed_files":8}}