summaryrefslogtreecommitdiffstats
path: root/contrib/libs/opentelemetry-cpp/api/include/opentelemetry/semconv/incubating/thread_attributes.h
blob: c6249884b66896ac899dc2d2fc7b0211ecd2d393 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
/*
 * Copyright The OpenTelemetry Authors
 * SPDX-License-Identifier: Apache-2.0
 */

/*
 * DO NOT EDIT, this is an Auto-generated file from:
 * buildscripts/semantic-convention/templates/registry/semantic_attributes-h.j2
 */

#pragma once

#include "opentelemetry/common/macros.h"
#include "opentelemetry/version.h"

OPENTELEMETRY_BEGIN_NAMESPACE
namespace semconv
{
namespace thread
{

/**
  Current "managed" thread ID (as opposed to OS thread ID).
  <p>
  Examples of where the value can be extracted from:
  <p>
  | Language or platform | Source |
  | --- | --- |
  | JVM | @code Thread.currentThread().threadId() @endcode |
  | .NET | @code Thread.CurrentThread.ManagedThreadId @endcode |
  | Python | @code threading.current_thread().ident @endcode |
  | Ruby | @code Thread.current.object_id @endcode |
  | C++ | @code std::this_thread::get_id() @endcode |
  | Erlang | @code erlang:self() @endcode |
 */
static constexpr const char *kThreadId = "thread.id";

/**
  Current thread name.
  <p>
  Examples of where the value can be extracted from:
  <p>
  | Language or platform | Source |
  | --- | --- |
  | JVM | @code Thread.currentThread().getName() @endcode |
  | .NET | @code Thread.CurrentThread.Name @endcode |
  | Python | @code threading.current_thread().name @endcode |
  | Ruby | @code Thread.current.name @endcode |
  | Erlang | @code erlang:process_info(self(), registered_name) @endcode |
 */
static constexpr const char *kThreadName = "thread.name";

}  // namespace thread
}  // namespace semconv
OPENTELEMETRY_END_NAMESPACE