8000 Method for injecting trace parent into curl · Issue #306 · equinix-labs/otel-cli · GitHub
[go: up one dir, main page]

Skip to content

Method for injecting trace parent into curl #306

Closed

Description

@jeeftor

I wrote my own cli client for Otel and then found this one ... is there a way to inject the trace parent from an exec into the curl headers so I can see the full round trip of my existing tracing with this command?

Activity

  1. tobert commented on Feb 23, 2024

    @tobert
    Contributor

    There's not an easy way to do it right now. I had an old issue for this that I'll work on now that I have a request for it.

    The way I've done it so far is with a TRACEPARENT environment variable.

    traceparent_file=$(mktemp)
    otel-cli span --name "first span in the trace" --tp-carrier $traceparent_file --tp-export --endpoint https://collector
    . $traceparent_file
    otel-cli exec --endpoint https://collector -- curl -X "traceparent: $TRACEPARENT" https://site.com/file
  2. jeeftor commented on Feb 23, 2024

    @jeeftor
    Author

    Ended up just writing my own client

  3. tobert commented on Mar 11, 2024

    @tobert
    Contributor

    Released 0.4.3 with the injection feature. Sorry the timing didn't work out @jeeftor, and thanks for the bump to get this feature in.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      0