From cdd7ad020e165fe680703b6d3319b908b682fb7a Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Fri, 20 Oct 2023 17:12:29 +0300 Subject: jaeger-client -> opentelemetry --- .../Proto/Logs/V1/InstrumentationLibraryLogs.php | 156 ++++++ .../Opentelemetry/Proto/Logs/V1/LogRecord.php | 541 +++++++++++++++++++++ .../Opentelemetry/Proto/Logs/V1/LogRecordFlags.php | 58 +++ .../Opentelemetry/Proto/Logs/V1/LogsData.php | 90 ++++ .../Opentelemetry/Proto/Logs/V1/ResourceLogs.php | 153 ++++++ .../Opentelemetry/Proto/Logs/V1/ScopeLogs.php | 153 ++++++ .../Opentelemetry/Proto/Logs/V1/SeverityNumber.php | 167 +++++++ 7 files changed, 1318 insertions(+) create mode 100644 vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/InstrumentationLibraryLogs.php create mode 100644 vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/LogRecord.php create mode 100644 vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/LogRecordFlags.php create mode 100644 vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/LogsData.php create mode 100644 vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/ResourceLogs.php create mode 100644 vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/ScopeLogs.php create mode 100644 vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/SeverityNumber.php (limited to 'vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1') diff --git a/vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/InstrumentationLibraryLogs.php b/vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/InstrumentationLibraryLogs.php new file mode 100644 index 000000000..e43654641 --- /dev/null +++ b/vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/InstrumentationLibraryLogs.php @@ -0,0 +1,156 @@ +opentelemetry.proto.logs.v1.InstrumentationLibraryLogs + */ +class InstrumentationLibraryLogs extends \Google\Protobuf\Internal\Message +{ + /** + * The instrumentation library information for the logs in this message. + * Semantically when InstrumentationLibrary isn't set, it is equivalent with + * an empty instrumentation library name (unknown). + * + * Generated from protobuf field .opentelemetry.proto.common.v1.InstrumentationLibrary instrumentation_library = 1; + */ + protected $instrumentation_library = null; + /** + * A list of logs that originate from an instrumentation library. + * + * Generated from protobuf field repeated .opentelemetry.proto.logs.v1.LogRecord log_records = 2; + */ + private $log_records; + /** + * This schema_url applies to all logs in the "logs" field. + * + * Generated from protobuf field string schema_url = 3; + */ + protected $schema_url = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Opentelemetry\Proto\Common\V1\InstrumentationLibrary $instrumentation_library + * The instrumentation library information for the logs in this message. + * Semantically when InstrumentationLibrary isn't set, it is equivalent with + * an empty instrumentation library name (unknown). + * @type \Opentelemetry\Proto\Logs\V1\LogRecord[]|\Google\Protobuf\Internal\RepeatedField $log_records + * A list of logs that originate from an instrumentation library. + * @type string $schema_url + * This schema_url applies to all logs in the "logs" field. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Opentelemetry\Proto\Logs\V1\Logs::initOnce(); + parent::__construct($data); + } + + /** + * The instrumentation library information for the logs in this message. + * Semantically when InstrumentationLibrary isn't set, it is equivalent with + * an empty instrumentation library name (unknown). + * + * Generated from protobuf field .opentelemetry.proto.common.v1.InstrumentationLibrary instrumentation_library = 1; + * @return \Opentelemetry\Proto\Common\V1\InstrumentationLibrary|null + */ + public function getInstrumentationLibrary() + { + return $this->instrumentation_library; + } + + public function hasInstrumentationLibrary() + { + return isset($this->instrumentation_library); + } + + public function clearInstrumentationLibrary() + { + unset($this->instrumentation_library); + } + + /** + * The instrumentation library information for the logs in this message. + * Semantically when InstrumentationLibrary isn't set, it is equivalent with + * an empty instrumentation library name (unknown). + * + * Generated from protobuf field .opentelemetry.proto.common.v1.InstrumentationLibrary instrumentation_library = 1; + * @param \Opentelemetry\Proto\Common\V1\InstrumentationLibrary $var + * @return $this + */ + public function setInstrumentationLibrary($var) + { + GPBUtil::checkMessage($var, \Opentelemetry\Proto\Common\V1\InstrumentationLibrary::class); + $this->instrumentation_library = $var; + + return $this; + } + + /** + * A list of logs that originate from an instrumentation library. + * + * Generated from protobuf field repeated .opentelemetry.proto.logs.v1.LogRecord log_records = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getLogRecords() + { + return $this->log_records; + } + + /** + * A list of logs that originate from an instrumentation library. + * + * Generated from protobuf field repeated .opentelemetry.proto.logs.v1.LogRecord log_records = 2; + * @param \Opentelemetry\Proto\Logs\V1\LogRecord[]|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setLogRecords($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Opentelemetry\Proto\Logs\V1\LogRecord::class); + $this->log_records = $arr; + + return $this; + } + + /** + * This schema_url applies to all logs in the "logs" field. + * + * Generated from protobuf field string schema_url = 3; + * @return string + */ + public function getSchemaUrl() + { + return $this->schema_url; + } + + /** + * This schema_url applies to all logs in the "logs" field. + * + * Generated from protobuf field string schema_url = 3; + * @param string $var + * @return $this + */ + public function setSchemaUrl($var) + { + GPBUtil::checkString($var, True); + $this->schema_url = $var; + + return $this; + } + +} + diff --git a/vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/LogRecord.php b/vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/LogRecord.php new file mode 100644 index 000000000..caca11f87 --- /dev/null +++ b/vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/LogRecord.php @@ -0,0 +1,541 @@ +opentelemetry.proto.logs.v1.LogRecord + */ +class LogRecord extends \Google\Protobuf\Internal\Message +{ + /** + * time_unix_nano is the time when the event occurred. + * Value is UNIX Epoch time in nanoseconds since 00:00:00 UTC on 1 January 1970. + * Value of 0 indicates unknown or missing timestamp. + * + * Generated from protobuf field fixed64 time_unix_nano = 1; + */ + protected $time_unix_nano = 0; + /** + * Time when the event was observed by the collection system. + * For events that originate in OpenTelemetry (e.g. using OpenTelemetry Logging SDK) + * this timestamp is typically set at the generation time and is equal to Timestamp. + * For events originating externally and collected by OpenTelemetry (e.g. using + * Collector) this is the time when OpenTelemetry's code observed the event measured + * by the clock of the OpenTelemetry code. This field MUST be set once the event is + * observed by OpenTelemetry. + * For converting OpenTelemetry log data to formats that support only one timestamp or + * when receiving OpenTelemetry log data by recipients that support only one timestamp + * internally the following logic is recommended: + * - Use time_unix_nano if it is present, otherwise use observed_time_unix_nano. + * Value is UNIX Epoch time in nanoseconds since 00:00:00 UTC on 1 January 1970. + * Value of 0 indicates unknown or missing timestamp. + * + * Generated from protobuf field fixed64 observed_time_unix_nano = 11; + */ + protected $observed_time_unix_nano = 0; + /** + * Numerical value of the severity, normalized to values described in Log Data Model. + * [Optional]. + * + * Generated from protobuf field .opentelemetry.proto.logs.v1.SeverityNumber severity_number = 2; + */ + protected $severity_number = 0; + /** + * The severity text (also known as log level). The original string representation as + * it is known at the source. [Optional]. + * + * Generated from protobuf field string severity_text = 3; + */ + protected $severity_text = ''; + /** + * A value containing the body of the log record. Can be for example a human-readable + * string message (including multi-line) describing the event in a free form or it can + * be a structured data composed of arrays and maps of other values. [Optional]. + * + * Generated from protobuf field .opentelemetry.proto.common.v1.AnyValue body = 5; + */ + protected $body = null; + /** + * Additional attributes that describe the specific event occurrence. [Optional]. + * Attribute keys MUST be unique (it is not allowed to have more than one + * attribute with the same key). + * + * Generated from protobuf field repeated .opentelemetry.proto.common.v1.KeyValue attributes = 6; + */ + private $attributes; + /** + * Generated from protobuf field uint32 dropped_attributes_count = 7; + */ + protected $dropped_attributes_count = 0; + /** + * Flags, a bit field. 8 least significant bits are the trace flags as + * defined in W3C Trace Context specification. 24 most significant bits are reserved + * and must be set to 0. Readers must not assume that 24 most significant bits + * will be zero and must correctly mask the bits when reading 8-bit trace flag (use + * flags & LOG_RECORD_FLAGS_TRACE_FLAGS_MASK). [Optional]. + * + * Generated from protobuf field fixed32 flags = 8; + */ + protected $flags = 0; + /** + * A unique identifier for a trace. All logs from the same trace share + * the same `trace_id`. The ID is a 16-byte array. An ID with all zeroes OR + * of length other than 16 bytes is considered invalid (empty string in OTLP/JSON + * is zero-length and thus is also invalid). + * This field is optional. + * The receivers SHOULD assume that the log record is not associated with a + * trace if any of the following is true: + * - the field is not present, + * - the field contains an invalid value. + * + * Generated from protobuf field bytes trace_id = 9; + */ + protected $trace_id = ''; + /** + * A unique identifier for a span within a trace, assigned when the span + * is created. The ID is an 8-byte array. An ID with all zeroes OR of length + * other than 8 bytes is considered invalid (empty string in OTLP/JSON + * is zero-length and thus is also invalid). + * This field is optional. If the sender specifies a valid span_id then it SHOULD also + * specify a valid trace_id. + * The receivers SHOULD assume that the log record is not associated with a + * span if any of the following is true: + * - the field is not present, + * - the field contains an invalid value. + * + * Generated from protobuf field bytes span_id = 10; + */ + protected $span_id = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $time_unix_nano + * time_unix_nano is the time when the event occurred. + * Value is UNIX Epoch time in nanoseconds since 00:00:00 UTC on 1 January 1970. + * Value of 0 indicates unknown or missing timestamp. + * @type int|string $observed_time_unix_nano + * Time when the event was observed by the collection system. + * For events that originate in OpenTelemetry (e.g. using OpenTelemetry Logging SDK) + * this timestamp is typically set at the generation time and is equal to Timestamp. + * For events originating externally and collected by OpenTelemetry (e.g. using + * Collector) this is the time when OpenTelemetry's code observed the event measured + * by the clock of the OpenTelemetry code. This field MUST be set once the event is + * observed by OpenTelemetry. + * For converting OpenTelemetry log data to formats that support only one timestamp or + * when receiving OpenTelemetry log data by recipients that support only one timestamp + * internally the following logic is recommended: + * - Use time_unix_nano if it is present, otherwise use observed_time_unix_nano. + * Value is UNIX Epoch time in nanoseconds since 00:00:00 UTC on 1 January 1970. + * Value of 0 indicates unknown or missing timestamp. + * @type int $severity_number + * Numerical value of the severity, normalized to values described in Log Data Model. + * [Optional]. + * @type string $severity_text + * The severity text (also known as log level). The original string representation as + * it is known at the source. [Optional]. + * @type \Opentelemetry\Proto\Common\V1\AnyValue $body + * A value containing the body of the log record. Can be for example a human-readable + * string message (including multi-line) describing the event in a free form or it can + * be a structured data composed of arrays and maps of other values. [Optional]. + * @type \Opentelemetry\Proto\Common\V1\KeyValue[]|\Google\Protobuf\Internal\RepeatedField $attributes + * Additional attributes that describe the specific event occurrence. [Optional]. + * Attribute keys MUST be unique (it is not allowed to have more than one + * attribute with the same key). + * @type int $dropped_attributes_count + * @type int $flags + * Flags, a bit field. 8 least significant bits are the trace flags as + * defined in W3C Trace Context specification. 24 most significant bits are reserved + * and must be set to 0. Readers must not assume that 24 most significant bits + * will be zero and must correctly mask the bits when reading 8-bit trace flag (use + * flags & LOG_RECORD_FLAGS_TRACE_FLAGS_MASK). [Optional]. + * @type string $trace_id + * A unique identifier for a trace. All logs from the same trace share + * the same `trace_id`. The ID is a 16-byte array. An ID with all zeroes OR + * of length other than 16 bytes is considered invalid (empty string in OTLP/JSON + * is zero-length and thus is also invalid). + * This field is optional. + * The receivers SHOULD assume that the log record is not associated with a + * trace if any of the following is true: + * - the field is not present, + * - the field contains an invalid value. + * @type string $span_id + * A unique identifier for a span within a trace, assigned when the span + * is created. The ID is an 8-byte array. An ID with all zeroes OR of length + * other than 8 bytes is considered invalid (empty string in OTLP/JSON + * is zero-length and thus is also invalid). + * This field is optional. If the sender specifies a valid span_id then it SHOULD also + * specify a valid trace_id. + * The receivers SHOULD assume that the log record is not associated with a + * span if any of the following is true: + * - the field is not present, + * - the field contains an invalid value. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Opentelemetry\Proto\Logs\V1\Logs::initOnce(); + parent::__construct($data); + } + + /** + * time_unix_nano is the time when the event occurred. + * Value is UNIX Epoch time in nanoseconds since 00:00:00 UTC on 1 January 1970. + * Value of 0 indicates unknown or missing timestamp. + * + * Generated from protobuf field fixed64 time_unix_nano = 1; + * @return int|string + */ + public function getTimeUnixNano() + { + return $this->time_unix_nano; + } + + /** + * time_unix_nano is the time when the event occurred. + * Value is UNIX Epoch time in nanoseconds since 00:00:00 UTC on 1 January 1970. + * Value of 0 indicates unknown or missing timestamp. + * + * Generated from protobuf field fixed64 time_unix_nano = 1; + * @param int|string $var + * @return $this + */ + public function setTimeUnixNano($var) + { + GPBUtil::checkUint64($var); + $this->time_unix_nano = $var; + + return $this; + } + + /** + * Time when the event was observed by the collection system. + * For events that originate in OpenTelemetry (e.g. using OpenTelemetry Logging SDK) + * this timestamp is typically set at the generation time and is equal to Timestamp. + * For events originating externally and collected by OpenTelemetry (e.g. using + * Collector) this is the time when OpenTelemetry's code observed the event measured + * by the clock of the OpenTelemetry code. This field MUST be set once the event is + * observed by OpenTelemetry. + * For converting OpenTelemetry log data to formats that support only one timestamp or + * when receiving OpenTelemetry log data by recipients that support only one timestamp + * internally the following logic is recommended: + * - Use time_unix_nano if it is present, otherwise use observed_time_unix_nano. + * Value is UNIX Epoch time in nanoseconds since 00:00:00 UTC on 1 January 1970. + * Value of 0 indicates unknown or missing timestamp. + * + * Generated from protobuf field fixed64 observed_time_unix_nano = 11; + * @return int|string + */ + public function getObservedTimeUnixNano() + { + return $this->observed_time_unix_nano; + } + + /** + * Time when the event was observed by the collection system. + * For events that originate in OpenTelemetry (e.g. using OpenTelemetry Logging SDK) + * this timestamp is typically set at the generation time and is equal to Timestamp. + * For events originating externally and collected by OpenTelemetry (e.g. using + * Collector) this is the time when OpenTelemetry's code observed the event measured + * by the clock of the OpenTelemetry code. This field MUST be set once the event is + * observed by OpenTelemetry. + * For converting OpenTelemetry log data to formats that support only one timestamp or + * when receiving OpenTelemetry log data by recipients that support only one timestamp + * internally the following logic is recommended: + * - Use time_unix_nano if it is present, otherwise use observed_time_unix_nano. + * Value is UNIX Epoch time in nanoseconds since 00:00:00 UTC on 1 January 1970. + * Value of 0 indicates unknown or missing timestamp. + * + * Generated from protobuf field fixed64 observed_time_unix_nano = 11; + * @param int|string $var + * @return $this + */ + public function setObservedTimeUnixNano($var) + { + GPBUtil::checkUint64($var); + $this->observed_time_unix_nano = $var; + + return $this; + } + + /** + * Numerical value of the severity, normalized to values described in Log Data Model. + * [Optional]. + * + * Generated from protobuf field .opentelemetry.proto.logs.v1.SeverityNumber severity_number = 2; + * @return int + */ + public function getSeverityNumber() + { + return $this->severity_number; + } + + /** + * Numerical value of the severity, normalized to values described in Log Data Model. + * [Optional]. + * + * Generated from protobuf field .opentelemetry.proto.logs.v1.SeverityNumber severity_number = 2; + * @param int $var + * @return $this + */ + public function setSeverityNumber($var) + { + GPBUtil::checkEnum($var, \Opentelemetry\Proto\Logs\V1\SeverityNumber::class); + $this->severity_number = $var; + + return $this; + } + + /** + * The severity text (also known as log level). The original string representation as + * it is known at the source. [Optional]. + * + * Generated from protobuf field string severity_text = 3; + * @return string + */ + public function getSeverityText() + { + return $this->severity_text; + } + + /** + * The severity text (also known as log level). The original string representation as + * it is known at the source. [Optional]. + * + * Generated from protobuf field string severity_text = 3; + * @param string $var + * @return $this + */ + public function setSeverityText($var) + { + GPBUtil::checkString($var, True); + $this->severity_text = $var; + + return $this; + } + + /** + * A value containing the body of the log record. Can be for example a human-readable + * string message (including multi-line) describing the event in a free form or it can + * be a structured data composed of arrays and maps of other values. [Optional]. + * + * Generated from protobuf field .opentelemetry.proto.common.v1.AnyValue body = 5; + * @return \Opentelemetry\Proto\Common\V1\AnyValue|null + */ + public function getBody() + { + return $this->body; + } + + public function hasBody() + { + return isset($this->body); + } + + public function clearBody() + { + unset($this->body); + } + + /** + * A value containing the body of the log record. Can be for example a human-readable + * string message (including multi-line) describing the event in a free form or it can + * be a structured data composed of arrays and maps of other values. [Optional]. + * + * Generated from protobuf field .opentelemetry.proto.common.v1.AnyValue body = 5; + * @param \Opentelemetry\Proto\Common\V1\AnyValue $var + * @return $this + */ + public function setBody($var) + { + GPBUtil::checkMessage($var, \Opentelemetry\Proto\Common\V1\AnyValue::class); + $this->body = $var; + + return $this; + } + + /** + * Additional attributes that describe the specific event occurrence. [Optional]. + * Attribute keys MUST be unique (it is not allowed to have more than one + * attribute with the same key). + * + * Generated from protobuf field repeated .opentelemetry.proto.common.v1.KeyValue attributes = 6; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAttributes() + { + return $this->attributes; + } + + /** + * Additional attributes that describe the specific event occurrence. [Optional]. + * Attribute keys MUST be unique (it is not allowed to have more than one + * attribute with the same key). + * + * Generated from protobuf field repeated .opentelemetry.proto.common.v1.KeyValue attributes = 6; + * @param \Opentelemetry\Proto\Common\V1\KeyValue[]|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAttributes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Opentelemetry\Proto\Common\V1\KeyValue::class); + $this->attributes = $arr; + + return $this; + } + + /** + * Generated from protobuf field uint32 dropped_attributes_count = 7; + * @return int + */ + public function getDroppedAttributesCount() + { + return $this->dropped_attributes_count; + } + + /** + * Generated from protobuf field uint32 dropped_attributes_count = 7; + * @param int $var + * @return $this + */ + public function setDroppedAttributesCount($var) + { + GPBUtil::checkUint32($var); + $this->dropped_attributes_count = $var; + + return $this; + } + + /** + * Flags, a bit field. 8 least significant bits are the trace flags as + * defined in W3C Trace Context specification. 24 most significant bits are reserved + * and must be set to 0. Readers must not assume that 24 most significant bits + * will be zero and must correctly mask the bits when reading 8-bit trace flag (use + * flags & LOG_RECORD_FLAGS_TRACE_FLAGS_MASK). [Optional]. + * + * Generated from protobuf field fixed32 flags = 8; + * @return int + */ + public function getFlags() + { + return $this->flags; + } + + /** + * Flags, a bit field. 8 least significant bits are the trace flags as + * defined in W3C Trace Context specification. 24 most significant bits are reserved + * and must be set to 0. Readers must not assume that 24 most significant bits + * will be zero and must correctly mask the bits when reading 8-bit trace flag (use + * flags & LOG_RECORD_FLAGS_TRACE_FLAGS_MASK). [Optional]. + * + * Generated from protobuf field fixed32 flags = 8; + * @param int $var + * @return $this + */ + public function setFlags($var) + { + GPBUtil::checkUint32($var); + $this->flags = $var; + + return $this; + } + + /** + * A unique identifier for a trace. All logs from the same trace share + * the same `trace_id`. The ID is a 16-byte array. An ID with all zeroes OR + * of length other than 16 bytes is considered invalid (empty string in OTLP/JSON + * is zero-length and thus is also invalid). + * This field is optional. + * The receivers SHOULD assume that the log record is not associated with a + * trace if any of the following is true: + * - the field is not present, + * - the field contains an invalid value. + * + * Generated from protobuf field bytes trace_id = 9; + * @return string + */ + public function getTraceId() + { + return $this->trace_id; + } + + /** + * A unique identifier for a trace. All logs from the same trace share + * the same `trace_id`. The ID is a 16-byte array. An ID with all zeroes OR + * of length other than 16 bytes is considered invalid (empty string in OTLP/JSON + * is zero-length and thus is also invalid). + * This field is optional. + * The receivers SHOULD assume that the log record is not associated with a + * trace if any of the following is true: + * - the field is not present, + * - the field contains an invalid value. + * + * Generated from protobuf field bytes trace_id = 9; + * @param string $var + * @return $this + */ + public function setTraceId($var) + { + GPBUtil::checkString($var, False); + $this->trace_id = $var; + + return $this; + } + + /** + * A unique identifier for a span within a trace, assigned when the span + * is created. The ID is an 8-byte array. An ID with all zeroes OR of length + * other than 8 bytes is considered invalid (empty string in OTLP/JSON + * is zero-length and thus is also invalid). + * This field is optional. If the sender specifies a valid span_id then it SHOULD also + * specify a valid trace_id. + * The receivers SHOULD assume that the log record is not associated with a + * span if any of the following is true: + * - the field is not present, + * - the field contains an invalid value. + * + * Generated from protobuf field bytes span_id = 10; + * @return string + */ + public function getSpanId() + { + return $this->span_id; + } + + /** + * A unique identifier for a span within a trace, assigned when the span + * is created. The ID is an 8-byte array. An ID with all zeroes OR of length + * other than 8 bytes is considered invalid (empty string in OTLP/JSON + * is zero-length and thus is also invalid). + * This field is optional. If the sender specifies a valid span_id then it SHOULD also + * specify a valid trace_id. + * The receivers SHOULD assume that the log record is not associated with a + * span if any of the following is true: + * - the field is not present, + * - the field contains an invalid value. + * + * Generated from protobuf field bytes span_id = 10; + * @param string $var + * @return $this + */ + public function setSpanId($var) + { + GPBUtil::checkString($var, False); + $this->span_id = $var; + + return $this; + } + +} + diff --git a/vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/LogRecordFlags.php b/vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/LogRecordFlags.php new file mode 100644 index 000000000..de6f38899 --- /dev/null +++ b/vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/LogRecordFlags.php @@ -0,0 +1,58 @@ +opentelemetry.proto.logs.v1.LogRecordFlags + */ +class LogRecordFlags +{ + /** + * The zero value for the enum. Should not be used for comparisons. + * Instead use bitwise "and" with the appropriate mask as shown above. + * + * Generated from protobuf enum LOG_RECORD_FLAGS_DO_NOT_USE = 0; + */ + const LOG_RECORD_FLAGS_DO_NOT_USE = 0; + /** + * Bits 0-7 are used for trace flags. + * + * Generated from protobuf enum LOG_RECORD_FLAGS_TRACE_FLAGS_MASK = 255; + */ + const LOG_RECORD_FLAGS_TRACE_FLAGS_MASK = 255; + + private static $valueToName = [ + self::LOG_RECORD_FLAGS_DO_NOT_USE => 'LOG_RECORD_FLAGS_DO_NOT_USE', + self::LOG_RECORD_FLAGS_TRACE_FLAGS_MASK => 'LOG_RECORD_FLAGS_TRACE_FLAGS_MASK', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + diff --git a/vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/LogsData.php b/vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/LogsData.php new file mode 100644 index 000000000..90db06035 --- /dev/null +++ b/vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/LogsData.php @@ -0,0 +1,90 @@ +opentelemetry.proto.logs.v1.LogsData + */ +class LogsData extends \Google\Protobuf\Internal\Message +{ + /** + * An array of ResourceLogs. + * For data coming from a single resource this array will typically contain + * one element. Intermediary nodes that receive data from multiple origins + * typically batch the data before forwarding further and in that case this + * array will contain multiple elements. + * + * Generated from protobuf field repeated .opentelemetry.proto.logs.v1.ResourceLogs resource_logs = 1; + */ + private $resource_logs; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Opentelemetry\Proto\Logs\V1\ResourceLogs[]|\Google\Protobuf\Internal\RepeatedField $resource_logs + * An array of ResourceLogs. + * For data coming from a single resource this array will typically contain + * one element. Intermediary nodes that receive data from multiple origins + * typically batch the data before forwarding further and in that case this + * array will contain multiple elements. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Opentelemetry\Proto\Logs\V1\Logs::initOnce(); + parent::__construct($data); + } + + /** + * An array of ResourceLogs. + * For data coming from a single resource this array will typically contain + * one element. Intermediary nodes that receive data from multiple origins + * typically batch the data before forwarding further and in that case this + * array will contain multiple elements. + * + * Generated from protobuf field repeated .opentelemetry.proto.logs.v1.ResourceLogs resource_logs = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getResourceLogs() + { + return $this->resource_logs; + } + + /** + * An array of ResourceLogs. + * For data coming from a single resource this array will typically contain + * one element. Intermediary nodes that receive data from multiple origins + * typically batch the data before forwarding further and in that case this + * array will contain multiple elements. + * + * Generated from protobuf field repeated .opentelemetry.proto.logs.v1.ResourceLogs resource_logs = 1; + * @param \Opentelemetry\Proto\Logs\V1\ResourceLogs[]|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setResourceLogs($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Opentelemetry\Proto\Logs\V1\ResourceLogs::class); + $this->resource_logs = $arr; + + return $this; + } + +} + diff --git a/vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/ResourceLogs.php b/vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/ResourceLogs.php new file mode 100644 index 000000000..2049339d4 --- /dev/null +++ b/vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/ResourceLogs.php @@ -0,0 +1,153 @@ +opentelemetry.proto.logs.v1.ResourceLogs + */ +class ResourceLogs extends \Google\Protobuf\Internal\Message +{ + /** + * The resource for the logs in this message. + * If this field is not set then resource info is unknown. + * + * Generated from protobuf field .opentelemetry.proto.resource.v1.Resource resource = 1; + */ + protected $resource = null; + /** + * A list of ScopeLogs that originate from a resource. + * + * Generated from protobuf field repeated .opentelemetry.proto.logs.v1.ScopeLogs scope_logs = 2; + */ + private $scope_logs; + /** + * This schema_url applies to the data in the "resource" field. It does not apply + * to the data in the "scope_logs" field which have their own schema_url field. + * + * Generated from protobuf field string schema_url = 3; + */ + protected $schema_url = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Opentelemetry\Proto\Resource\V1\Resource $resource + * The resource for the logs in this message. + * If this field is not set then resource info is unknown. + * @type \Opentelemetry\Proto\Logs\V1\ScopeLogs[]|\Google\Protobuf\Internal\RepeatedField $scope_logs + * A list of ScopeLogs that originate from a resource. + * @type string $schema_url + * This schema_url applies to the data in the "resource" field. It does not apply + * to the data in the "scope_logs" field which have their own schema_url field. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Opentelemetry\Proto\Logs\V1\Logs::initOnce(); + parent::__construct($data); + } + + /** + * The resource for the logs in this message. + * If this field is not set then resource info is unknown. + * + * Generated from protobuf field .opentelemetry.proto.resource.v1.Resource resource = 1; + * @return \Opentelemetry\Proto\Resource\V1\Resource|null + */ + public function getResource() + { + return $this->resource; + } + + public function hasResource() + { + return isset($this->resource); + } + + public function clearResource() + { + unset($this->resource); + } + + /** + * The resource for the logs in this message. + * If this field is not set then resource info is unknown. + * + * Generated from protobuf field .opentelemetry.proto.resource.v1.Resource resource = 1; + * @param \Opentelemetry\Proto\Resource\V1\Resource $var + * @return $this + */ + public function setResource($var) + { + GPBUtil::checkMessage($var, \Opentelemetry\Proto\Resource\V1\Resource::class); + $this->resource = $var; + + return $this; + } + + /** + * A list of ScopeLogs that originate from a resource. + * + * Generated from protobuf field repeated .opentelemetry.proto.logs.v1.ScopeLogs scope_logs = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getScopeLogs() + { + return $this->scope_logs; + } + + /** + * A list of ScopeLogs that originate from a resource. + * + * Generated from protobuf field repeated .opentelemetry.proto.logs.v1.ScopeLogs scope_logs = 2; + * @param \Opentelemetry\Proto\Logs\V1\ScopeLogs[]|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setScopeLogs($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Opentelemetry\Proto\Logs\V1\ScopeLogs::class); + $this->scope_logs = $arr; + + return $this; + } + + /** + * This schema_url applies to the data in the "resource" field. It does not apply + * to the data in the "scope_logs" field which have their own schema_url field. + * + * Generated from protobuf field string schema_url = 3; + * @return string + */ + public function getSchemaUrl() + { + return $this->schema_url; + } + + /** + * This schema_url applies to the data in the "resource" field. It does not apply + * to the data in the "scope_logs" field which have their own schema_url field. + * + * Generated from protobuf field string schema_url = 3; + * @param string $var + * @return $this + */ + public function setSchemaUrl($var) + { + GPBUtil::checkString($var, True); + $this->schema_url = $var; + + return $this; + } + +} + diff --git a/vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/ScopeLogs.php b/vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/ScopeLogs.php new file mode 100644 index 000000000..8c5a94821 --- /dev/null +++ b/vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/ScopeLogs.php @@ -0,0 +1,153 @@ +opentelemetry.proto.logs.v1.ScopeLogs + */ +class ScopeLogs extends \Google\Protobuf\Internal\Message +{ + /** + * The instrumentation scope information for the logs in this message. + * Semantically when InstrumentationScope isn't set, it is equivalent with + * an empty instrumentation scope name (unknown). + * + * Generated from protobuf field .opentelemetry.proto.common.v1.InstrumentationScope scope = 1; + */ + protected $scope = null; + /** + * A list of log records. + * + * Generated from protobuf field repeated .opentelemetry.proto.logs.v1.LogRecord log_records = 2; + */ + private $log_records; + /** + * This schema_url applies to all logs in the "logs" field. + * + * Generated from protobuf field string schema_url = 3; + */ + protected $schema_url = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Opentelemetry\Proto\Common\V1\InstrumentationScope $scope + * The instrumentation scope information for the logs in this message. + * Semantically when InstrumentationScope isn't set, it is equivalent with + * an empty instrumentation scope name (unknown). + * @type \Opentelemetry\Proto\Logs\V1\LogRecord[]|\Google\Protobuf\Internal\RepeatedField $log_records + * A list of log records. + * @type string $schema_url + * This schema_url applies to all logs in the "logs" field. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Opentelemetry\Proto\Logs\V1\Logs::initOnce(); + parent::__construct($data); + } + + /** + * The instrumentation scope information for the logs in this message. + * Semantically when InstrumentationScope isn't set, it is equivalent with + * an empty instrumentation scope name (unknown). + * + * Generated from protobuf field .opentelemetry.proto.common.v1.InstrumentationScope scope = 1; + * @return \Opentelemetry\Proto\Common\V1\InstrumentationScope|null + */ + public function getScope() + { + return $this->scope; + } + + public function hasScope() + { + return isset($this->scope); + } + + public function clearScope() + { + unset($this->scope); + } + + /** + * The instrumentation scope information for the logs in this message. + * Semantically when InstrumentationScope isn't set, it is equivalent with + * an empty instrumentation scope name (unknown). + * + * Generated from protobuf field .opentelemetry.proto.common.v1.InstrumentationScope scope = 1; + * @param \Opentelemetry\Proto\Common\V1\InstrumentationScope $var + * @return $this + */ + public function setScope($var) + { + GPBUtil::checkMessage($var, \Opentelemetry\Proto\Common\V1\InstrumentationScope::class); + $this->scope = $var; + + return $this; + } + + /** + * A list of log records. + * + * Generated from protobuf field repeated .opentelemetry.proto.logs.v1.LogRecord log_records = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getLogRecords() + { + return $this->log_records; + } + + /** + * A list of log records. + * + * Generated from protobuf field repeated .opentelemetry.proto.logs.v1.LogRecord log_records = 2; + * @param \Opentelemetry\Proto\Logs\V1\LogRecord[]|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setLogRecords($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Opentelemetry\Proto\Logs\V1\LogRecord::class); + $this->log_records = $arr; + + return $this; + } + + /** + * This schema_url applies to all logs in the "logs" field. + * + * Generated from protobuf field string schema_url = 3; + * @return string + */ + public function getSchemaUrl() + { + return $this->schema_url; + } + + /** + * This schema_url applies to all logs in the "logs" field. + * + * Generated from protobuf field string schema_url = 3; + * @param string $var + * @return $this + */ + public function setSchemaUrl($var) + { + GPBUtil::checkString($var, True); + $this->schema_url = $var; + + return $this; + } + +} + diff --git a/vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/SeverityNumber.php b/vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/SeverityNumber.php new file mode 100644 index 000000000..ad89442b0 --- /dev/null +++ b/vendor/open-telemetry/gen-otlp-protobuf/Opentelemetry/Proto/Logs/V1/SeverityNumber.php @@ -0,0 +1,167 @@ +opentelemetry.proto.logs.v1.SeverityNumber + */ +class SeverityNumber +{ + /** + * UNSPECIFIED is the default SeverityNumber, it MUST NOT be used. + * + * Generated from protobuf enum SEVERITY_NUMBER_UNSPECIFIED = 0; + */ + const SEVERITY_NUMBER_UNSPECIFIED = 0; + /** + * Generated from protobuf enum SEVERITY_NUMBER_TRACE = 1; + */ + const SEVERITY_NUMBER_TRACE = 1; + /** + * Generated from protobuf enum SEVERITY_NUMBER_TRACE2 = 2; + */ + const SEVERITY_NUMBER_TRACE2 = 2; + /** + * Generated from protobuf enum SEVERITY_NUMBER_TRACE3 = 3; + */ + const SEVERITY_NUMBER_TRACE3 = 3; + /** + * Generated from protobuf enum SEVERITY_NUMBER_TRACE4 = 4; + */ + const SEVERITY_NUMBER_TRACE4 = 4; + /** + * Generated from protobuf enum SEVERITY_NUMBER_DEBUG = 5; + */ + const SEVERITY_NUMBER_DEBUG = 5; + /** + * Generated from protobuf enum SEVERITY_NUMBER_DEBUG2 = 6; + */ + const SEVERITY_NUMBER_DEBUG2 = 6; + /** + * Generated from protobuf enum SEVERITY_NUMBER_DEBUG3 = 7; + */ + const SEVERITY_NUMBER_DEBUG3 = 7; + /** + * Generated from protobuf enum SEVERITY_NUMBER_DEBUG4 = 8; + */ + const SEVERITY_NUMBER_DEBUG4 = 8; + /** + * Generated from protobuf enum SEVERITY_NUMBER_INFO = 9; + */ + const SEVERITY_NUMBER_INFO = 9; + /** + * Generated from protobuf enum SEVERITY_NUMBER_INFO2 = 10; + */ + const SEVERITY_NUMBER_INFO2 = 10; + /** + * Generated from protobuf enum SEVERITY_NUMBER_INFO3 = 11; + */ + const SEVERITY_NUMBER_INFO3 = 11; + /** + * Generated from protobuf enum SEVERITY_NUMBER_INFO4 = 12; + */ + const SEVERITY_NUMBER_INFO4 = 12; + /** + * Generated from protobuf enum SEVERITY_NUMBER_WARN = 13; + */ + const SEVERITY_NUMBER_WARN = 13; + /** + * Generated from protobuf enum SEVERITY_NUMBER_WARN2 = 14; + */ + const SEVERITY_NUMBER_WARN2 = 14; + /** + * Generated from protobuf enum SEVERITY_NUMBER_WARN3 = 15; + */ + const SEVERITY_NUMBER_WARN3 = 15; + /** + * Generated from protobuf enum SEVERITY_NUMBER_WARN4 = 16; + */ + const SEVERITY_NUMBER_WARN4 = 16; + /** + * Generated from protobuf enum SEVERITY_NUMBER_ERROR = 17; + */ + const SEVERITY_NUMBER_ERROR = 17; + /** + * Generated from protobuf enum SEVERITY_NUMBER_ERROR2 = 18; + */ + const SEVERITY_NUMBER_ERROR2 = 18; + /** + * Generated from protobuf enum SEVERITY_NUMBER_ERROR3 = 19; + */ + const SEVERITY_NUMBER_ERROR3 = 19; + /** + * Generated from protobuf enum SEVERITY_NUMBER_ERROR4 = 20; + */ + const SEVERITY_NUMBER_ERROR4 = 20; + /** + * Generated from protobuf enum SEVERITY_NUMBER_FATAL = 21; + */ + const SEVERITY_NUMBER_FATAL = 21; + /** + * Generated from protobuf enum SEVERITY_NUMBER_FATAL2 = 22; + */ + const SEVERITY_NUMBER_FATAL2 = 22; + /** + * Generated from protobuf enum SEVERITY_NUMBER_FATAL3 = 23; + */ + const SEVERITY_NUMBER_FATAL3 = 23; + /** + * Generated from protobuf enum SEVERITY_NUMBER_FATAL4 = 24; + */ + const SEVERITY_NUMBER_FATAL4 = 24; + + private static $valueToName = [ + self::SEVERITY_NUMBER_UNSPECIFIED => 'SEVERITY_NUMBER_UNSPECIFIED', + self::SEVERITY_NUMBER_TRACE => 'SEVERITY_NUMBER_TRACE', + self::SEVERITY_NUMBER_TRACE2 => 'SEVERITY_NUMBER_TRACE2', + self::SEVERITY_NUMBER_TRACE3 => 'SEVERITY_NUMBER_TRACE3', + self::SEVERITY_NUMBER_TRACE4 => 'SEVERITY_NUMBER_TRACE4', + self::SEVERITY_NUMBER_DEBUG => 'SEVERITY_NUMBER_DEBUG', + self::SEVERITY_NUMBER_DEBUG2 => 'SEVERITY_NUMBER_DEBUG2', + self::SEVERITY_NUMBER_DEBUG3 => 'SEVERITY_NUMBER_DEBUG3', + self::SEVERITY_NUMBER_DEBUG4 => 'SEVERITY_NUMBER_DEBUG4', + self::SEVERITY_NUMBER_INFO => 'SEVERITY_NUMBER_INFO', + self::SEVERITY_NUMBER_INFO2 => 'SEVERITY_NUMBER_INFO2', + self::SEVERITY_NUMBER_INFO3 => 'SEVERITY_NUMBER_INFO3', + self::SEVERITY_NUMBER_INFO4 => 'SEVERITY_NUMBER_INFO4', + self::SEVERITY_NUMBER_WARN => 'SEVERITY_NUMBER_WARN', + self::SEVERITY_NUMBER_WARN2 => 'SEVERITY_NUMBER_WARN2', + self::SEVERITY_NUMBER_WARN3 => 'SEVERITY_NUMBER_WARN3', + self::SEVERITY_NUMBER_WARN4 => 'SEVERITY_NUMBER_WARN4', + self::SEVERITY_NUMBER_ERROR => 'SEVERITY_NUMBER_ERROR', + self::SEVERITY_NUMBER_ERROR2 => 'SEVERITY_NUMBER_ERROR2', + self::SEVERITY_NUMBER_ERROR3 => 'SEVERITY_NUMBER_ERROR3', + self::SEVERITY_NUMBER_ERROR4 => 'SEVERITY_NUMBER_ERROR4', + self::SEVERITY_NUMBER_FATAL => 'SEVERITY_NUMBER_FATAL', + self::SEVERITY_NUMBER_FATAL2 => 'SEVERITY_NUMBER_FATAL2', + self::SEVERITY_NUMBER_FATAL3 => 'SEVERITY_NUMBER_FATAL3', + self::SEVERITY_NUMBER_FATAL4 => 'SEVERITY_NUMBER_FATAL4', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + -- cgit v1.2.3