|
| 1 | +// Copyright 2019, OpenTelemetry Authors |
| 2 | +// SPDX-License-Identifier: Apache-2.0 |
| 3 | + |
| 4 | +// This file is @generated by prost-build. |
| 5 | +/// Represents any type of attribute value. AnyValue may contain a |
| 6 | +/// primitive value such as a string or integer or it may contain an arbitrary nested |
| 7 | +/// object containing arrays, key-value lists and primitives. |
| 8 | +#[derive(Clone, PartialEq, ::prost::Message)] |
| 9 | +pub struct AnyValue { |
| 10 | + /// The value is one of the listed fields. It is valid for all values to be unspecified |
| 11 | + /// in which case this AnyValue is considered to be "empty". |
| 12 | + #[prost(oneof = "any_value::Value", tags = "1, 2, 3, 4, 5, 6, 7, 8")] |
| 13 | + pub value: ::core::option::Option<any_value::Value>, |
| 14 | +} |
| 15 | +/// Nested message and enum types in `AnyValue`. |
| 16 | +pub mod any_value { |
| 17 | + /// The value is one of the listed fields. It is valid for all values to be unspecified |
| 18 | + /// in which case this AnyValue is considered to be "empty". |
| 19 | + #[derive(Clone, PartialEq, ::prost::Oneof)] |
| 20 | + pub enum Value { |
| 21 | + #[prost(string, tag = "1")] |
| 22 | + StringValue(::prost::alloc::string::String), |
| 23 | + #[prost(bool, tag = "2")] |
| 24 | + BoolValue(bool), |
| 25 | + #[prost(int64, tag = "3")] |
| 26 | + IntValue(i64), |
| 27 | + #[prost(double, tag = "4")] |
| 28 | + DoubleValue(f64), |
| 29 | + #[prost(message, tag = "5")] |
| 30 | + ArrayValue(super::ArrayValue), |
| 31 | + #[prost(message, tag = "6")] |
| 32 | + KvlistValue(super::KeyValueList), |
| 33 | + #[prost(bytes, tag = "7")] |
| 34 | + BytesValue(::prost::alloc::vec::Vec<u8>), |
| 35 | + /// Reference to the string value in ProfilesDictionary.string_table. |
| 36 | + /// |
| 37 | + /// Note: This is currently used exclusively in the Profiling signal. |
| 38 | + /// Implementers of OTLP receivers for signals other than Profiling should |
| 39 | + /// treat the presence of this value as a non-fatal issue. |
| 40 | + /// Log an error or warning indicating an unexpected field intended for the |
| 41 | + /// Profiling signal and process the data as if this value were absent or |
| 42 | + /// empty, ignoring its semantic content for the non-Profiling signal. |
| 43 | + /// |
| 44 | + /// Status: \[Development\] |
| 45 | + #[prost(int32, tag = "8")] |
| 46 | + StringValueRef(i32), |
| 47 | + } |
| 48 | +} |
| 49 | +/// ArrayValue is a list of AnyValue messages. We need ArrayValue as a message |
| 50 | +/// since oneof in AnyValue does not allow repeated fields. |
| 51 | +#[derive(Clone, PartialEq, ::prost::Message)] |
| 52 | +pub struct ArrayValue { |
| 53 | + /// Array of values. The array may be empty (contain 0 elements). |
| 54 | + #[prost(message, repeated, tag = "1")] |
| 55 | + pub values: ::prost::alloc::vec::Vec<AnyValue>, |
| 56 | +} |
| 57 | +/// KeyValueList is a list of KeyValue messages. We need KeyValueList as a message |
| 58 | +/// since `oneof` in AnyValue does not allow repeated fields. Everywhere else where we need |
| 59 | +/// a list of KeyValue messages (e.g. in Span) we use `repeated KeyValue` directly to |
| 60 | +/// avoid unnecessary extra wrapping (which slows down the protocol). The 2 approaches |
| 61 | +/// are semantically equivalent. |
| 62 | +#[derive(Clone, PartialEq, ::prost::Message)] |
| 63 | +pub struct KeyValueList { |
| 64 | + /// A collection of key/value pairs of key-value pairs. The list may be empty (may |
| 65 | + /// contain 0 elements). |
| 66 | + /// |
| 67 | + /// The keys MUST be unique (it is not allowed to have more than one |
| 68 | + /// value with the same key). |
| 69 | + /// The behavior of software that receives duplicated keys can be unpredictable. |
| 70 | + #[prost(message, repeated, tag = "1")] |
| 71 | + pub values: ::prost::alloc::vec::Vec<KeyValue>, |
| 72 | +} |
| 73 | +/// Represents a key-value pair that is used to store Span attributes, Link |
| 74 | +/// attributes, etc. |
| 75 | +#[derive(Clone, PartialEq, ::prost::Message)] |
| 76 | +pub struct KeyValue { |
| 77 | + /// The key name of the pair. |
| 78 | + /// key_ref MUST NOT be set if key is used. |
| 79 | + #[prost(string, tag = "1")] |
| 80 | + pub key: ::prost::alloc::string::String, |
| 81 | + /// The value of the pair. |
| 82 | + #[prost(message, optional, tag = "2")] |
| 83 | + pub value: ::core::option::Option<AnyValue>, |
| 84 | + /// Reference to the string key in ProfilesDictionary.string_table. |
| 85 | + /// key MUST NOT be set if key_ref is used. |
| 86 | + /// |
| 87 | + /// Note: This is currently used exclusively in the Profiling signal. |
| 88 | + /// Implementers of OTLP receivers for signals other than Profiling should |
| 89 | + /// treat the presence of this key as a non-fatal issue. |
| 90 | + /// Log an error or warning indicating an unexpected field intended for the |
| 91 | + /// Profiling signal and process the data as if this value were absent or |
| 92 | + /// empty, ignoring its semantic content for the non-Profiling signal. |
| 93 | + /// |
| 94 | + /// Status: \[Development\] |
| 95 | + #[prost(int32, tag = "3")] |
| 96 | + pub key_ref: i32, |
| 97 | +} |
| 98 | +/// InstrumentationScope is a message representing the instrumentation scope information |
| 99 | +/// such as the fully qualified name and version. |
| 100 | +#[derive(Clone, PartialEq, ::prost::Message)] |
| 101 | +pub struct InstrumentationScope { |
| 102 | + /// A name denoting the Instrumentation scope. |
| 103 | + /// An empty instrumentation scope name means the name is unknown. |
| 104 | + #[prost(string, tag = "1")] |
| 105 | + pub name: ::prost::alloc::string::String, |
| 106 | + /// Defines the version of the instrumentation scope. |
| 107 | + /// An empty instrumentation scope version means the version is unknown. |
| 108 | + #[prost(string, tag = "2")] |
| 109 | + pub version: ::prost::alloc::string::String, |
| 110 | + /// Additional attributes that describe the scope. \[Optional\]. |
| 111 | + /// Attribute keys MUST be unique (it is not allowed to have more than one |
| 112 | + /// attribute with the same key). |
| 113 | + /// The behavior of software that receives duplicated keys can be unpredictable. |
| 114 | + #[prost(message, repeated, tag = "3")] |
| 115 | + pub attributes: ::prost::alloc::vec::Vec<KeyValue>, |
| 116 | + /// The number of attributes that were discarded. Attributes |
| 117 | + /// can be discarded because their keys are too long or because there are too many |
| 118 | + /// attributes. If this value is 0, then no attributes were dropped. |
| 119 | + #[prost(uint32, tag = "4")] |
| 120 | + pub dropped_attributes_count: u32, |
| 121 | +} |
| 122 | +/// A reference to an Entity. |
| 123 | +/// Entity represents an object of interest associated with produced telemetry: e.g spans, metrics, profiles, or logs. |
| 124 | +/// |
| 125 | +/// Status: \[Development\] |
| 126 | +#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)] |
| 127 | +pub struct EntityRef { |
| 128 | + /// The Schema URL, if known. This is the identifier of the Schema that the entity data |
| 129 | + /// is recorded in. To learn more about Schema URL see |
| 130 | + /// <https://opentelemetry.io/docs/specs/otel/schemas/#schema-url> |
| 131 | + /// |
| 132 | + /// This schema_url applies to the data in this message and to the Resource attributes |
| 133 | + /// referenced by id_keys and description_keys. |
| 134 | + /// TODO: discuss if we are happy with this somewhat complicated definition of what |
| 135 | + /// the schema_url applies to. |
| 136 | + /// |
| 137 | + /// This field obsoletes the schema_url field in ResourceMetrics/ResourceSpans/ResourceLogs. |
| 138 | + #[prost(string, tag = "1")] |
| 139 | + pub schema_url: ::prost::alloc::string::String, |
| 140 | + /// Defines the type of the entity. MUST not change during the lifetime of the entity. |
| 141 | + /// For example: "service" or "host". This field is required and MUST not be empty |
| 142 | + /// for valid entities. |
| 143 | + #[prost(string, tag = "2")] |
| 144 | + pub r#type: ::prost::alloc::string::String, |
| 145 | + /// Attribute Keys that identify the entity. |
| 146 | + /// MUST not change during the lifetime of the entity. The Id must contain at least one attribute. |
| 147 | + /// These keys MUST exist in the containing {message}.attributes. |
| 148 | + #[prost(string, repeated, tag = "3")] |
| 149 | + pub id_keys: ::prost::alloc::vec::Vec<::prost::alloc::string::String>, |
| 150 | + /// Descriptive (non-identifying) attribute keys of the entity. |
| 151 | + /// MAY change over the lifetime of the entity. MAY be empty. |
| 152 | + /// These attribute keys are not part of entity's identity. |
| 153 | + /// These keys MUST exist in the containing {message}.attributes. |
| 154 | + #[prost(string, repeated, tag = "4")] |
| 155 | + pub description_keys: ::prost::alloc::vec::Vec<::prost::alloc::string::String>, |
| 156 | +} |
| 157 | +/// ProcessContext represents the payload for the process context sharing mechanism. |
| 158 | +/// |
| 159 | +/// This message is designed to be published by OpenTelemetry SDKs via a memory-mapped |
| 160 | +/// region, allowing external readers (such as the OpenTelemetry eBPF Profiler) to |
| 161 | +/// discover and read resource attributes from instrumented processes without requiring |
| 162 | +/// direct integration or process activity. |
| 163 | +#[derive(Clone, PartialEq, ::prost::Message)] |
| 164 | +pub struct ProcessContext { |
| 165 | + /// The resource attributes describing this process. |
| 166 | + /// |
| 167 | + /// Attribute keys MUST be unique (it is not allowed to have more than one |
| 168 | + /// attribute with the same key). The behavior of software that receives |
| 169 | + /// duplicated keys can be unpredictable. |
| 170 | + /// |
| 171 | + /// Attributes SHOULD follow OpenTelemetry semantic conventions where applicable. |
| 172 | + /// See: <https://opentelemetry.io/docs/specs/semconv/> |
| 173 | + #[prost(message, optional, tag = "1")] |
| 174 | + pub resource: ::core::option::Option<super::super::resource::v1::Resource>, |
| 175 | + /// Additional attributes to share with external readers that are not part of |
| 176 | + /// the standard Resource. \[Optional\] |
| 177 | + /// |
| 178 | + /// This field allows publishers to include supplementary key-value pairs that |
| 179 | + /// may be useful for external readers but are not part of the SDK's configured |
| 180 | + /// Resource. |
| 181 | + /// |
| 182 | + /// Consider adding any keys here to the profiles semantic conventions in |
| 183 | + /// <https://opentelemetry.io/docs/specs/semconv/general/profiles/> |
| 184 | + #[prost(message, repeated, tag = "2")] |
| 185 | + pub extra_attributes: ::prost::alloc::vec::Vec<KeyValue>, |
| 186 | +} |
0 commit comments