You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@skywalking.apache.org by "jmjoy (via GitHub)" <gi...@apache.org> on 2023/04/01 06:22:37 UTC

[GitHub] [skywalking-php] jmjoy commented on a diff in pull request #63: Fix parent endpoint and peer in segment ref.

jmjoy commented on code in PR #63:
URL: https://github.com/apache/skywalking-php/pull/63#discussion_r1155065260


##########
src/plugin/plugin_curl.rs:
##########
@@ -404,8 +404,13 @@ impl CurlPlugin {
     }
 
     fn inject_sw_header(request_id: Option<i64>, ch: ZVal, info: &CurlInfo) -> crate::Result<()> {
-        let sw_header = RequestContext::try_with_global_ctx(request_id, |ctx| {
-            Ok(encode_propagation(ctx, info.url.path(), &info.peer))
+        let sw_header = RequestContext::try_with_global(request_id, |req_ctx| {
+            let span_object = req_ctx.entry_span.span_object();

Review Comment:
   Now PHP trace always start from HTTP requests, so the entry span will exist, I think.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@skywalking.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org