-
Notifications
You must be signed in to change notification settings - Fork 49
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Capability to manually create spans #90
Comments
It also might be beneficial to get id of span and of traceID to enrich trace with data from other tools. |
Does the following pipeline code do the same? I think so def my_span(List spanAttributes, Closure body) {
withSpanAttributes(spanAttributes) {
body()
}
}
pipeline {
agent any
stages {
stage('Checkout') {
steps {
my_span([spanAttribute(key: "test.tool", value: "junit")]) {
// TODO sequence of shell steps to `git`+ fetch git submodules
// Get some code from a GitHub repository
// git credentialsId: 'my-user-git', url: 'https://github.com/jglick/simple-maven-project-with-tests.git'
}
}
}
stage('Build') {
steps {
...
}
}
}
} |
I am wrong; the functions and shared library steps do not create a new span. I will review if it is possible to generate a span there. |
Hello, I am really looking forward the ability to create my own spans while still being part of the auto genrated trace created by the plugin. I followed the #84 PR for a long time and I don't understand why is it closed? |
Problem description
I want to manually create spans in my pipeline, similar to manually creating spans when instrumenting applications with distributed tracing.
Example use cases
sh 'docker login -u $user -p $pass my.docker.registry'
)Example with the OpenTelemetry APIs for Java
See other problem statements
Proposed solutions
createSpan
pipeline stepThe text was updated successfully, but these errors were encountered: