You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
|[`thread.id`](/docs/registry/attributes/thread.md)| int | Current "managed" thread ID (as opposed to OS thread ID). |`42`|`Recommended`||
398
-
|[`thread.name`](/docs/registry/attributes/thread.md)| string | Current thread name. |`main`|`Recommended`||
397
+
|[`thread.id`](/docs/registry/attributes/thread.md)| int | Current "managed" thread ID (as opposed to OS thread ID). [1]|`42`|`Recommended`||
398
+
|[`thread.name`](/docs/registry/attributes/thread.md)| string | Current thread name. [2]|`main`|`Recommended`||
399
+
400
+
**[1]`thread.id`:** Examples of where the value can be extracted from:
401
+
402
+
| Language or platform | Source |
403
+
| --- | --- |
404
+
| JVM |`Thread.currentThread().threadId()`|
405
+
| .NET |`Thread.CurrentThread.ManagedThreadId`|
406
+
| Python |`threading.current_thread().ident`|
407
+
| Ruby |`Thread.current.object_id`|
408
+
| C++ |`std::this_thread::get_id()`|
409
+
| Erlang |`erlang:self()`|
410
+
411
+
**[2]`thread.name`:** Examples of where the value can be extracted from:
| <aid="thread-id"href="#thread-id">`thread.id`</a> | int | Current "managed" thread ID (as opposed to OS thread ID). |`42`||
13
-
| <aid="thread-name"href="#thread-name">`thread.name`</a> | string | Current thread name. |`main`||
12
+
| <aid="thread-id"href="#thread-id">`thread.id`</a> | int | Current "managed" thread ID (as opposed to OS thread ID). [1]|`42`||
13
+
| <aid="thread-name"href="#thread-name">`thread.name`</a> | string | Current thread name. [2]|`main`||
14
+
15
+
**[1]`thread.id`:** Examples of where the value can be extracted from:
16
+
17
+
| Language or platform | Source |
18
+
| --- | --- |
19
+
| JVM |`Thread.currentThread().threadId()`|
20
+
| .NET |`Thread.CurrentThread.ManagedThreadId`|
21
+
| Python |`threading.current_thread().ident`|
22
+
| Ruby |`Thread.current.object_id`|
23
+
| C++ |`std::this_thread::get_id()`|
24
+
| Erlang |`erlang:self()`|
25
+
26
+
**[2]`thread.name`:** Examples of where the value can be extracted from:
0 commit comments