{"action":"closed","number":23,"pull_request":{"url":"https://api.github.com/repos/closeio/nylas/pulls/23","id":183554133,"html_url":"https://github.com/closeio/nylas/pull/23","diff_url":"https://github.com/closeio/nylas/pull/23.diff","patch_url":"https://github.com/closeio/nylas/pull/23.patch","issue_url":"https://api.github.com/repos/closeio/nylas/issues/23","number":23,"state":"closed","locked":false,"title":"Add index for cursor queries","user":{"login":"jkemp101","id":3944676,"avatar_url":"https://avatars0.githubusercontent.com/u/3944676?v=4","gravatar_id":"","url":"https://api.github.com/users/jkemp101","html_url":"https://github.com/jkemp101","followers_url":"https://api.github.com/users/jkemp101/followers","following_url":"https://api.github.com/users/jkemp101/following{/other_user}","gists_url":"https://api.github.com/users/jkemp101/gists{/gist_id}","starred_url":"https://api.github.com/users/jkemp101/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jkemp101/subscriptions","organizations_url":"https://api.github.com/users/jkemp101/orgs","repos_url":"https://api.github.com/users/jkemp101/repos","events_url":"https://api.github.com/users/jkemp101/events{/privacy}","received_events_url":"https://api.github.com/users/jkemp101/received_events","type":"User","site_admin":false},"body":"This is an optimized index to handle the SQL query generated by the get cursor API request.  The SQL looks like this:\r\n\r\n```sql\r\nSELECT transaction.public_id AS transaction_public_id, transaction.created_at AS transaction_created_at, transaction.id AS transaction_id, transaction.namespace_id AS transaction_namespace_id, transaction.object_type AS transaction_object_type, transaction.record_id AS transaction_record_id, transaction.object_public_id AS transaction_object_public_id, transaction.command AS transaction_command \r\nFROM transaction ignore index (ix_transaction_namespace_id_object_type_id)\r\nWHERE transaction.id > 117212893 AND transaction.namespace_id = 999 AND transaction.object_type NOT IN ('folder', 'metadata', 'account', 'label') ORDER BY transaction.id ASC \r\nLIMIT 250\r\n```\r\n\r\n```create index ix_transaction_namespace_id_object_type_id on transaction (namespace_id, object_type, id)```","created_at":"2018-04-23T20:52:35Z","updated_at":"2018-05-04T10:46:47Z","closed_at":"2018-05-04T10:46:47Z","merged_at":"2018-05-04T10:46:47Z","merge_commit_sha":"c0f94b2bec276774f5ed6b3e27668c8a2233a886","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/closeio/nylas/pulls/23/commits","review_comments_url":"https://api.github.com/repos/closeio/nylas/pulls/23/comments","review_comment_url":"https://api.github.com/repos/closeio/nylas/pulls/comments{/number}","comments_url":"https://api.github.com/repos/closeio/nylas/issues/23/comments","statuses_url":"https://api.github.com/repos/closeio/nylas/statuses/e9cd364072717f2ea8aff50a767726e90e75b4e5","head":{"label":"closeio:get-cursor-index","ref":"get-cursor-index","sha":"e9cd364072717f2ea8aff50a767726e90e75b4e5","user":{"login":"closeio","id":437267,"avatar_url":"https://avatars1.githubusercontent.com/u/437267?v=4","gravatar_id":"","url":"https://api.github.com/users/closeio","html_url":"https://github.com/closeio","followers_url":"https://api.github.com/users/closeio/followers","following_url":"https://api.github.com/users/closeio/following{/other_user}","gists_url":"https://api.github.com/users/closeio/gists{/gist_id}","starred_url":"https://api.github.com/users/closeio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/closeio/subscriptions","organizations_url":"https://api.github.com/users/closeio/orgs","repos_url":"https://api.github.com/users/closeio/repos","events_url":"https://api.github.com/users/closeio/events{/privacy}","received_events_url":"https://api.github.com/users/closeio/received_events","type":"Organization","site_admin":false},"repo":{"id":31797159,"name":"nylas","full_name":"closeio/nylas","owner":{"login":"closeio","id":437267,"avatar_url":"https://avatars1.githubusercontent.com/u/437267?v=4","gravatar_id":"","url":"https://api.github.com/users/closeio","html_url":"https://github.com/closeio","followers_url":"https://api.github.com/users/closeio/followers","following_url":"https://api.github.com/users/closeio/following{/other_user}","gists_url":"https://api.github.com/users/closeio/gists{/gist_id}","starred_url":"https://api.github.com/users/closeio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/closeio/subscriptions","organizations_url":"https://api.github.com/users/closeio/orgs","repos_url":"https://api.github.com/users/closeio/repos","events_url":"https://api.github.com/users/closeio/events{/privacy}","received_events_url":"https://api.github.com/users/closeio/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/closeio/nylas","description":"Nylas — the next-generation email platform","fork":true,"url":"https://api.github.com/repos/closeio/nylas","forks_url":"https://api.github.com/repos/closeio/nylas/forks","keys_url":"https://api.github.com/repos/closeio/nylas/keys{/key_id}","collaborators_url":"https://api.github.com/repos/closeio/nylas/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/closeio/nylas/teams","hooks_url":"https://api.github.com/repos/closeio/nylas/hooks","issue_events_url":"https://api.github.com/repos/closeio/nylas/issues/events{/number}","events_url":"https://api.github.com/repos/closeio/nylas/events","assignees_url":"https://api.github.com/repos/closeio/nylas/assignees{/user}","branches_url":"https://api.github.com/repos/closeio/nylas/branches{/branch}","tags_url":"https://api.github.com/repos/closeio/nylas/tags","blobs_url":"https://api.github.com/repos/closeio/nylas/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/closeio/nylas/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/closeio/nylas/git/refs{/sha}","trees_url":"https://api.github.com/repos/closeio/nylas/git/trees{/sha}","statuses_url":"https://api.github.com/repos/closeio/nylas/statuses/{sha}","languages_url":"https://api.github.com/repos/closeio/nylas/languages","stargazers_url":"https://api.github.com/repos/closeio/nylas/stargazers","contributors_url":"https://api.github.com/repos/closeio/nylas/contributors","subscribers_url":"https://api.github.com/repos/closeio/nylas/subscribers","subscription_url":"https://api.github.com/repos/closeio/nylas/subscription","commits_url":"https://api.github.com/repos/closeio/nylas/commits{/sha}","git_commits_url":"https://api.github.com/repos/closeio/nylas/git/commits{/sha}","comments_url":"https://api.github.com/repos/closeio/nylas/comments{/number}","issue_comment_url":"https://api.github.com/repos/closeio/nylas/issues/comments{/number}","contents_url":"https://api.github.com/repos/closeio/nylas/contents/{+path}","compare_url":"https://api.github.com/repos/closeio/nylas/compare/{base}...{head}","merges_url":"https://api.github.com/repos/closeio/nylas/merges","archive_url":"https://api.github.com/repos/closeio/nylas/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/closeio/nylas/downloads","issues_url":"https://api.github.com/repos/closeio/nylas/issues{/number}","pulls_url":"https://api.github.com/repos/closeio/nylas/pulls{/number}","milestones_url":"https://api.github.com/repos/closeio/nylas/milestones{/number}","notifications_url":"https://api.github.com/repos/closeio/nylas/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/closeio/nylas/labels{/name}","releases_url":"https://api.github.com/repos/closeio/nylas/releases{/id}","deployments_url":"https://api.github.com/repos/closeio/nylas/deployments","created_at":"2015-03-07T01:38:00Z","updated_at":"2018-05-03T15:20:53Z","pushed_at":"2018-05-04T10:46:47Z","git_url":"git://github.com/closeio/nylas.git","ssh_url":"git@github.com:closeio/nylas.git","clone_url":"https://github.com/closeio/nylas.git","svn_url":"https://github.com/closeio/nylas","homepage":"https://www.nylas.com","size":20216,"stargazers_count":3,"watchers_count":3,"language":"Python","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":{"key":"agpl-3.0","name":"GNU Affero General Public License v3.0","spdx_id":"AGPL-3.0","url":"https://api.github.com/licenses/agpl-3.0"},"forks":0,"open_issues":1,"watchers":3,"default_branch":"n17"}},"base":{"label":"closeio:n17","ref":"n17","sha":"3ecc0ecb501318e268c3f7ca0b9b2dbd1e47dddd","user":{"login":"closeio","id":437267,"avatar_url":"https://avatars1.githubusercontent.com/u/437267?v=4","gravatar_id":"","url":"https://api.github.com/users/closeio","html_url":"https://github.com/closeio","followers_url":"https://api.github.com/users/closeio/followers","following_url":"https://api.github.com/users/closeio/following{/other_user}","gists_url":"https://api.github.com/users/closeio/gists{/gist_id}","starred_url":"https://api.github.com/users/closeio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/closeio/subscriptions","organizations_url":"https://api.github.com/users/closeio/orgs","repos_url":"https://api.github.com/users/closeio/repos","events_url":"https://api.github.com/users/closeio/events{/privacy}","received_events_url":"https://api.github.com/users/closeio/received_events","type":"Organization","site_admin":false},"repo":{"id":31797159,"name":"nylas","full_name":"closeio/nylas","owner":{"login":"closeio","id":437267,"avatar_url":"https://avatars1.githubusercontent.com/u/437267?v=4","gravatar_id":"","url":"https://api.github.com/users/closeio","html_url":"https://github.com/closeio","followers_url":"https://api.github.com/users/closeio/followers","following_url":"https://api.github.com/users/closeio/following{/other_user}","gists_url":"https://api.github.com/users/closeio/gists{/gist_id}","starred_url":"https://api.github.com/users/closeio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/closeio/subscriptions","organizations_url":"https://api.github.com/users/closeio/orgs","repos_url":"https://api.github.com/users/closeio/repos","events_url":"https://api.github.com/users/closeio/events{/privacy}","received_events_url":"https://api.github.com/users/closeio/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/closeio/nylas","description":"Nylas — the next-generation email platform","fork":true,"url":"https://api.github.com/repos/closeio/nylas","forks_url":"https://api.github.com/repos/closeio/nylas/forks","keys_url":"https://api.github.com/repos/closeio/nylas/keys{/key_id}","collaborators_url":"https://api.github.com/repos/closeio/nylas/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/closeio/nylas/teams","hooks_url":"https://api.github.com/repos/closeio/nylas/hooks","issue_events_url":"https://api.github.com/repos/closeio/nylas/issues/events{/number}","events_url":"https://api.github.com/repos/closeio/nylas/events","assignees_url":"https://api.github.com/repos/closeio/nylas/assignees{/user}","branches_url":"https://api.github.com/repos/closeio/nylas/branches{/branch}","tags_url":"https://api.github.com/repos/closeio/nylas/tags","blobs_url":"https://api.github.com/repos/closeio/nylas/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/closeio/nylas/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/closeio/nylas/git/refs{/sha}","trees_url":"https://api.github.com/repos/closeio/nylas/git/trees{/sha}","statuses_url":"https://api.github.com/repos/closeio/nylas/statuses/{sha}","languages_url":"https://api.github.com/repos/closeio/nylas/languages","stargazers_url":"https://api.github.com/repos/closeio/nylas/stargazers","contributors_url":"https://api.github.com/repos/closeio/nylas/contributors","subscribers_url":"https://api.github.com/repos/closeio/nylas/subscribers","subscription_url":"https://api.github.com/repos/closeio/nylas/subscription","commits_url":"https://api.github.com/repos/closeio/nylas/commits{/sha}","git_commits_url":"https://api.github.com/repos/closeio/nylas/git/commits{/sha}","comments_url":"https://api.github.com/repos/closeio/nylas/comments{/number}","issue_comment_url":"https://api.github.com/repos/closeio/nylas/issues/comments{/number}","contents_url":"https://api.github.com/repos/closeio/nylas/contents/{+path}","compare_url":"https://api.github.com/repos/closeio/nylas/compare/{base}...{head}","merges_url":"https://api.github.com/repos/closeio/nylas/merges","archive_url":"https://api.github.com/repos/closeio/nylas/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/closeio/nylas/downloads","issues_url":"https://api.github.com/repos/closeio/nylas/issues{/number}","pulls_url":"https://api.github.com/repos/closeio/nylas/pulls{/number}","milestones_url":"https://api.github.com/repos/closeio/nylas/milestones{/number}","notifications_url":"https://api.github.com/repos/closeio/nylas/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/closeio/nylas/labels{/name}","releases_url":"https://api.github.com/repos/closeio/nylas/releases{/id}","deployments_url":"https://api.github.com/repos/closeio/nylas/deployments","created_at":"2015-03-07T01:38:00Z","updated_at":"2018-05-03T15:20:53Z","pushed_at":"2018-05-04T10:46:47Z","git_url":"git://github.com/closeio/nylas.git","ssh_url":"git@github.com:closeio/nylas.git","clone_url":"https://github.com/closeio/nylas.git","svn_url":"https://github.com/closeio/nylas","homepage":"https://www.nylas.com","size":20216,"stargazers_count":3,"watchers_count":3,"language":"Python","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":{"key":"agpl-3.0","name":"GNU Affero General Public License v3.0","spdx_id":"AGPL-3.0","url":"https://api.github.com/licenses/agpl-3.0"},"forks":0,"open_issues":1,"watchers":3,"default_branch":"n17"}},"_links":{"self":{"href":"https://api.github.com/repos/closeio/nylas/pulls/23"},"html":{"href":"https://github.com/closeio/nylas/pull/23"},"issue":{"href":"https://api.github.com/repos/closeio/nylas/issues/23"},"comments":{"href":"https://api.github.com/repos/closeio/nylas/issues/23/comments"},"review_comments":{"href":"https://api.github.com/repos/closeio/nylas/pulls/23/comments"},"review_comment":{"href":"https://api.github.com/repos/closeio/nylas/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/closeio/nylas/pulls/23/commits"},"statuses":{"href":"https://api.github.com/repos/closeio/nylas/statuses/e9cd364072717f2ea8aff50a767726e90e75b4e5"}},"author_association":"NONE","merged":true,"mergeable":null,"rebaseable":null,"mergeable_state":"unknown","merged_by":{"login":"jkemp101","id":3944676,"avatar_url":"https://avatars0.githubusercontent.com/u/3944676?v=4","gravatar_id":"","url":"https://api.github.com/users/jkemp101","html_url":"https://github.com/jkemp101","followers_url":"https://api.github.com/users/jkemp101/followers","following_url":"https://api.github.com/users/jkemp101/following{/other_user}","gists_url":"https://api.github.com/users/jkemp101/gists{/gist_id}","starred_url":"https://api.github.com/users/jkemp101/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jkemp101/subscriptions","organizations_url":"https://api.github.com/users/jkemp101/orgs","repos_url":"https://api.github.com/users/jkemp101/repos","events_url":"https://api.github.com/users/jkemp101/events{/privacy}","received_events_url":"https://api.github.com/users/jkemp101/received_events","type":"User","site_admin":false},"comments":0,"review_comments":0,"maintainer_can_modify":false,"commits":1,"additions":25,"deletions":0,"changed_files":2}}
{"actor":{"display_login":"jkemp101"}}