{"action":"created","comment":{"url":"https://api.github.com/repos/jaegertracing/jaeger/pulls/comments/172661185","pull_request_review_id":101715746,"id":172661185,"diff_hunk":"@@ -0,0 +1,88 @@\n+// Copyright (c) 2018 The Jaeger Authors.\n+//\n+// Licensed under the Apache License, Version 2.0 (the \"License\");\n+// you may not use this file except in compliance with the License.\n+// You may obtain a copy of the License at\n+//\n+// http://www.apache.org/licenses/LICENSE-2.0\n+//\n+// Unless required by applicable law or agreed to in writing, software\n+// distributed under the License is distributed on an \"AS IS\" BASIS,\n+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n+// See the License for the specific language governing permissions and\n+// limitations under the License.\n+\n+package adjuster\n+\n+import (\n+\t\"sort\"\n+\n+\t\"github.com/jaegertracing/jaeger/model\"\n+)\n+\n+// MergeSpans returns an Adjuster that merges Jaeger spans with the same spanID.\n+// It skips merging Zipkin spans. Zipkin spans are defined as spans sharing the spanID and containing\n+// both client and server span.kind annotations.\n+// As Zipkin spans are always reported in entirety, we can assume that that the span.kind annotations are present.\n+// A drawback of this approach is that incomplete traces with duplicate Zipkin spans will be merged unnecessarily\n+//\n+// MergeSpans assumes that the duration field in a span is monotonically increasing for a spans with the","path":"model/adjuster/span_merger.go","position":29,"original_position":29,"commit_id":"c5c819e6698314c0870c9189c4245549f9fc97d9","original_commit_id":"49a0bd419fe6bc564751d320a2976c68cc3872c1","user":{"login":"black-adder","id":791791,"avatar_url":"https://avatars1.githubusercontent.com/u/791791?v=4","gravatar_id":"","url":"https://api.github.com/users/black-adder","html_url":"https://github.com/black-adder","followers_url":"https://api.github.com/users/black-adder/followers","following_url":"https://api.github.com/users/black-adder/following{/other_user}","gists_url":"https://api.github.com/users/black-adder/gists{/gist_id}","starred_url":"https://api.github.com/users/black-adder/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/black-adder/subscriptions","organizations_url":"https://api.github.com/users/black-adder/orgs","repos_url":"https://api.github.com/users/black-adder/repos","events_url":"https://api.github.com/users/black-adder/events{/privacy}","received_events_url":"https://api.github.com/users/black-adder/received_events","type":"User","site_admin":false},"body":"s/a spans/spans","created_at":"2018-03-06T21:12:15Z","updated_at":"2018-03-06T21:33:27Z","html_url":"https://github.com/jaegertracing/jaeger/pull/728#discussion_r172661185","pull_request_url":"https://api.github.com/repos/jaegertracing/jaeger/pulls/728","author_association":"COLLABORATOR","_links":{"self":{"href":"https://api.github.com/repos/jaegertracing/jaeger/pulls/comments/172661185"},"html":{"href":"https://github.com/jaegertracing/jaeger/pull/728#discussion_r172661185"},"pull_request":{"href":"https://api.github.com/repos/jaegertracing/jaeger/pulls/728"}}},"pull_request":{"url":"https://api.github.com/repos/jaegertracing/jaeger/pulls/728","id":173277702,"html_url":"https://github.com/jaegertracing/jaeger/pull/728","diff_url":"https://github.com/jaegertracing/jaeger/pull/728.diff","patch_url":"https://github.com/jaegertracing/jaeger/pull/728.patch","issue_url":"https://api.github.com/repos/jaegertracing/jaeger/issues/728","number":728,"state":"open","locked":false,"title":"Add a span merger that merges spans read","user":{"login":"vprithvi","id":833009,"avatar_url":"https://avatars0.githubusercontent.com/u/833009?v=4","gravatar_id":"","url":"https://api.github.com/users/vprithvi","html_url":"https://github.com/vprithvi","followers_url":"https://api.github.com/users/vprithvi/followers","following_url":"https://api.github.com/users/vprithvi/following{/other_user}","gists_url":"https://api.github.com/users/vprithvi/gists{/gist_id}","starred_url":"https://api.github.com/users/vprithvi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vprithvi/subscriptions","organizations_url":"https://api.github.com/users/vprithvi/orgs","repos_url":"https://api.github.com/users/vprithvi/repos","events_url":"https://api.github.com/users/vprithvi/events{/privacy}","received_events_url":"https://api.github.com/users/vprithvi/received_events","type":"User","site_admin":false},"body":"- allows for partially written spans to be merged while querying by selecting\r\n  the span with the longest duration.\r\n\r\nSee https://github.com/jaegertracing/jaeger-client-java/issues/231 for more discussion\r\n\r\nSigned-off-by: Prithvi Raj <p.r@uber.com>","created_at":"2018-03-06T20:52:03Z","updated_at":"2018-03-06T21:33:27Z","closed_at":null,"merged_at":null,"merge_commit_sha":"238d8f50a8f9811b021f1955fbe03eb907e994dc","assignee":{"login":"vprithvi","id":833009,"avatar_url":"https://avatars0.githubusercontent.com/u/833009?v=4","gravatar_id":"","url":"https://api.github.com/users/vprithvi","html_url":"https://github.com/vprithvi","followers_url":"https://api.github.com/users/vprithvi/followers","following_url":"https://api.github.com/users/vprithvi/following{/other_user}","gists_url":"https://api.github.com/users/vprithvi/gists{/gist_id}","starred_url":"https://api.github.com/users/vprithvi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vprithvi/subscriptions","organizations_url":"https://api.github.com/users/vprithvi/orgs","repos_url":"https://api.github.com/users/vprithvi/repos","events_url":"https://api.github.com/users/vprithvi/events{/privacy}","received_events_url":"https://api.github.com/users/vprithvi/received_events","type":"User","site_admin":false},"assignees":[{"login":"vprithvi","id":833009,"avatar_url":"https://avatars0.githubusercontent.com/u/833009?v=4","gravatar_id":"","url":"https://api.github.com/users/vprithvi","html_url":"https://github.com/vprithvi","followers_url":"https://api.github.com/users/vprithvi/followers","following_url":"https://api.github.com/users/vprithvi/following{/other_user}","gists_url":"https://api.github.com/users/vprithvi/gists{/gist_id}","starred_url":"https://api.github.com/users/vprithvi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vprithvi/subscriptions","organizations_url":"https://api.github.com/users/vprithvi/orgs","repos_url":"https://api.github.com/users/vprithvi/repos","events_url":"https://api.github.com/users/vprithvi/events{/privacy}","received_events_url":"https://api.github.com/users/vprithvi/received_events","type":"User","site_admin":false}],"requested_reviewers":[{"login":"yurishkuro","id":3523016,"avatar_url":"https://avatars2.githubusercontent.com/u/3523016?v=4","gravatar_id":"","url":"https://api.github.com/users/yurishkuro","html_url":"https://github.com/yurishkuro","followers_url":"https://api.github.com/users/yurishkuro/followers","following_url":"https://api.github.com/users/yurishkuro/following{/other_user}","gists_url":"https://api.github.com/users/yurishkuro/gists{/gist_id}","starred_url":"https://api.github.com/users/yurishkuro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yurishkuro/subscriptions","organizations_url":"https://api.github.com/users/yurishkuro/orgs","repos_url":"https://api.github.com/users/yurishkuro/repos","events_url":"https://api.github.com/users/yurishkuro/events{/privacy}","received_events_url":"https://api.github.com/users/yurishkuro/received_events","type":"User","site_admin":false},{"login":"pavolloffay","id":5618424,"avatar_url":"https://avatars0.githubusercontent.com/u/5618424?v=4","gravatar_id":"","url":"https://api.github.com/users/pavolloffay","html_url":"https://github.com/pavolloffay","followers_url":"https://api.github.com/users/pavolloffay/followers","following_url":"https://api.github.com/users/pavolloffay/following{/other_user}","gists_url":"https://api.github.com/users/pavolloffay/gists{/gist_id}","starred_url":"https://api.github.com/users/pavolloffay/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pavolloffay/subscriptions","organizations_url":"https://api.github.com/users/pavolloffay/orgs","repos_url":"https://api.github.com/users/pavolloffay/repos","events_url":"https://api.github.com/users/pavolloffay/events{/privacy}","received_events_url":"https://api.github.com/users/pavolloffay/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[{"id":708883141,"url":"https://api.github.com/repos/jaegertracing/jaeger/labels/review","name":"review","color":"ededed","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/jaegertracing/jaeger/pulls/728/commits","review_comments_url":"https://api.github.com/repos/jaegertracing/jaeger/pulls/728/comments","review_comment_url":"https://api.github.com/repos/jaegertracing/jaeger/pulls/comments{/number}","comments_url":"https://api.github.com/repos/jaegertracing/jaeger/issues/728/comments","statuses_url":"https://api.github.com/repos/jaegertracing/jaeger/statuses/c5c819e6698314c0870c9189c4245549f9fc97d9","head":{"label":"jaegertracing:merge-on-read","ref":"merge-on-read","sha":"c5c819e6698314c0870c9189c4245549f9fc97d9","user":{"login":"jaegertracing","id":28545596,"avatar_url":"https://avatars1.githubusercontent.com/u/28545596?v=4","gravatar_id":"","url":"https://api.github.com/users/jaegertracing","html_url":"https://github.com/jaegertracing","followers_url":"https://api.github.com/users/jaegertracing/followers","following_url":"https://api.github.com/users/jaegertracing/following{/other_user}","gists_url":"https://api.github.com/users/jaegertracing/gists{/gist_id}","starred_url":"https://api.github.com/users/jaegertracing/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jaegertracing/subscriptions","organizations_url":"https://api.github.com/users/jaegertracing/orgs","repos_url":"https://api.github.com/users/jaegertracing/repos","events_url":"https://api.github.com/users/jaegertracing/events{/privacy}","received_events_url":"https://api.github.com/users/jaegertracing/received_events","type":"Organization","site_admin":false},"repo":{"id":56342508,"name":"jaeger","full_name":"jaegertracing/jaeger","owner":{"login":"jaegertracing","id":28545596,"avatar_url":"https://avatars1.githubusercontent.com/u/28545596?v=4","gravatar_id":"","url":"https://api.github.com/users/jaegertracing","html_url":"https://github.com/jaegertracing","followers_url":"https://api.github.com/users/jaegertracing/followers","following_url":"https://api.github.com/users/jaegertracing/following{/other_user}","gists_url":"https://api.github.com/users/jaegertracing/gists{/gist_id}","starred_url":"https://api.github.com/users/jaegertracing/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jaegertracing/subscriptions","organizations_url":"https://api.github.com/users/jaegertracing/orgs","repos_url":"https://api.github.com/users/jaegertracing/repos","events_url":"https://api.github.com/users/jaegertracing/events{/privacy}","received_events_url":"https://api.github.com/users/jaegertracing/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/jaegertracing/jaeger","description":"CNCF Jaeger, a Distributed Tracing System","fork":false,"url":"https://api.github.com/repos/jaegertracing/jaeger","forks_url":"https://api.github.com/repos/jaegertracing/jaeger/forks","keys_url":"https://api.github.com/repos/jaegertracing/jaeger/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jaegertracing/jaeger/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jaegertracing/jaeger/teams","hooks_url":"https://api.github.com/repos/jaegertracing/jaeger/hooks","issue_events_url":"https://api.github.com/repos/jaegertracing/jaeger/issues/events{/number}","events_url":"https://api.github.com/repos/jaegertracing/jaeger/events","assignees_url":"https://api.github.com/repos/jaegertracing/jaeger/assignees{/user}","branches_url":"https://api.github.com/repos/jaegertracing/jaeger/branches{/branch}","tags_url":"https://api.github.com/repos/jaegertracing/jaeger/tags","blobs_url":"https://api.github.com/repos/jaegertracing/jaeger/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jaegertracing/jaeger/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jaegertracing/jaeger/git/refs{/sha}","trees_url":"https://api.github.com/repos/jaegertracing/jaeger/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jaegertracing/jaeger/statuses/{sha}","languages_url":"https://api.github.com/repos/jaegertracing/jaeger/languages","stargazers_url":"https://api.github.com/repos/jaegertracing/jaeger/stargazers","contributors_url":"https://api.github.com/repos/jaegertracing/jaeger/contributors","subscribers_url":"https://api.github.com/repos/jaegertracing/jaeger/subscribers","subscription_url":"https://api.github.com/repos/jaegertracing/jaeger/subscription","commits_url":"https://api.github.com/repos/jaegertracing/jaeger/commits{/sha}","git_commits_url":"https://api.github.com/repos/jaegertracing/jaeger/git/commits{/sha}","comments_url":"https://api.github.com/repos/jaegertracing/jaeger/comments{/number}","issue_comment_url":"https://api.github.com/repos/jaegertracing/jaeger/issues/comments{/number}","contents_url":"https://api.github.com/repos/jaegertracing/jaeger/contents/{+path}","compare_url":"https://api.github.com/repos/jaegertracing/jaeger/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jaegertracing/jaeger/merges","archive_url":"https://api.github.com/repos/jaegertracing/jaeger/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jaegertracing/jaeger/downloads","issues_url":"https://api.github.com/repos/jaegertracing/jaeger/issues{/number}","pulls_url":"https://api.github.com/repos/jaegertracing/jaeger/pulls{/number}","milestones_url":"https://api.github.com/repos/jaegertracing/jaeger/milestones{/number}","notifications_url":"https://api.github.com/repos/jaegertracing/jaeger/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jaegertracing/jaeger/labels{/name}","releases_url":"https://api.github.com/repos/jaegertracing/jaeger/releases{/id}","deployments_url":"https://api.github.com/repos/jaegertracing/jaeger/deployments","created_at":"2016-04-15T18:49:02Z","updated_at":"2018-03-06T21:06:03Z","pushed_at":"2018-03-06T21:26:36Z","git_url":"git://github.com/jaegertracing/jaeger.git","ssh_url":"git@github.com:jaegertracing/jaeger.git","clone_url":"https://github.com/jaegertracing/jaeger.git","svn_url":"https://github.com/jaegertracing/jaeger","homepage":"http://jaegertracing.io/","size":2657,"stargazers_count":4091,"watchers_count":4091,"language":"Go","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":319,"mirror_url":null,"archived":false,"open_issues_count":145,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0"},"forks":319,"open_issues":145,"watchers":4091,"default_branch":"master"}},"base":{"label":"jaegertracing:master","ref":"master","sha":"cce04e79abd54e41f41e7ad583e48343b7010e4c","user":{"login":"jaegertracing","id":28545596,"avatar_url":"https://avatars1.githubusercontent.com/u/28545596?v=4","gravatar_id":"","url":"https://api.github.com/users/jaegertracing","html_url":"https://github.com/jaegertracing","followers_url":"https://api.github.com/users/jaegertracing/followers","following_url":"https://api.github.com/users/jaegertracing/following{/other_user}","gists_url":"https://api.github.com/users/jaegertracing/gists{/gist_id}","starred_url":"https://api.github.com/users/jaegertracing/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jaegertracing/subscriptions","organizations_url":"https://api.github.com/users/jaegertracing/orgs","repos_url":"https://api.github.com/users/jaegertracing/repos","events_url":"https://api.github.com/users/jaegertracing/events{/privacy}","received_events_url":"https://api.github.com/users/jaegertracing/received_events","type":"Organization","site_admin":false},"repo":{"id":56342508,"name":"jaeger","full_name":"jaegertracing/jaeger","owner":{"login":"jaegertracing","id":28545596,"avatar_url":"https://avatars1.githubusercontent.com/u/28545596?v=4","gravatar_id":"","url":"https://api.github.com/users/jaegertracing","html_url":"https://github.com/jaegertracing","followers_url":"https://api.github.com/users/jaegertracing/followers","following_url":"https://api.github.com/users/jaegertracing/following{/other_user}","gists_url":"https://api.github.com/users/jaegertracing/gists{/gist_id}","starred_url":"https://api.github.com/users/jaegertracing/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jaegertracing/subscriptions","organizations_url":"https://api.github.com/users/jaegertracing/orgs","repos_url":"https://api.github.com/users/jaegertracing/repos","events_url":"https://api.github.com/users/jaegertracing/events{/privacy}","received_events_url":"https://api.github.com/users/jaegertracing/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/jaegertracing/jaeger","description":"CNCF Jaeger, a Distributed Tracing System","fork":false,"url":"https://api.github.com/repos/jaegertracing/jaeger","forks_url":"https://api.github.com/repos/jaegertracing/jaeger/forks","keys_url":"https://api.github.com/repos/jaegertracing/jaeger/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jaegertracing/jaeger/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jaegertracing/jaeger/teams","hooks_url":"https://api.github.com/repos/jaegertracing/jaeger/hooks","issue_events_url":"https://api.github.com/repos/jaegertracing/jaeger/issues/events{/number}","events_url":"https://api.github.com/repos/jaegertracing/jaeger/events","assignees_url":"https://api.github.com/repos/jaegertracing/jaeger/assignees{/user}","branches_url":"https://api.github.com/repos/jaegertracing/jaeger/branches{/branch}","tags_url":"https://api.github.com/repos/jaegertracing/jaeger/tags","blobs_url":"https://api.github.com/repos/jaegertracing/jaeger/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jaegertracing/jaeger/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jaegertracing/jaeger/git/refs{/sha}","trees_url":"https://api.github.com/repos/jaegertracing/jaeger/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jaegertracing/jaeger/statuses/{sha}","languages_url":"https://api.github.com/repos/jaegertracing/jaeger/languages","stargazers_url":"https://api.github.com/repos/jaegertracing/jaeger/stargazers","contributors_url":"https://api.github.com/repos/jaegertracing/jaeger/contributors","subscribers_url":"https://api.github.com/repos/jaegertracing/jaeger/subscribers","subscription_url":"https://api.github.com/repos/jaegertracing/jaeger/subscription","commits_url":"https://api.github.com/repos/jaegertracing/jaeger/commits{/sha}","git_commits_url":"https://api.github.com/repos/jaegertracing/jaeger/git/commits{/sha}","comments_url":"https://api.github.com/repos/jaegertracing/jaeger/comments{/number}","issue_comment_url":"https://api.github.com/repos/jaegertracing/jaeger/issues/comments{/number}","contents_url":"https://api.github.com/repos/jaegertracing/jaeger/contents/{+path}","compare_url":"https://api.github.com/repos/jaegertracing/jaeger/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jaegertracing/jaeger/merges","archive_url":"https://api.github.com/repos/jaegertracing/jaeger/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jaegertracing/jaeger/downloads","issues_url":"https://api.github.com/repos/jaegertracing/jaeger/issues{/number}","pulls_url":"https://api.github.com/repos/jaegertracing/jaeger/pulls{/number}","milestones_url":"https://api.github.com/repos/jaegertracing/jaeger/milestones{/number}","notifications_url":"https://api.github.com/repos/jaegertracing/jaeger/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jaegertracing/jaeger/labels{/name}","releases_url":"https://api.github.com/repos/jaegertracing/jaeger/releases{/id}","deployments_url":"https://api.github.com/repos/jaegertracing/jaeger/deployments","created_at":"2016-04-15T18:49:02Z","updated_at":"2018-03-06T21:06:03Z","pushed_at":"2018-03-06T21:26:36Z","git_url":"git://github.com/jaegertracing/jaeger.git","ssh_url":"git@github.com:jaegertracing/jaeger.git","clone_url":"https://github.com/jaegertracing/jaeger.git","svn_url":"https://github.com/jaegertracing/jaeger","homepage":"http://jaegertracing.io/","size":2657,"stargazers_count":4091,"watchers_count":4091,"language":"Go","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":319,"mirror_url":null,"archived":false,"open_issues_count":145,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0"},"forks":319,"open_issues":145,"watchers":4091,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/jaegertracing/jaeger/pulls/728"},"html":{"href":"https://github.com/jaegertracing/jaeger/pull/728"},"issue":{"href":"https://api.github.com/repos/jaegertracing/jaeger/issues/728"},"comments":{"href":"https://api.github.com/repos/jaegertracing/jaeger/issues/728/comments"},"review_comments":{"href":"https://api.github.com/repos/jaegertracing/jaeger/pulls/728/comments"},"review_comment":{"href":"https://api.github.com/repos/jaegertracing/jaeger/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/jaegertracing/jaeger/pulls/728/commits"},"statuses":{"href":"https://api.github.com/repos/jaegertracing/jaeger/statuses/c5c819e6698314c0870c9189c4245549f9fc97d9"}},"author_association":"COLLABORATOR"}}
{"actor":{"display_login":"black-adder"}}