libdd_trace_protobuf/opentelemetry.proto.collector.trace.v1.rs
1// Copyright 2019, OpenTelemetry Authors
2// SPDX-License-Identifier: Apache-2.0
3
4// This file is @generated by prost-build.
5#[derive(Clone, PartialEq, ::prost::Message)]
6pub struct ExportTraceServiceRequest {
7 /// An array of ResourceSpans.
8 /// For data coming from a single resource this array will typically contain one
9 /// element. Intermediary nodes (such as OpenTelemetry Collector) that receive
10 /// data from multiple origins typically batch the data before forwarding further and
11 /// in that case this array will contain multiple elements.
12 #[prost(message, repeated, tag = "1")]
13 pub resource_spans: ::prost::alloc::vec::Vec<
14 super::super::super::trace::v1::ResourceSpans,
15 >,
16}
17#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
18pub struct ExportTraceServiceResponse {
19 /// The details of a partially successful export request.
20 ///
21 /// If the request is only partially accepted
22 /// (i.e. when the server accepts only parts of the data and rejects the rest)
23 /// the server MUST initialize the `partial_success` field and MUST
24 /// set the `rejected_<signal>` with the number of items it rejected.
25 ///
26 /// Servers MAY also make use of the `partial_success` field to convey
27 /// warnings/suggestions to senders even when the request was fully accepted.
28 /// In such cases, the `rejected_<signal>` MUST have a value of `0` and
29 /// the `error_message` MUST be non-empty.
30 ///
31 /// A `partial_success` message with an empty value (rejected_<signal> = 0 and
32 /// `error_message` = "") is equivalent to it not being set/present. Senders
33 /// SHOULD interpret it the same way as in the full success case.
34 #[prost(message, optional, tag = "1")]
35 pub partial_success: ::core::option::Option<ExportTracePartialSuccess>,
36}
37#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
38pub struct ExportTracePartialSuccess {
39 /// The number of rejected spans.
40 ///
41 /// A `rejected_<signal>` field holding a `0` value indicates that the
42 /// request was fully accepted.
43 #[prost(int64, tag = "1")]
44 pub rejected_spans: i64,
45 /// A developer-facing human-readable message in English. It should be used
46 /// either to explain why the server rejected parts of the data during a partial
47 /// success or to convey warnings/suggestions during a full success. The message
48 /// should offer guidance on how users can address such issues.
49 ///
50 /// error_message is an optional field. An error_message with an empty value
51 /// is equivalent to it not being set.
52 #[prost(string, tag = "2")]
53 pub error_message: ::prost::alloc::string::String,
54}