Skip to content

Add experimental span attribute job.system#6586

Merged
trask merged 2 commits intoopen-telemetry:mainfrom
trask:job-system-attr
Sep 13, 2022
Merged

Add experimental span attribute job.system#6586
trask merged 2 commits intoopen-telemetry:mainfrom
trask:job-system-attr

Conversation

@trask
Copy link
Copy Markdown
Member

@trask trask commented Sep 12, 2022

Introduces experimental job.system span attribute from open-telemetry/opentelemetry-specification#1582

[motivation: we're mapping scheduled jobs to "top-level" operations (similar to SERVER/CONSUMER spans, but scheduled jobs are INTERNAL), and I need a way to identify them that doesn't involve checking the InstrumentationScope, since the scope isn't available in samplers]

@trask trask requested a review from a team September 12, 2022 01:13
@trask trask added this to the v1.18.0 milestone Sep 12, 2022
Copy link
Copy Markdown
Member

@mateuszrzeszutek mateuszrzeszutek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should probably include Spring Batch too.

One more question: this kinda duplicates the instrumentation/scope name, is that not usable for you?

@trask
Copy link
Copy Markdown
Member Author

trask commented Sep 12, 2022

We should probably include Spring Batch too.

will do

One more question: this kinda duplicates the instrumentation/scope name, is that not usable for you?

oh ya, I should have mentioned, I want to detect now in a sampler, which doesn't have scope (yet) 😞

@trask trask merged commit e8e573c into open-telemetry:main Sep 13, 2022
@trask trask deleted the job-system-attr branch September 13, 2022 14:22
LironKS pushed a commit to helios/opentelemetry-java-instrumentation that referenced this pull request Oct 23, 2022
* Add experimental span attribute job.system

* spring-batch
LironKS pushed a commit to helios/opentelemetry-java-instrumentation that referenced this pull request Oct 31, 2022
* Add experimental span attribute job.system

* spring-batch
LironKS pushed a commit to helios/opentelemetry-java-instrumentation that referenced this pull request Dec 4, 2022
* Add experimental span attribute job.system

* spring-batch
@julealgon
Copy link
Copy Markdown

Question on this: shouldn't it be a resource attribute instead of a span attribute?

We already have these today for identifying the web Engine:

With attributes:

  • webengine.description
  • webengine.name
  • webengine.version

It feels to me like the same structure would apply to a job scheduler/runner.

@trask
Copy link
Copy Markdown
Member Author

trask commented Mar 25, 2024

hi @julealgon! I don't see webengine.* attributes in this PR, can you clarify the relation to this PR, or even better probably open a new issues with all of the context? thanks

@julealgon
Copy link
Copy Markdown

hi @julealgon! I don't see webengine.* attributes in this PR, can you clarify the relation to this PR, or even better probably open a new issues with all of the context? thanks

Hi @trask . Those webengine.* attributes are not in the PR at all. I just brought them up because they were standardized in OTEL Semantic Conventions as resource attributes and, to me, they model something very similar to job.system, but job.system was added as a span-level attribute here in the instrumentation instead.

I was arguing/asking whether it would not have made more sense to have job.system in a "Job resource" instead (in my mind it would).

@laurit
Copy link
Copy Markdown
Contributor

laurit commented Mar 26, 2024

@julealgon the scheduling library, such as quarts, is but a small part of the application, but the resource is shared for all telemetry from the same jvm.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants