{"action":"created","comment":{"url":"https://api.github.com/repos/opentracing/opentracing-java/pulls/comments/70742560","id":70742560,"diff_hunk":"@@ -20,73 +20,80 @@\n public interface Tracer {\n \n   /**\n-   * Create, start, and return a new Span with the given `operationName`.\n-   * An optional parent Span can be specified used to incorporate the newly-returned Span into an existing trace.\n+   * Return a new SpanBuilder for a Span with the given `operationName`.\n    *\n-   * <p>Example:\n+   * <p>A contrived example:\n    * <pre>{@code\n     Tracer tracer = ...\n \n-    Span feed = tracer.buildSpan(\"GetFeed\")\n-                      .start();\n+    Span parentSpan = tracer.buildSpan(\"DoWork\")\n+                            .start();\n \n     Span http = tracer.buildSpan(\"HandleHTTPRequest\")\n-                      .withParent(feed)\n+                      .withChildOf(parentSpan.context())\n                       .withTag(\"user_agent\", req.UserAgent)\n                       .withTag(\"lucky_number\", 42)\n                       .start();\n     }</pre>\n    */\n   SpanBuilder buildSpan(String operationName);\n \n-  /** Takes two arguments:\n-   *    a Span instance, and\n-   *    a “carrier” object in which to inject that Span for cross-process propagation.\n+  /**\n+   * Inject a SpanContext into a `carrier` of a given `format`, presumably for propagation across process boundaries.\n+   *\n+   * <p>Example:\n+   * <pre>{@code\n+   * Tracer tracer = ...\n+   * Span clientSpan = ...\n+   * TextMapWriter httpHeaderWriter = new AnHttpHeaderCarrier(httpRequest);\n+   * tracer.inject(span.context(), BuiltinFormats.HTTP_HEADER, httpHeaderWriter);\n+   * }</pre>\n    *\n-   * A “carrier” object is some sort of http or rpc envelope, for example HeaderGroup (from Apache HttpComponents).\n+   * @param spanContext the SpanContext instance to inject into the carrier\n+   * @param format the Format of the carrier. See BuiltinFormats.\n+   * @param carrier the carrier for the SpanContext state; when inject() returns, the Tracer implementation will have represented the SpanContext within `carrier`\n    *\n-   * Attempting to inject to a carrier that has been registered/configured to this Tracer will result in a\n-   * IllegalStateException.\n+   * All implementations must support, at minimum, the BuiltinFormats.\n    *\n-   * All implementations support at minimum the required carriers BinaryWriter and TextMapWriter.\n+   * @see BuiltinFormats\n    */\n-  <T> void inject(Span span, T carrier);\n+  <W> void inject(SpanContext spanContext, Format<?, W> format, W carrier);","path":"opentracing-api/src/main/java/io/opentracing/Tracer.java","position":null,"original_position":55,"commit_id":"ba3be7bde538097c10941f810754954f1735550e","original_commit_id":"3630064fbce5367c438fc2981780103022e38c51","user":{"login":"yurishkuro","id":3523016,"avatar_url":"https://avatars.githubusercontent.com/u/3523016?v=3","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},"body":"Keeping both would've been a good compromise if not for the proposed `Format.HTTPHeader` that actually requires the 2-argument version, and is _the_ prevalent use case.","created_at":"2016-07-14T03:04:59Z","updated_at":"2016-07-14T03:04:59Z","html_url":"https://github.com/opentracing/opentracing-java/pull/32#discussion_r70742560","pull_request_url":"https://api.github.com/repos/opentracing/opentracing-java/pulls/32","_links":{"self":{"href":"https://api.github.com/repos/opentracing/opentracing-java/pulls/comments/70742560"},"html":{"href":"https://github.com/opentracing/opentracing-java/pull/32#discussion_r70742560"},"pull_request":{"href":"https://api.github.com/repos/opentracing/opentracing-java/pulls/32"}}},"pull_request":{"url":"https://api.github.com/repos/opentracing/opentracing-java/pulls/32","id":77232826,"html_url":"https://github.com/opentracing/opentracing-java/pull/32","diff_url":"https://github.com/opentracing/opentracing-java/pull/32.diff","patch_url":"https://github.com/opentracing/opentracing-java/pull/32.patch","issue_url":"https://api.github.com/repos/opentracing/opentracing-java/issues/32","number":32,"state":"open","locked":false,"title":"An RFC for SpanContext, References, as well as changes to carriers","user":{"login":"bensigelman","id":2251553,"avatar_url":"https://avatars.githubusercontent.com/u/2251553?v=3","gravatar_id":"","url":"https://api.github.com/users/bensigelman","html_url":"https://github.com/bensigelman","followers_url":"https://api.github.com/users/bensigelman/followers","following_url":"https://api.github.com/users/bensigelman/following{/other_user}","gists_url":"https://api.github.com/users/bensigelman/gists{/gist_id}","starred_url":"https://api.github.com/users/bensigelman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bensigelman/subscriptions","organizations_url":"https://api.github.com/users/bensigelman/orgs","repos_url":"https://api.github.com/users/bensigelman/repos","events_url":"https://api.github.com/users/bensigelman/events{/privacy}","received_events_url":"https://api.github.com/users/bensigelman/received_events","type":"User","site_admin":false},"body":"I would love feedback about the API here... once we converge, we can decide what to do about the rest of this (github) repo (the impl helpers, etc).\r\n\r\nPlease look at https://github.com/opentracing/opentracing-java/issues/31 and https://github.com/opentracing/opentracing.github.io/issues/99 for background and motivation.\r\n\r\nI'll add a few PR comments inline as well.","created_at":"2016-07-13T05:40:11Z","updated_at":"2016-07-14T03:04:59Z","closed_at":null,"merged_at":null,"merge_commit_sha":"dd5623adaa57681c93ea1e3aeedf89b40e92040d","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/opentracing/opentracing-java/pulls/32/commits","review_comments_url":"https://api.github.com/repos/opentracing/opentracing-java/pulls/32/comments","review_comment_url":"https://api.github.com/repos/opentracing/opentracing-java/pulls/comments{/number}","comments_url":"https://api.github.com/repos/opentracing/opentracing-java/issues/32/comments","statuses_url":"https://api.github.com/repos/opentracing/opentracing-java/statuses/ba3be7bde538097c10941f810754954f1735550e","head":{"label":"opentracing:bhs/span_context_etc","ref":"bhs/span_context_etc","sha":"ba3be7bde538097c10941f810754954f1735550e","user":{"login":"opentracing","id":15482765,"avatar_url":"https://avatars.githubusercontent.com/u/15482765?v=3","gravatar_id":"","url":"https://api.github.com/users/opentracing","html_url":"https://github.com/opentracing","followers_url":"https://api.github.com/users/opentracing/followers","following_url":"https://api.github.com/users/opentracing/following{/other_user}","gists_url":"https://api.github.com/users/opentracing/gists{/gist_id}","starred_url":"https://api.github.com/users/opentracing/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/opentracing/subscriptions","organizations_url":"https://api.github.com/users/opentracing/orgs","repos_url":"https://api.github.com/users/opentracing/repos","events_url":"https://api.github.com/users/opentracing/events{/privacy}","received_events_url":"https://api.github.com/users/opentracing/received_events","type":"Organization","site_admin":false},"repo":{"id":48295629,"name":"opentracing-java","full_name":"opentracing/opentracing-java","owner":{"login":"opentracing","id":15482765,"avatar_url":"https://avatars.githubusercontent.com/u/15482765?v=3","gravatar_id":"","url":"https://api.github.com/users/opentracing","html_url":"https://github.com/opentracing","followers_url":"https://api.github.com/users/opentracing/followers","following_url":"https://api.github.com/users/opentracing/following{/other_user}","gists_url":"https://api.github.com/users/opentracing/gists{/gist_id}","starred_url":"https://api.github.com/users/opentracing/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/opentracing/subscriptions","organizations_url":"https://api.github.com/users/opentracing/orgs","repos_url":"https://api.github.com/users/opentracing/repos","events_url":"https://api.github.com/users/opentracing/events{/privacy}","received_events_url":"https://api.github.com/users/opentracing/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/opentracing/opentracing-java","description":"Java implementation of the OpenTracing API","fork":false,"url":"https://api.github.com/repos/opentracing/opentracing-java","forks_url":"https://api.github.com/repos/opentracing/opentracing-java/forks","keys_url":"https://api.github.com/repos/opentracing/opentracing-java/keys{/key_id}","collaborators_url":"https://api.github.com/repos/opentracing/opentracing-java/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/opentracing/opentracing-java/teams","hooks_url":"https://api.github.com/repos/opentracing/opentracing-java/hooks","issue_events_url":"https://api.github.com/repos/opentracing/opentracing-java/issues/events{/number}","events_url":"https://api.github.com/repos/opentracing/opentracing-java/events","assignees_url":"https://api.github.com/repos/opentracing/opentracing-java/assignees{/user}","branches_url":"https://api.github.com/repos/opentracing/opentracing-java/branches{/branch}","tags_url":"https://api.github.com/repos/opentracing/opentracing-java/tags","blobs_url":"https://api.github.com/repos/opentracing/opentracing-java/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/opentracing/opentracing-java/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/opentracing/opentracing-java/git/refs{/sha}","trees_url":"https://api.github.com/repos/opentracing/opentracing-java/git/trees{/sha}","statuses_url":"https://api.github.com/repos/opentracing/opentracing-java/statuses/{sha}","languages_url":"https://api.github.com/repos/opentracing/opentracing-java/languages","stargazers_url":"https://api.github.com/repos/opentracing/opentracing-java/stargazers","contributors_url":"https://api.github.com/repos/opentracing/opentracing-java/contributors","subscribers_url":"https://api.github.com/repos/opentracing/opentracing-java/subscribers","subscription_url":"https://api.github.com/repos/opentracing/opentracing-java/subscription","commits_url":"https://api.github.com/repos/opentracing/opentracing-java/commits{/sha}","git_commits_url":"https://api.github.com/repos/opentracing/opentracing-java/git/commits{/sha}","comments_url":"https://api.github.com/repos/opentracing/opentracing-java/comments{/number}","issue_comment_url":"https://api.github.com/repos/opentracing/opentracing-java/issues/comments{/number}","contents_url":"https://api.github.com/repos/opentracing/opentracing-java/contents/{+path}","compare_url":"https://api.github.com/repos/opentracing/opentracing-java/compare/{base}...{head}","merges_url":"https://api.github.com/repos/opentracing/opentracing-java/merges","archive_url":"https://api.github.com/repos/opentracing/opentracing-java/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/opentracing/opentracing-java/downloads","issues_url":"https://api.github.com/repos/opentracing/opentracing-java/issues{/number}","pulls_url":"https://api.github.com/repos/opentracing/opentracing-java/pulls{/number}","milestones_url":"https://api.github.com/repos/opentracing/opentracing-java/milestones{/number}","notifications_url":"https://api.github.com/repos/opentracing/opentracing-java/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/opentracing/opentracing-java/labels{/name}","releases_url":"https://api.github.com/repos/opentracing/opentracing-java/releases{/id}","deployments_url":"https://api.github.com/repos/opentracing/opentracing-java/deployments","created_at":"2015-12-19T20:07:30Z","updated_at":"2016-07-01T21:19:58Z","pushed_at":"2016-07-14T00:09:39Z","git_url":"git://github.com/opentracing/opentracing-java.git","ssh_url":"git@github.com:opentracing/opentracing-java.git","clone_url":"https://github.com/opentracing/opentracing-java.git","svn_url":"https://github.com/opentracing/opentracing-java","homepage":"http://opentracing.io","size":186,"stargazers_count":38,"watchers_count":38,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":7,"mirror_url":null,"open_issues_count":6,"forks":7,"open_issues":6,"watchers":38,"default_branch":"master"}},"base":{"label":"opentracing:master","ref":"master","sha":"88c8fefd93fa1dcf71a62ef969fd65f4ef7d1102","user":{"login":"opentracing","id":15482765,"avatar_url":"https://avatars.githubusercontent.com/u/15482765?v=3","gravatar_id":"","url":"https://api.github.com/users/opentracing","html_url":"https://github.com/opentracing","followers_url":"https://api.github.com/users/opentracing/followers","following_url":"https://api.github.com/users/opentracing/following{/other_user}","gists_url":"https://api.github.com/users/opentracing/gists{/gist_id}","starred_url":"https://api.github.com/users/opentracing/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/opentracing/subscriptions","organizations_url":"https://api.github.com/users/opentracing/orgs","repos_url":"https://api.github.com/users/opentracing/repos","events_url":"https://api.github.com/users/opentracing/events{/privacy}","received_events_url":"https://api.github.com/users/opentracing/received_events","type":"Organization","site_admin":false},"repo":{"id":48295629,"name":"opentracing-java","full_name":"opentracing/opentracing-java","owner":{"login":"opentracing","id":15482765,"avatar_url":"https://avatars.githubusercontent.com/u/15482765?v=3","gravatar_id":"","url":"https://api.github.com/users/opentracing","html_url":"https://github.com/opentracing","followers_url":"https://api.github.com/users/opentracing/followers","following_url":"https://api.github.com/users/opentracing/following{/other_user}","gists_url":"https://api.github.com/users/opentracing/gists{/gist_id}","starred_url":"https://api.github.com/users/opentracing/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/opentracing/subscriptions","organizations_url":"https://api.github.com/users/opentracing/orgs","repos_url":"https://api.github.com/users/opentracing/repos","events_url":"https://api.github.com/users/opentracing/events{/privacy}","received_events_url":"https://api.github.com/users/opentracing/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/opentracing/opentracing-java","description":"Java implementation of the OpenTracing API","fork":false,"url":"https://api.github.com/repos/opentracing/opentracing-java","forks_url":"https://api.github.com/repos/opentracing/opentracing-java/forks","keys_url":"https://api.github.com/repos/opentracing/opentracing-java/keys{/key_id}","collaborators_url":"https://api.github.com/repos/opentracing/opentracing-java/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/opentracing/opentracing-java/teams","hooks_url":"https://api.github.com/repos/opentracing/opentracing-java/hooks","issue_events_url":"https://api.github.com/repos/opentracing/opentracing-java/issues/events{/number}","events_url":"https://api.github.com/repos/opentracing/opentracing-java/events","assignees_url":"https://api.github.com/repos/opentracing/opentracing-java/assignees{/user}","branches_url":"https://api.github.com/repos/opentracing/opentracing-java/branches{/branch}","tags_url":"https://api.github.com/repos/opentracing/opentracing-java/tags","blobs_url":"https://api.github.com/repos/opentracing/opentracing-java/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/opentracing/opentracing-java/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/opentracing/opentracing-java/git/refs{/sha}","trees_url":"https://api.github.com/repos/opentracing/opentracing-java/git/trees{/sha}","statuses_url":"https://api.github.com/repos/opentracing/opentracing-java/statuses/{sha}","languages_url":"https://api.github.com/repos/opentracing/opentracing-java/languages","stargazers_url":"https://api.github.com/repos/opentracing/opentracing-java/stargazers","contributors_url":"https://api.github.com/repos/opentracing/opentracing-java/contributors","subscribers_url":"https://api.github.com/repos/opentracing/opentracing-java/subscribers","subscription_url":"https://api.github.com/repos/opentracing/opentracing-java/subscription","commits_url":"https://api.github.com/repos/opentracing/opentracing-java/commits{/sha}","git_commits_url":"https://api.github.com/repos/opentracing/opentracing-java/git/commits{/sha}","comments_url":"https://api.github.com/repos/opentracing/opentracing-java/comments{/number}","issue_comment_url":"https://api.github.com/repos/opentracing/opentracing-java/issues/comments{/number}","contents_url":"https://api.github.com/repos/opentracing/opentracing-java/contents/{+path}","compare_url":"https://api.github.com/repos/opentracing/opentracing-java/compare/{base}...{head}","merges_url":"https://api.github.com/repos/opentracing/opentracing-java/merges","archive_url":"https://api.github.com/repos/opentracing/opentracing-java/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/opentracing/opentracing-java/downloads","issues_url":"https://api.github.com/repos/opentracing/opentracing-java/issues{/number}","pulls_url":"https://api.github.com/repos/opentracing/opentracing-java/pulls{/number}","milestones_url":"https://api.github.com/repos/opentracing/opentracing-java/milestones{/number}","notifications_url":"https://api.github.com/repos/opentracing/opentracing-java/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/opentracing/opentracing-java/labels{/name}","releases_url":"https://api.github.com/repos/opentracing/opentracing-java/releases{/id}","deployments_url":"https://api.github.com/repos/opentracing/opentracing-java/deployments","created_at":"2015-12-19T20:07:30Z","updated_at":"2016-07-01T21:19:58Z","pushed_at":"2016-07-14T00:09:39Z","git_url":"git://github.com/opentracing/opentracing-java.git","ssh_url":"git@github.com:opentracing/opentracing-java.git","clone_url":"https://github.com/opentracing/opentracing-java.git","svn_url":"https://github.com/opentracing/opentracing-java","homepage":"http://opentracing.io","size":186,"stargazers_count":38,"watchers_count":38,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":7,"mirror_url":null,"open_issues_count":6,"forks":7,"open_issues":6,"watchers":38,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/opentracing/opentracing-java/pulls/32"},"html":{"href":"https://github.com/opentracing/opentracing-java/pull/32"},"issue":{"href":"https://api.github.com/repos/opentracing/opentracing-java/issues/32"},"comments":{"href":"https://api.github.com/repos/opentracing/opentracing-java/issues/32/comments"},"review_comments":{"href":"https://api.github.com/repos/opentracing/opentracing-java/pulls/32/comments"},"review_comment":{"href":"https://api.github.com/repos/opentracing/opentracing-java/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/opentracing/opentracing-java/pulls/32/commits"},"statuses":{"href":"https://api.github.com/repos/opentracing/opentracing-java/statuses/ba3be7bde538097c10941f810754954f1735550e"}}}}
{"actor":{"display_login":"yurishkuro"}}