{"action":"created","comment":{"url":"https://api.github.com/repos/pivotalsoftware/quickstep/pulls/comments/58481769","id":58481769,"diff_hunk":"@@ -252,15 +253,15 @@ class ForemanTest : public ::testing::Test {\n   }\n \n   inline const int getNumWorkOrdersInExecution(const QueryPlan::DAGNodeIndex index) const {\n-    return foreman_->queued_workorders_per_op_[index];\n+    return foreman_->query_exec_state_->getNumQueuedWorkOrders(index);","path":"query_execution/tests/Foreman_unittest.cpp","position":13,"original_position":13,"commit_id":"6d1c1198ff14a3886abbc8c0e317260f1a5d0ba1","original_commit_id":"6d1c1198ff14a3886abbc8c0e317260f1a5d0ba1","user":{"login":"zuyu","id":2245572,"avatar_url":"https://avatars.githubusercontent.com/u/2245572?v=3","gravatar_id":"","url":"https://api.github.com/users/zuyu","html_url":"https://github.com/zuyu","followers_url":"https://api.github.com/users/zuyu/followers","following_url":"https://api.github.com/users/zuyu/following{/other_user}","gists_url":"https://api.github.com/users/zuyu/gists{/gist_id}","starred_url":"https://api.github.com/users/zuyu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zuyu/subscriptions","organizations_url":"https://api.github.com/users/zuyu/orgs","repos_url":"https://api.github.com/users/zuyu/repos","events_url":"https://api.github.com/users/zuyu/events{/privacy}","received_events_url":"https://api.github.com/users/zuyu/received_events","type":"User","site_admin":false},"body":"Remove the unnecessary `foreman_->` here and below, as this is a friend class of `Foreman`.","created_at":"2016-04-05T03:15:16Z","updated_at":"2016-04-05T03:15:16Z","html_url":"https://github.com/pivotalsoftware/quickstep/pull/119#discussion_r58481769","pull_request_url":"https://api.github.com/repos/pivotalsoftware/quickstep/pulls/119","_links":{"self":{"href":"https://api.github.com/repos/pivotalsoftware/quickstep/pulls/comments/58481769"},"html":{"href":"https://github.com/pivotalsoftware/quickstep/pull/119#discussion_r58481769"},"pull_request":{"href":"https://api.github.com/repos/pivotalsoftware/quickstep/pulls/119"}}},"pull_request":{"url":"https://api.github.com/repos/pivotalsoftware/quickstep/pulls/119","id":65184830,"html_url":"https://github.com/pivotalsoftware/quickstep/pull/119","diff_url":"https://github.com/pivotalsoftware/quickstep/pull/119.diff","patch_url":"https://github.com/pivotalsoftware/quickstep/pull/119.patch","issue_url":"https://api.github.com/repos/pivotalsoftware/quickstep/issues/119","number":119,"state":"open","locked":false,"title":"Query Execution State ","user":{"login":"hbdeshmukh","id":3750801,"avatar_url":"https://avatars.githubusercontent.com/u/3750801?v=3","gravatar_id":"","url":"https://api.github.com/users/hbdeshmukh","html_url":"https://github.com/hbdeshmukh","followers_url":"https://api.github.com/users/hbdeshmukh/followers","following_url":"https://api.github.com/users/hbdeshmukh/following{/other_user}","gists_url":"https://api.github.com/users/hbdeshmukh/gists{/gist_id}","starred_url":"https://api.github.com/users/hbdeshmukh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hbdeshmukh/subscriptions","organizations_url":"https://api.github.com/users/hbdeshmukh/orgs","repos_url":"https://api.github.com/users/hbdeshmukh/repos","events_url":"https://api.github.com/users/hbdeshmukh/events{/privacy}","received_events_url":"https://api.github.com/users/hbdeshmukh/received_events","type":"User","site_admin":false},"body":"This PR includes creation of a new class called ``QueryExecutionState``. The functionality of the class is related to book keeping of a query execution which inculdes:\r\n\r\n- Which operators in the DAG have finished their execution. \r\n- Whether an operator has produced all of its work orders.\r\n- Whether the execution of the query is over. \r\n- For an active operator, modifying and retrieving the number of work orders which have been dispatched and the number of work orders which have finished their execution.\r\n- Rebuild related information for the relevant operators. \r\n\r\nEarlier, all of the supporting data structures were private members of Foreman. Now they have been pulled out in the class ``QueryExecutionState``. As this class is fairly straightforward, and we had all of its functionality earlier in Foreman, I didn't write test cases for this class. \r\n\r\nThe next PR will be about ``QueryManager``, which moves all the functions about a query's execution from Foreman to a new class called ``QueryManager``. \r\n","created_at":"2016-04-04T17:48:04Z","updated_at":"2016-04-05T03:15:16Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d9109126df7ef69292528a8614773c488f51dd29","assignee":{"login":"jianqiao","id":2695519,"avatar_url":"https://avatars.githubusercontent.com/u/2695519?v=3","gravatar_id":"","url":"https://api.github.com/users/jianqiao","html_url":"https://github.com/jianqiao","followers_url":"https://api.github.com/users/jianqiao/followers","following_url":"https://api.github.com/users/jianqiao/following{/other_user}","gists_url":"https://api.github.com/users/jianqiao/gists{/gist_id}","starred_url":"https://api.github.com/users/jianqiao/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jianqiao/subscriptions","organizations_url":"https://api.github.com/users/jianqiao/orgs","repos_url":"https://api.github.com/users/jianqiao/repos","events_url":"https://api.github.com/users/jianqiao/events{/privacy}","received_events_url":"https://api.github.com/users/jianqiao/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/pivotalsoftware/quickstep/pulls/119/commits","review_comments_url":"https://api.github.com/repos/pivotalsoftware/quickstep/pulls/119/comments","review_comment_url":"https://api.github.com/repos/pivotalsoftware/quickstep/pulls/comments{/number}","comments_url":"https://api.github.com/repos/pivotalsoftware/quickstep/issues/119/comments","statuses_url":"https://api.github.com/repos/pivotalsoftware/quickstep/statuses/6d1c1198ff14a3886abbc8c0e317260f1a5d0ba1","head":{"label":"pivotalsoftware:query-exec-state","ref":"query-exec-state","sha":"6d1c1198ff14a3886abbc8c0e317260f1a5d0ba1","user":{"login":"pivotalsoftware","id":4247270,"avatar_url":"https://avatars.githubusercontent.com/u/4247270?v=3","gravatar_id":"","url":"https://api.github.com/users/pivotalsoftware","html_url":"https://github.com/pivotalsoftware","followers_url":"https://api.github.com/users/pivotalsoftware/followers","following_url":"https://api.github.com/users/pivotalsoftware/following{/other_user}","gists_url":"https://api.github.com/users/pivotalsoftware/gists{/gist_id}","starred_url":"https://api.github.com/users/pivotalsoftware/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pivotalsoftware/subscriptions","organizations_url":"https://api.github.com/users/pivotalsoftware/orgs","repos_url":"https://api.github.com/users/pivotalsoftware/repos","events_url":"https://api.github.com/users/pivotalsoftware/events{/privacy}","received_events_url":"https://api.github.com/users/pivotalsoftware/received_events","type":"Organization","site_admin":false},"repo":{"id":45578105,"name":"quickstep","full_name":"pivotalsoftware/quickstep","owner":{"login":"pivotalsoftware","id":4247270,"avatar_url":"https://avatars.githubusercontent.com/u/4247270?v=3","gravatar_id":"","url":"https://api.github.com/users/pivotalsoftware","html_url":"https://github.com/pivotalsoftware","followers_url":"https://api.github.com/users/pivotalsoftware/followers","following_url":"https://api.github.com/users/pivotalsoftware/following{/other_user}","gists_url":"https://api.github.com/users/pivotalsoftware/gists{/gist_id}","starred_url":"https://api.github.com/users/pivotalsoftware/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pivotalsoftware/subscriptions","organizations_url":"https://api.github.com/users/pivotalsoftware/orgs","repos_url":"https://api.github.com/users/pivotalsoftware/repos","events_url":"https://api.github.com/users/pivotalsoftware/events{/privacy}","received_events_url":"https://api.github.com/users/pivotalsoftware/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/pivotalsoftware/quickstep","description":"Quickstep Project","fork":false,"url":"https://api.github.com/repos/pivotalsoftware/quickstep","forks_url":"https://api.github.com/repos/pivotalsoftware/quickstep/forks","keys_url":"https://api.github.com/repos/pivotalsoftware/quickstep/keys{/key_id}","collaborators_url":"https://api.github.com/repos/pivotalsoftware/quickstep/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/pivotalsoftware/quickstep/teams","hooks_url":"https://api.github.com/repos/pivotalsoftware/quickstep/hooks","issue_events_url":"https://api.github.com/repos/pivotalsoftware/quickstep/issues/events{/number}","events_url":"https://api.github.com/repos/pivotalsoftware/quickstep/events","assignees_url":"https://api.github.com/repos/pivotalsoftware/quickstep/assignees{/user}","branches_url":"https://api.github.com/repos/pivotalsoftware/quickstep/branches{/branch}","tags_url":"https://api.github.com/repos/pivotalsoftware/quickstep/tags","blobs_url":"https://api.github.com/repos/pivotalsoftware/quickstep/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/pivotalsoftware/quickstep/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/pivotalsoftware/quickstep/git/refs{/sha}","trees_url":"https://api.github.com/repos/pivotalsoftware/quickstep/git/trees{/sha}","statuses_url":"https://api.github.com/repos/pivotalsoftware/quickstep/statuses/{sha}","languages_url":"https://api.github.com/repos/pivotalsoftware/quickstep/languages","stargazers_url":"https://api.github.com/repos/pivotalsoftware/quickstep/stargazers","contributors_url":"https://api.github.com/repos/pivotalsoftware/quickstep/contributors","subscribers_url":"https://api.github.com/repos/pivotalsoftware/quickstep/subscribers","subscription_url":"https://api.github.com/repos/pivotalsoftware/quickstep/subscription","commits_url":"https://api.github.com/repos/pivotalsoftware/quickstep/commits{/sha}","git_commits_url":"https://api.github.com/repos/pivotalsoftware/quickstep/git/commits{/sha}","comments_url":"https://api.github.com/repos/pivotalsoftware/quickstep/comments{/number}","issue_comment_url":"https://api.github.com/repos/pivotalsoftware/quickstep/issues/comments{/number}","contents_url":"https://api.github.com/repos/pivotalsoftware/quickstep/contents/{+path}","compare_url":"https://api.github.com/repos/pivotalsoftware/quickstep/compare/{base}...{head}","merges_url":"https://api.github.com/repos/pivotalsoftware/quickstep/merges","archive_url":"https://api.github.com/repos/pivotalsoftware/quickstep/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/pivotalsoftware/quickstep/downloads","issues_url":"https://api.github.com/repos/pivotalsoftware/quickstep/issues{/number}","pulls_url":"https://api.github.com/repos/pivotalsoftware/quickstep/pulls{/number}","milestones_url":"https://api.github.com/repos/pivotalsoftware/quickstep/milestones{/number}","notifications_url":"https://api.github.com/repos/pivotalsoftware/quickstep/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/pivotalsoftware/quickstep/labels{/name}","releases_url":"https://api.github.com/repos/pivotalsoftware/quickstep/releases{/id}","deployments_url":"https://api.github.com/repos/pivotalsoftware/quickstep/deployments","created_at":"2015-11-05T01:06:50Z","updated_at":"2016-03-30T04:28:05Z","pushed_at":"2016-04-05T01:23:21Z","git_url":"git://github.com/pivotalsoftware/quickstep.git","ssh_url":"git@github.com:pivotalsoftware/quickstep.git","clone_url":"https://github.com/pivotalsoftware/quickstep.git","svn_url":"https://github.com/pivotalsoftware/quickstep","homepage":null,"size":7901,"stargazers_count":14,"watchers_count":14,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":9,"mirror_url":null,"open_issues_count":17,"forks":9,"open_issues":17,"watchers":14,"default_branch":"master"}},"base":{"label":"pivotalsoftware:master","ref":"master","sha":"abbe75b8f32ac6e1af20fc8408753ec35cf6efaa","user":{"login":"pivotalsoftware","id":4247270,"avatar_url":"https://avatars.githubusercontent.com/u/4247270?v=3","gravatar_id":"","url":"https://api.github.com/users/pivotalsoftware","html_url":"https://github.com/pivotalsoftware","followers_url":"https://api.github.com/users/pivotalsoftware/followers","following_url":"https://api.github.com/users/pivotalsoftware/following{/other_user}","gists_url":"https://api.github.com/users/pivotalsoftware/gists{/gist_id}","starred_url":"https://api.github.com/users/pivotalsoftware/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pivotalsoftware/subscriptions","organizations_url":"https://api.github.com/users/pivotalsoftware/orgs","repos_url":"https://api.github.com/users/pivotalsoftware/repos","events_url":"https://api.github.com/users/pivotalsoftware/events{/privacy}","received_events_url":"https://api.github.com/users/pivotalsoftware/received_events","type":"Organization","site_admin":false},"repo":{"id":45578105,"name":"quickstep","full_name":"pivotalsoftware/quickstep","owner":{"login":"pivotalsoftware","id":4247270,"avatar_url":"https://avatars.githubusercontent.com/u/4247270?v=3","gravatar_id":"","url":"https://api.github.com/users/pivotalsoftware","html_url":"https://github.com/pivotalsoftware","followers_url":"https://api.github.com/users/pivotalsoftware/followers","following_url":"https://api.github.com/users/pivotalsoftware/following{/other_user}","gists_url":"https://api.github.com/users/pivotalsoftware/gists{/gist_id}","starred_url":"https://api.github.com/users/pivotalsoftware/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pivotalsoftware/subscriptions","organizations_url":"https://api.github.com/users/pivotalsoftware/orgs","repos_url":"https://api.github.com/users/pivotalsoftware/repos","events_url":"https://api.github.com/users/pivotalsoftware/events{/privacy}","received_events_url":"https://api.github.com/users/pivotalsoftware/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/pivotalsoftware/quickstep","description":"Quickstep Project","fork":false,"url":"https://api.github.com/repos/pivotalsoftware/quickstep","forks_url":"https://api.github.com/repos/pivotalsoftware/quickstep/forks","keys_url":"https://api.github.com/repos/pivotalsoftware/quickstep/keys{/key_id}","collaborators_url":"https://api.github.com/repos/pivotalsoftware/quickstep/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/pivotalsoftware/quickstep/teams","hooks_url":"https://api.github.com/repos/pivotalsoftware/quickstep/hooks","issue_events_url":"https://api.github.com/repos/pivotalsoftware/quickstep/issues/events{/number}","events_url":"https://api.github.com/repos/pivotalsoftware/quickstep/events","assignees_url":"https://api.github.com/repos/pivotalsoftware/quickstep/assignees{/user}","branches_url":"https://api.github.com/repos/pivotalsoftware/quickstep/branches{/branch}","tags_url":"https://api.github.com/repos/pivotalsoftware/quickstep/tags","blobs_url":"https://api.github.com/repos/pivotalsoftware/quickstep/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/pivotalsoftware/quickstep/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/pivotalsoftware/quickstep/git/refs{/sha}","trees_url":"https://api.github.com/repos/pivotalsoftware/quickstep/git/trees{/sha}","statuses_url":"https://api.github.com/repos/pivotalsoftware/quickstep/statuses/{sha}","languages_url":"https://api.github.com/repos/pivotalsoftware/quickstep/languages","stargazers_url":"https://api.github.com/repos/pivotalsoftware/quickstep/stargazers","contributors_url":"https://api.github.com/repos/pivotalsoftware/quickstep/contributors","subscribers_url":"https://api.github.com/repos/pivotalsoftware/quickstep/subscribers","subscription_url":"https://api.github.com/repos/pivotalsoftware/quickstep/subscription","commits_url":"https://api.github.com/repos/pivotalsoftware/quickstep/commits{/sha}","git_commits_url":"https://api.github.com/repos/pivotalsoftware/quickstep/git/commits{/sha}","comments_url":"https://api.github.com/repos/pivotalsoftware/quickstep/comments{/number}","issue_comment_url":"https://api.github.com/repos/pivotalsoftware/quickstep/issues/comments{/number}","contents_url":"https://api.github.com/repos/pivotalsoftware/quickstep/contents/{+path}","compare_url":"https://api.github.com/repos/pivotalsoftware/quickstep/compare/{base}...{head}","merges_url":"https://api.github.com/repos/pivotalsoftware/quickstep/merges","archive_url":"https://api.github.com/repos/pivotalsoftware/quickstep/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/pivotalsoftware/quickstep/downloads","issues_url":"https://api.github.com/repos/pivotalsoftware/quickstep/issues{/number}","pulls_url":"https://api.github.com/repos/pivotalsoftware/quickstep/pulls{/number}","milestones_url":"https://api.github.com/repos/pivotalsoftware/quickstep/milestones{/number}","notifications_url":"https://api.github.com/repos/pivotalsoftware/quickstep/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/pivotalsoftware/quickstep/labels{/name}","releases_url":"https://api.github.com/repos/pivotalsoftware/quickstep/releases{/id}","deployments_url":"https://api.github.com/repos/pivotalsoftware/quickstep/deployments","created_at":"2015-11-05T01:06:50Z","updated_at":"2016-03-30T04:28:05Z","pushed_at":"2016-04-05T01:23:21Z","git_url":"git://github.com/pivotalsoftware/quickstep.git","ssh_url":"git@github.com:pivotalsoftware/quickstep.git","clone_url":"https://github.com/pivotalsoftware/quickstep.git","svn_url":"https://github.com/pivotalsoftware/quickstep","homepage":null,"size":7901,"stargazers_count":14,"watchers_count":14,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":9,"mirror_url":null,"open_issues_count":17,"forks":9,"open_issues":17,"watchers":14,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/pivotalsoftware/quickstep/pulls/119"},"html":{"href":"https://github.com/pivotalsoftware/quickstep/pull/119"},"issue":{"href":"https://api.github.com/repos/pivotalsoftware/quickstep/issues/119"},"comments":{"href":"https://api.github.com/repos/pivotalsoftware/quickstep/issues/119/comments"},"review_comments":{"href":"https://api.github.com/repos/pivotalsoftware/quickstep/pulls/119/comments"},"review_comment":{"href":"https://api.github.com/repos/pivotalsoftware/quickstep/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/pivotalsoftware/quickstep/pulls/119/commits"},"statuses":{"href":"https://api.github.com/repos/pivotalsoftware/quickstep/statuses/6d1c1198ff14a3886abbc8c0e317260f1a5d0ba1"}}}}