diff --git a/GPBMetadata/Opentelemetry/Proto/Logs/V1/Logs.php b/GPBMetadata/Opentelemetry/Proto/Logs/V1/Logs.php index e3ce8d4..9af0fcc 100644 Binary files a/GPBMetadata/Opentelemetry/Proto/Logs/V1/Logs.php and b/GPBMetadata/Opentelemetry/Proto/Logs/V1/Logs.php differ diff --git a/GPBMetadata/Opentelemetry/Proto/Metrics/V1/Metrics.php b/GPBMetadata/Opentelemetry/Proto/Metrics/V1/Metrics.php index 3da1638..cbb0950 100644 Binary files a/GPBMetadata/Opentelemetry/Proto/Metrics/V1/Metrics.php and b/GPBMetadata/Opentelemetry/Proto/Metrics/V1/Metrics.php differ diff --git a/Opentelemetry/Proto/Common/V1/InstrumentationScope.php b/Opentelemetry/Proto/Common/V1/InstrumentationScope.php index aa84bbe..d2b4b6f 100644 --- a/Opentelemetry/Proto/Common/V1/InstrumentationScope.php +++ b/Opentelemetry/Proto/Common/V1/InstrumentationScope.php @@ -27,6 +27,10 @@ class InstrumentationScope extends \Google\Protobuf\Internal\Message */ protected $version = ''; /** + * Additional attributes that describe the scope. [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 = 3; */ private $attributes; @@ -45,6 +49,9 @@ class InstrumentationScope extends \Google\Protobuf\Internal\Message * An empty instrumentation scope name means the name is unknown. * @type string $version * @type \Opentelemetry\Proto\Common\V1\KeyValue[]|\Google\Protobuf\Internal\RepeatedField $attributes + * Additional attributes that describe the scope. [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 * } */ @@ -102,6 +109,10 @@ public function setVersion($var) } /** + * Additional attributes that describe the scope. [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 = 3; * @return \Google\Protobuf\Internal\RepeatedField */ @@ -111,6 +122,10 @@ public function getAttributes() } /** + * Additional attributes that describe the scope. [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 = 3; * @param \Opentelemetry\Proto\Common\V1\KeyValue[]|\Google\Protobuf\Internal\RepeatedField $var * @return $this diff --git a/Opentelemetry/Proto/Logs/V1/LogRecord.php b/Opentelemetry/Proto/Logs/V1/LogRecord.php index e05c106..caca11f 100644 --- a/Opentelemetry/Proto/Logs/V1/LogRecord.php +++ b/Opentelemetry/Proto/Logs/V1/LogRecord.php @@ -81,25 +81,36 @@ class LogRecord extends \Google\Protobuf\Internal\Message * 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 & TRACE_FLAGS_MASK). [Optional]. + * 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 - * is considered invalid. Can be set for logs that are part of request processing - * and have an assigned trace id. [Optional]. + * 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 is considered - * invalid. Can be set for logs that are part of a particular processing span. - * If span_id is present trace_id SHOULD be also present. [Optional]. + * 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; */ @@ -149,17 +160,28 @@ class LogRecord extends \Google\Protobuf\Internal\Message * 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 & TRACE_FLAGS_MASK). [Optional]. + * 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 - * is considered invalid. Can be set for logs that are part of request processing - * and have an assigned trace id. [Optional]. + * 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 is considered - * invalid. Can be set for logs that are part of a particular processing span. - * If span_id is present trace_id SHOULD be also present. [Optional]. + * 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) { @@ -400,7 +422,7 @@ public function setDroppedAttributesCount($var) * 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 & TRACE_FLAGS_MASK). [Optional]. + * flags & LOG_RECORD_FLAGS_TRACE_FLAGS_MASK). [Optional]. * * Generated from protobuf field fixed32 flags = 8; * @return int @@ -415,7 +437,7 @@ public function getFlags() * 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 & TRACE_FLAGS_MASK). [Optional]. + * flags & LOG_RECORD_FLAGS_TRACE_FLAGS_MASK). [Optional]. * * Generated from protobuf field fixed32 flags = 8; * @param int $var @@ -431,9 +453,14 @@ public function setFlags($var) /** * 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 - * is considered invalid. Can be set for logs that are part of request processing - * and have an assigned trace id. [Optional]. + * 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 @@ -445,9 +472,14 @@ public function getTraceId() /** * 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 - * is considered invalid. Can be set for logs that are part of request processing - * and have an assigned trace id. [Optional]. + * 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 @@ -463,9 +495,15 @@ public function setTraceId($var) /** * 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 is considered - * invalid. Can be set for logs that are part of a particular processing span. - * If span_id is present trace_id SHOULD be also present. [Optional]. + * 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 @@ -477,9 +515,15 @@ public function getSpanId() /** * 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 is considered - * invalid. Can be set for logs that are part of a particular processing span. - * If span_id is present trace_id SHOULD be also present. [Optional]. + * 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 diff --git a/Opentelemetry/Proto/Logs/V1/LogRecordFlags.php b/Opentelemetry/Proto/Logs/V1/LogRecordFlags.php index 9927400..de6f388 100644 --- a/Opentelemetry/Proto/Logs/V1/LogRecordFlags.php +++ b/Opentelemetry/Proto/Logs/V1/LogRecordFlags.php @@ -7,24 +7,32 @@ use UnexpectedValueException; /** - * Masks for LogRecord.flags field. + * LogRecordFlags is defined as a protobuf 'uint32' type and is to be used as + * bit-fields. Each non-zero value defined in this enum is a bit-mask. + * To extract the bit-field, for example, use an expression like: + * (logRecord.flags & LOG_RECORD_FLAGS_TRACE_FLAGS_MASK) * * Protobuf type opentelemetry.proto.logs.v1.LogRecordFlags */ class LogRecordFlags { /** - * Generated from protobuf enum LOG_RECORD_FLAG_UNSPECIFIED = 0; + * 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_FLAG_UNSPECIFIED = 0; + const LOG_RECORD_FLAGS_DO_NOT_USE = 0; /** - * Generated from protobuf enum LOG_RECORD_FLAG_TRACE_FLAGS_MASK = 255; + * Bits 0-7 are used for trace flags. + * + * Generated from protobuf enum LOG_RECORD_FLAGS_TRACE_FLAGS_MASK = 255; */ - const LOG_RECORD_FLAG_TRACE_FLAGS_MASK = 255; + const LOG_RECORD_FLAGS_TRACE_FLAGS_MASK = 255; private static $valueToName = [ - self::LOG_RECORD_FLAG_UNSPECIFIED => 'LOG_RECORD_FLAG_UNSPECIFIED', - self::LOG_RECORD_FLAG_TRACE_FLAGS_MASK => 'LOG_RECORD_FLAG_TRACE_FLAGS_MASK', + 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) diff --git a/Opentelemetry/Proto/Metrics/V1/DataPointFlags.php b/Opentelemetry/Proto/Metrics/V1/DataPointFlags.php index f0f082b..f11029d 100644 --- a/Opentelemetry/Proto/Metrics/V1/DataPointFlags.php +++ b/Opentelemetry/Proto/Metrics/V1/DataPointFlags.php @@ -11,28 +11,31 @@ * bit-field representing 32 distinct boolean flags. Each flag defined in this * enum is a bit-mask. To test the presence of a single flag in the flags of * a data point, for example, use an expression like: - * (point.flags & FLAG_NO_RECORDED_VALUE) == FLAG_NO_RECORDED_VALUE + * (point.flags & DATA_POINT_FLAGS_NO_RECORDED_VALUE_MASK) == DATA_POINT_FLAGS_NO_RECORDED_VALUE_MASK * * Protobuf type opentelemetry.proto.metrics.v1.DataPointFlags */ class DataPointFlags { /** - * Generated from protobuf enum FLAG_NONE = 0; + * 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 DATA_POINT_FLAGS_DO_NOT_USE = 0; */ - const FLAG_NONE = 0; + const DATA_POINT_FLAGS_DO_NOT_USE = 0; /** * This DataPoint is valid but has no recorded value. This value * SHOULD be used to reflect explicitly missing data in a series, as * for an equivalent to the Prometheus "staleness marker". * - * Generated from protobuf enum FLAG_NO_RECORDED_VALUE = 1; + * Generated from protobuf enum DATA_POINT_FLAGS_NO_RECORDED_VALUE_MASK = 1; */ - const FLAG_NO_RECORDED_VALUE = 1; + const DATA_POINT_FLAGS_NO_RECORDED_VALUE_MASK = 1; private static $valueToName = [ - self::FLAG_NONE => 'FLAG_NONE', - self::FLAG_NO_RECORDED_VALUE => 'FLAG_NO_RECORDED_VALUE', + self::DATA_POINT_FLAGS_DO_NOT_USE => 'DATA_POINT_FLAGS_DO_NOT_USE', + self::DATA_POINT_FLAGS_NO_RECORDED_VALUE_MASK => 'DATA_POINT_FLAGS_NO_RECORDED_VALUE_MASK', ]; public static function name($value) diff --git a/Opentelemetry/Proto/Metrics/V1/ExponentialHistogramDataPoint.php b/Opentelemetry/Proto/Metrics/V1/ExponentialHistogramDataPoint.php index 64dde2e..62cb6f5 100644 --- a/Opentelemetry/Proto/Metrics/V1/ExponentialHistogramDataPoint.php +++ b/Opentelemetry/Proto/Metrics/V1/ExponentialHistogramDataPoint.php @@ -69,8 +69,8 @@ class ExponentialHistogramDataPoint extends \Google\Protobuf\Internal\Message * located at powers of the base, where: * base = (2^(2^-scale)) * The histogram bucket identified by `index`, a signed integer, - * contains values that are greater than or equal to (base^index) and - * less than (base^(index+1)). + * contains values that are greater than (base^index) and + * less than or equal to (base^(index+1)). * The positive and negative ranges of the histogram are expressed * separately. Negative values are mapped by their absolute value * into the negative range using the same scale as the positive range. @@ -130,6 +130,17 @@ class ExponentialHistogramDataPoint extends \Google\Protobuf\Internal\Message * Generated from protobuf field optional double max = 13; */ protected $max = null; + /** + * ZeroThreshold may be optionally set to convey the width of the zero + * region. Where the zero region is defined as the closed interval + * [-ZeroThreshold, ZeroThreshold]. + * When ZeroThreshold is 0, zero count bucket stores values that cannot be + * expressed using the standard exponential formula as well as values that + * have been rounded to zero. + * + * Generated from protobuf field double zero_threshold = 14; + */ + protected $zero_threshold = 0.0; /** * Constructor. @@ -168,8 +179,8 @@ class ExponentialHistogramDataPoint extends \Google\Protobuf\Internal\Message * located at powers of the base, where: * base = (2^(2^-scale)) * The histogram bucket identified by `index`, a signed integer, - * contains values that are greater than or equal to (base^index) and - * less than (base^(index+1)). + * contains values that are greater than (base^index) and + * less than or equal to (base^(index+1)). * The positive and negative ranges of the histogram are expressed * separately. Negative values are mapped by their absolute value * into the negative range using the same scale as the positive range. @@ -197,6 +208,13 @@ class ExponentialHistogramDataPoint extends \Google\Protobuf\Internal\Message * min is the minimum value over (start_time, end_time]. * @type float $max * max is the maximum value over (start_time, end_time]. + * @type float $zero_threshold + * ZeroThreshold may be optionally set to convey the width of the zero + * region. Where the zero region is defined as the closed interval + * [-ZeroThreshold, ZeroThreshold]. + * When ZeroThreshold is 0, zero count bucket stores values that cannot be + * expressed using the standard exponential formula as well as values that + * have been rounded to zero. * } */ public function __construct($data = NULL) { @@ -381,8 +399,8 @@ public function setSum($var) * located at powers of the base, where: * base = (2^(2^-scale)) * The histogram bucket identified by `index`, a signed integer, - * contains values that are greater than or equal to (base^index) and - * less than (base^(index+1)). + * contains values that are greater than (base^index) and + * less than or equal to (base^(index+1)). * The positive and negative ranges of the histogram are expressed * separately. Negative values are mapped by their absolute value * into the negative range using the same scale as the positive range. @@ -402,8 +420,8 @@ public function getScale() * located at powers of the base, where: * base = (2^(2^-scale)) * The histogram bucket identified by `index`, a signed integer, - * contains values that are greater than or equal to (base^index) and - * less than (base^(index+1)). + * contains values that are greater than (base^index) and + * less than or equal to (base^(index+1)). * The positive and negative ranges of the histogram are expressed * separately. Negative values are mapped by their absolute value * into the negative range using the same scale as the positive range. @@ -660,5 +678,41 @@ public function setMax($var) return $this; } + /** + * ZeroThreshold may be optionally set to convey the width of the zero + * region. Where the zero region is defined as the closed interval + * [-ZeroThreshold, ZeroThreshold]. + * When ZeroThreshold is 0, zero count bucket stores values that cannot be + * expressed using the standard exponential formula as well as values that + * have been rounded to zero. + * + * Generated from protobuf field double zero_threshold = 14; + * @return float + */ + public function getZeroThreshold() + { + return $this->zero_threshold; + } + + /** + * ZeroThreshold may be optionally set to convey the width of the zero + * region. Where the zero region is defined as the closed interval + * [-ZeroThreshold, ZeroThreshold]. + * When ZeroThreshold is 0, zero count bucket stores values that cannot be + * expressed using the standard exponential formula as well as values that + * have been rounded to zero. + * + * Generated from protobuf field double zero_threshold = 14; + * @param float $var + * @return $this + */ + public function setZeroThreshold($var) + { + GPBUtil::checkDouble($var); + $this->zero_threshold = $var; + + return $this; + } + } diff --git a/Opentelemetry/Proto/Metrics/V1/ExponentialHistogramDataPoint/Buckets.php b/Opentelemetry/Proto/Metrics/V1/ExponentialHistogramDataPoint/Buckets.php index b9e7f01..e1a90a3 100644 --- a/Opentelemetry/Proto/Metrics/V1/ExponentialHistogramDataPoint/Buckets.php +++ b/Opentelemetry/Proto/Metrics/V1/ExponentialHistogramDataPoint/Buckets.php @@ -25,9 +25,9 @@ class Buckets extends \Google\Protobuf\Internal\Message */ protected $offset = 0; /** - * Count is an array of counts, where count[i] carries the count - * of the bucket at index (offset+i). count[i] is the count of - * values greater than or equal to base^(offset+i) and less than + * bucket_counts is an array of count values, where bucket_counts[i] carries + * the count of the bucket at index (offset+i). bucket_counts[i] is the count + * of values greater than base^(offset+i) and less than or equal to * base^(offset+i+1). * Note: By contrast, the explicit HistogramDataPoint uses * fixed64. This field is expected to have many buckets, @@ -49,9 +49,9 @@ class Buckets extends \Google\Protobuf\Internal\Message * * Note: This uses a varint encoding as a simple form of compression. * @type int[]|string[]|\Google\Protobuf\Internal\RepeatedField $bucket_counts - * Count is an array of counts, where count[i] carries the count - * of the bucket at index (offset+i). count[i] is the count of - * values greater than or equal to base^(offset+i) and less than + * bucket_counts is an array of count values, where bucket_counts[i] carries + * the count of the bucket at index (offset+i). bucket_counts[i] is the count + * of values greater than base^(offset+i) and less than or equal to * base^(offset+i+1). * Note: By contrast, the explicit HistogramDataPoint uses * fixed64. This field is expected to have many buckets, @@ -95,9 +95,9 @@ public function setOffset($var) } /** - * Count is an array of counts, where count[i] carries the count - * of the bucket at index (offset+i). count[i] is the count of - * values greater than or equal to base^(offset+i) and less than + * bucket_counts is an array of count values, where bucket_counts[i] carries + * the count of the bucket at index (offset+i). bucket_counts[i] is the count + * of values greater than base^(offset+i) and less than or equal to * base^(offset+i+1). * Note: By contrast, the explicit HistogramDataPoint uses * fixed64. This field is expected to have many buckets, @@ -113,9 +113,9 @@ public function getBucketCounts() } /** - * Count is an array of counts, where count[i] carries the count - * of the bucket at index (offset+i). count[i] is the count of - * values greater than or equal to base^(offset+i) and less than + * bucket_counts is an array of count values, where bucket_counts[i] carries + * the count of the bucket at index (offset+i). bucket_counts[i] is the count + * of values greater than base^(offset+i) and less than or equal to * base^(offset+i+1). * Note: By contrast, the explicit HistogramDataPoint uses * fixed64. This field is expected to have many buckets, diff --git a/Opentelemetry/Proto/Trace/V1/Span.php b/Opentelemetry/Proto/Trace/V1/Span.php index d9da35c..4b1dc13 100644 --- a/Opentelemetry/Proto/Trace/V1/Span.php +++ b/Opentelemetry/Proto/Trace/V1/Span.php @@ -18,10 +18,9 @@ class Span extends \Google\Protobuf\Internal\Message { /** * A unique identifier for a trace. All spans from the same trace share - * the same `trace_id`. The ID is a 16-byte array. An ID with all zeroes - * is considered invalid. - * This field is semantically required. Receiver should generate new - * random trace_id if empty or invalid trace_id was received. + * 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 required. * * Generated from protobuf field bytes trace_id = 1; @@ -29,10 +28,9 @@ class Span extends \Google\Protobuf\Internal\Message 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 is considered - * invalid. - * This field is semantically required. Receiver should generate new - * random span_id if empty or invalid span_id was received. + * 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 required. * * Generated from protobuf field bytes span_id = 2; @@ -99,8 +97,8 @@ class Span extends \Google\Protobuf\Internal\Message * like server name can be set using the resource API. Examples of attributes: * "/http/user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36" * "/http/server_latency": 300 - * "abc.com/myattribute": true - * "abc.com/score": 10.239 + * "example.com/myattribute": true + * "example.com/score": 10.239 * The OpenTelemetry API specification further restricts the allowed value types: * https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/common/README.md#attribute * Attribute keys MUST be unique (it is not allowed to have more than one @@ -160,17 +158,15 @@ class Span extends \Google\Protobuf\Internal\Message * * @type string $trace_id * A unique identifier for a trace. All spans from the same trace share - * the same `trace_id`. The ID is a 16-byte array. An ID with all zeroes - * is considered invalid. - * This field is semantically required. Receiver should generate new - * random trace_id if empty or invalid trace_id was received. + * 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 required. * @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 is considered - * invalid. - * This field is semantically required. Receiver should generate new - * random span_id if empty or invalid span_id was received. + * 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 required. * @type string $trace_state * trace_state conveys information about request position in multiple distributed tracing graphs. @@ -209,8 +205,8 @@ class Span extends \Google\Protobuf\Internal\Message * like server name can be set using the resource API. Examples of attributes: * "/http/user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36" * "/http/server_latency": 300 - * "abc.com/myattribute": true - * "abc.com/score": 10.239 + * "example.com/myattribute": true + * "example.com/score": 10.239 * The OpenTelemetry API specification further restricts the allowed value types: * https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/common/README.md#attribute * Attribute keys MUST be unique (it is not allowed to have more than one @@ -242,10 +238,9 @@ public function __construct($data = NULL) { /** * A unique identifier for a trace. All spans from the same trace share - * the same `trace_id`. The ID is a 16-byte array. An ID with all zeroes - * is considered invalid. - * This field is semantically required. Receiver should generate new - * random trace_id if empty or invalid trace_id was received. + * 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 required. * * Generated from protobuf field bytes trace_id = 1; @@ -258,10 +253,9 @@ public function getTraceId() /** * A unique identifier for a trace. All spans from the same trace share - * the same `trace_id`. The ID is a 16-byte array. An ID with all zeroes - * is considered invalid. - * This field is semantically required. Receiver should generate new - * random trace_id if empty or invalid trace_id was received. + * 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 required. * * Generated from protobuf field bytes trace_id = 1; @@ -278,10 +272,9 @@ public function setTraceId($var) /** * 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 is considered - * invalid. - * This field is semantically required. Receiver should generate new - * random span_id if empty or invalid span_id was received. + * 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 required. * * Generated from protobuf field bytes span_id = 2; @@ -294,10 +287,9 @@ public function getSpanId() /** * 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 is considered - * invalid. - * This field is semantically required. Receiver should generate new - * random span_id if empty or invalid span_id was received. + * 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 required. * * Generated from protobuf field bytes span_id = 2; @@ -513,8 +505,8 @@ public function setEndTimeUnixNano($var) * like server name can be set using the resource API. Examples of attributes: * "/http/user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36" * "/http/server_latency": 300 - * "abc.com/myattribute": true - * "abc.com/score": 10.239 + * "example.com/myattribute": true + * "example.com/score": 10.239 * The OpenTelemetry API specification further restricts the allowed value types: * https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/common/README.md#attribute * Attribute keys MUST be unique (it is not allowed to have more than one @@ -533,8 +525,8 @@ public function getAttributes() * like server name can be set using the resource API. Examples of attributes: * "/http/user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36" * "/http/server_latency": 300 - * "abc.com/myattribute": true - * "abc.com/score": 10.239 + * "example.com/myattribute": true + * "example.com/score": 10.239 * The OpenTelemetry API specification further restricts the allowed value types: * https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/common/README.md#attribute * Attribute keys MUST be unique (it is not allowed to have more than one diff --git a/Opentelemetry/Proto/Trace/V1/Status/StatusCode.php b/Opentelemetry/Proto/Trace/V1/Status/StatusCode.php index 0ce2d16..954cf1f 100644 --- a/Opentelemetry/Proto/Trace/V1/Status/StatusCode.php +++ b/Opentelemetry/Proto/Trace/V1/Status/StatusCode.php @@ -21,8 +21,8 @@ class StatusCode */ const STATUS_CODE_UNSET = 0; /** - * The Span has been validated by an Application developers or Operator to have - * completed successfully. + * The Span has been validated by an Application developer or Operator to + * have completed successfully. * * Generated from protobuf enum STATUS_CODE_OK = 1; */ diff --git a/VERSION b/VERSION index 96fb87f..1847373 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -v0.19.0 +v0.20.0