Skip to content

Commit

Permalink
commit protobuf files
Browse files Browse the repository at this point in the history
  • Loading branch information
Noah-Kennedy committed Sep 4, 2022
1 parent 58a1cdb commit 8c2ed45
Show file tree
Hide file tree
Showing 6 changed files with 360 additions and 286 deletions.
30 changes: 15 additions & 15 deletions console-api/src/generated/rs.tokio.console.async_ops.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/// An `AsyncOp` state update.
/// An `AsyncOp` state update.
///
/// This includes a list of any new async ops, and updates to the associated statistics
/// for any async ops that have changed since the last update.
Expand All @@ -8,10 +8,10 @@ pub struct AsyncOpUpdate {
/// was sent. Note that the fact that an async operation has been created
/// does not mean that is has been polled or is being polled. This information
/// is reflected in the `Stats` of the operation.
#[prost(message, repeated, tag = "1")]
#[prost(message, repeated, tag="1")]
pub new_async_ops: ::prost::alloc::vec::Vec<AsyncOp>,
/// Any async op stats that have changed since the last update.
#[prost(map = "uint64, message", tag = "2")]
#[prost(map="uint64, message", tag="2")]
pub stats_update: ::std::collections::HashMap<u64, Stats>,
/// A count of how many async op events (e.g. polls, creation, etc) were not
/// recorded because the application's event buffer was at capacity.
Expand All @@ -23,32 +23,32 @@ pub struct AsyncOpUpdate {
///
/// If the application's instrumentation ensures reliable delivery of events,
/// this will always be 0.
#[prost(uint64, tag = "3")]
#[prost(uint64, tag="3")]
pub dropped_events: u64,
}
/// An async operation.
///
/// An async operation is an operation that is associated with a resource
/// This could, for example, be a a read or write on a TCP stream, or a receive operation on
/// a channel.
#[derive(Clone, Eq, PartialEq, ::prost::Message)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct AsyncOp {
/// The async op's ID.
///
/// This uniquely identifies this op across all *currently live*
/// ones.
#[prost(message, optional, tag = "1")]
#[prost(message, optional, tag="1")]
pub id: ::core::option::Option<super::common::Id>,
/// The numeric ID of the op's `Metadata`.
///
/// This identifies the `Metadata` that describes the `tracing` span
/// corresponding to this async op. The metadata for this ID will have been sent
/// in a prior `RegisterMetadata` message.
#[prost(message, optional, tag = "2")]
#[prost(message, optional, tag="2")]
pub metadata: ::core::option::Option<super::common::MetaId>,
/// The source of this async operation. Most commonly this should be the name
/// of the method where the instantiation of this op has happened.
#[prost(string, tag = "3")]
#[prost(string, tag="3")]
pub source: ::prost::alloc::string::String,
/// The ID of the parent async op.
///
Expand All @@ -58,28 +58,28 @@ pub struct AsyncOp {
///
/// This field can be empty; if it is empty, this async op is not a child of another
/// async op.
#[prost(message, optional, tag = "4")]
#[prost(message, optional, tag="4")]
pub parent_async_op_id: ::core::option::Option<super::common::Id>,
/// The resources's ID.
#[prost(message, optional, tag = "5")]
#[prost(message, optional, tag="5")]
pub resource_id: ::core::option::Option<super::common::Id>,
}
/// Statistics associated with a given async operation.
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct Stats {
/// Timestamp of when the async op has been created.
#[prost(message, optional, tag = "1")]
#[prost(message, optional, tag="1")]
pub created_at: ::core::option::Option<::prost_types::Timestamp>,
/// Timestamp of when the async op was dropped.
#[prost(message, optional, tag = "2")]
#[prost(message, optional, tag="2")]
pub dropped_at: ::core::option::Option<::prost_types::Timestamp>,
/// The Id of the task that is awaiting on this op.
#[prost(message, optional, tag = "4")]
#[prost(message, optional, tag="4")]
pub task_id: ::core::option::Option<super::common::Id>,
/// Contains the operation poll stats.
#[prost(message, optional, tag = "5")]
#[prost(message, optional, tag="5")]
pub poll_stats: ::core::option::Option<super::common::PollStats>,
/// State attributes of the async op.
#[prost(message, repeated, tag = "6")]
#[prost(message, repeated, tag="6")]
pub attributes: ::prost::alloc::vec::Vec<super::common::Attribute>,
}
102 changes: 51 additions & 51 deletions console-api/src/generated/rs.tokio.console.common.rs
Original file line number Diff line number Diff line change
@@ -1,157 +1,157 @@
/// Unique identifier for each task.
#[derive(Clone, Eq, PartialEq, ::prost::Message)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct Id {
/// The unique identifier's concrete value.
#[prost(uint64, tag = "1")]
#[prost(uint64, tag="1")]
pub id: u64,
}
/// A Rust source code location.
#[derive(Clone, Eq, PartialEq, ::prost::Message)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct Location {
/// The file path
#[prost(string, optional, tag = "1")]
#[prost(string, optional, tag="1")]
pub file: ::core::option::Option<::prost::alloc::string::String>,
/// The Rust module path
#[prost(string, optional, tag = "2")]
#[prost(string, optional, tag="2")]
pub module_path: ::core::option::Option<::prost::alloc::string::String>,
/// The line number in the source code file.
#[prost(uint32, optional, tag = "3")]
#[prost(uint32, optional, tag="3")]
pub line: ::core::option::Option<u32>,
/// The character in `line`.
#[prost(uint32, optional, tag = "4")]
#[prost(uint32, optional, tag="4")]
pub column: ::core::option::Option<u32>,
}
/// Unique identifier for metadata.
#[derive(Clone, Eq, PartialEq, ::prost::Message)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct MetaId {
/// The unique identifier's concrete value.
#[prost(uint64, tag = "1")]
#[prost(uint64, tag="1")]
pub id: u64,
}
/// Unique identifier for spans.
#[derive(Clone, Eq, PartialEq, ::prost::Message)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct SpanId {
/// The unique identifier's concrete value.
#[prost(uint64, tag = "1")]
#[prost(uint64, tag="1")]
pub id: u64,
}
/// A message representing a key-value pair of data associated with a `Span`
#[derive(Clone, Eq, PartialEq, ::prost::Message)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct Field {
/// Metadata for the task span that the field came from.
#[prost(message, optional, tag = "8")]
#[prost(message, optional, tag="8")]
pub metadata_id: ::core::option::Option<MetaId>,
/// The key of the key-value pair.
///
/// This is either represented as a string, or as an index into a `Metadata`'s
/// This is either represented as a string, or as an index into a `Metadata`'s
/// array of field name strings.
#[prost(oneof = "field::Name", tags = "1, 2")]
#[prost(oneof="field::Name", tags="1, 2")]
pub name: ::core::option::Option<field::Name>,
/// The value of the key-value pair.
#[prost(oneof = "field::Value", tags = "3, 4, 5, 6, 7")]
#[prost(oneof="field::Value", tags="3, 4, 5, 6, 7")]
pub value: ::core::option::Option<field::Value>,
}
/// Nested message and enum types in `Field`.
pub mod field {
/// The key of the key-value pair.
///
/// This is either represented as a string, or as an index into a `Metadata`'s
/// This is either represented as a string, or as an index into a `Metadata`'s
/// array of field name strings.
#[derive(Clone, PartialEq, ::prost::Oneof)]
pub enum Name {
/// The string representation of the name.
#[prost(string, tag = "1")]
#[prost(string, tag="1")]
StrName(::prost::alloc::string::String),
/// An index position into the `Metadata.field_names` of the metadata
/// for the task span that the field came from.
#[prost(uint64, tag = "2")]
#[prost(uint64, tag="2")]
NameIdx(u64),
}
/// The value of the key-value pair.
#[derive(Clone, Eq, PartialEq, ::prost::Oneof)]
#[derive(Clone, PartialEq, ::prost::Oneof)]
pub enum Value {
/// A value serialized to a string using `fmt::Debug`.
#[prost(string, tag = "3")]
#[prost(string, tag="3")]
DebugVal(::prost::alloc::string::String),
/// A string value.
#[prost(string, tag = "4")]
#[prost(string, tag="4")]
StrVal(::prost::alloc::string::String),
/// An unsigned integer value.
#[prost(uint64, tag = "5")]
#[prost(uint64, tag="5")]
U64Val(u64),
/// A signed integer value.
#[prost(sint64, tag = "6")]
#[prost(sint64, tag="6")]
I64Val(i64),
/// A boolean value.
#[prost(bool, tag = "7")]
#[prost(bool, tag="7")]
BoolVal(bool),
}
}
/// Represents a period of time in which a program was executing in a particular context.
///
/// Corresponds to `Span` in the `tracing` crate.
#[derive(Clone, Eq, PartialEq, ::prost::Message)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct Span {
/// An Id that uniquely identifies it in relation to other spans.
#[prost(message, optional, tag = "1")]
#[prost(message, optional, tag="1")]
pub id: ::core::option::Option<SpanId>,
/// Identifier for metadata describing static characteristics of all spans originating
/// from that callsite, such as its name, source code location, verbosity level, and
/// the names of its fields.
#[prost(message, optional, tag = "2")]
#[prost(message, optional, tag="2")]
pub metadata_id: ::core::option::Option<MetaId>,
/// User-defined key-value pairs of arbitrary data that describe the context the span represents,
#[prost(message, repeated, tag = "3")]
#[prost(message, repeated, tag="3")]
pub fields: ::prost::alloc::vec::Vec<Field>,
/// Timestamp for the span.
#[prost(message, optional, tag = "4")]
#[prost(message, optional, tag="4")]
pub at: ::core::option::Option<::prost_types::Timestamp>,
}
/// Any new metadata that was registered since the last update.
#[derive(Clone, Eq, PartialEq, ::prost::Message)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct RegisterMetadata {
/// The new metadata that was registered since the last update.
#[prost(message, repeated, tag = "1")]
#[prost(message, repeated, tag="1")]
pub metadata: ::prost::alloc::vec::Vec<register_metadata::NewMetadata>,
}
/// Nested message and enum types in `RegisterMetadata`.
pub mod register_metadata {
/// One metadata element registered since the last update.
#[derive(Clone, Eq, PartialEq, ::prost::Message)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct NewMetadata {
/// Unique identifier for `metadata`.
#[prost(message, optional, tag = "1")]
#[prost(message, optional, tag="1")]
pub id: ::core::option::Option<super::MetaId>,
/// The metadata payload.
#[prost(message, optional, tag = "2")]
#[prost(message, optional, tag="2")]
pub metadata: ::core::option::Option<super::Metadata>,
}
}
/// Metadata associated with a span or event.
#[derive(Clone, Eq, PartialEq, ::prost::Message)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct Metadata {
/// The name of the span or event.
#[prost(string, tag = "1")]
#[prost(string, tag="1")]
pub name: ::prost::alloc::string::String,
/// Describes the part of the system where the span or event that this
/// metadata describes occurred.
#[prost(string, tag = "2")]
#[prost(string, tag="2")]
pub target: ::prost::alloc::string::String,
/// The path to the Rust module where the span occurred.
#[prost(string, tag = "3")]
#[prost(string, tag="3")]
pub module_path: ::prost::alloc::string::String,
/// The Rust source location associated with the span or event.
#[prost(message, optional, tag = "4")]
#[prost(message, optional, tag="4")]
pub location: ::core::option::Option<Location>,
/// Indicates whether metadata is associated with a span or with an event.
#[prost(enumeration = "metadata::Kind", tag = "5")]
#[prost(enumeration="metadata::Kind", tag="5")]
pub kind: i32,
/// Describes the level of verbosity of a span or event.
#[prost(enumeration = "metadata::Level", tag = "6")]
#[prost(enumeration="metadata::Level", tag="6")]
pub level: i32,
/// The names of the key-value fields attached to the
/// span or event this metadata is associated with.
#[prost(string, repeated, tag = "7")]
#[prost(string, repeated, tag="7")]
pub field_names: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
}
/// Nested message and enum types in `Metadata`.
Expand Down Expand Up @@ -225,15 +225,15 @@ pub mod metadata {
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct PollStats {
/// The total number of times this object has been polled.
#[prost(uint64, tag = "1")]
#[prost(uint64, tag="1")]
pub polls: u64,
/// The timestamp of the first time this object was polled.
///
/// If this is `None`, the object has not yet been polled.
///
/// Subtracting this timestamp from `created_at` can be used to calculate the
/// time to first poll for this object, a measurement of executor latency.
#[prost(message, optional, tag = "3")]
#[prost(message, optional, tag="3")]
pub first_poll: ::core::option::Option<::prost_types::Timestamp>,
/// The timestamp of the most recent time this objects's poll method was invoked.
///
Expand All @@ -242,22 +242,22 @@ pub struct PollStats {
/// If the object has only been polled a single time, then this value may be
/// equal to the `first_poll` timestamp.
///
#[prost(message, optional, tag = "4")]
#[prost(message, optional, tag="4")]
pub last_poll_started: ::core::option::Option<::prost_types::Timestamp>,
/// The timestamp of the most recent time this objects's poll method finished execution.
///
/// If this is `None`, the object has not yet been polled or is currently being polled.
///
/// If the object does not exist anymore, then this is the time the final invocation of
/// its poll method has completed.
#[prost(message, optional, tag = "5")]
#[prost(message, optional, tag="5")]
pub last_poll_ended: ::core::option::Option<::prost_types::Timestamp>,
/// The total duration this object was being *actively polled*, summed across
/// all polls. Note that this includes only polls that have completed and is
/// not reflecting any inprogress polls. Subtracting `busy_time` from the
/// total lifetime of the polled object results in the amount of time it
/// has spent *waiting* to be polled.
#[prost(message, optional, tag = "6")]
#[prost(message, optional, tag="6")]
pub busy_time: ::core::option::Option<::prost_types::Duration>,
}
/// State attributes of an entity. These are dependent on the type of the entity.
Expand All @@ -267,13 +267,13 @@ pub struct PollStats {
/// indicating how many permits they are trying to acquire vs how many are acquired.
/// These values may change over time. Therefore, they live in the runtime stats rather
/// than the static data describing the entity.
#[derive(Clone, Eq, PartialEq, ::prost::Message)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct Attribute {
/// The key-value pair for the attribute
#[prost(message, optional, tag = "1")]
#[prost(message, optional, tag="1")]
pub field: ::core::option::Option<Field>,
/// Some values carry a unit of measurement. For example, a duration
/// carries an associated unit of time, such as "ms" for milliseconds.
#[prost(string, optional, tag = "2")]
#[prost(string, optional, tag="2")]
pub unit: ::core::option::Option<::prost::alloc::string::String>,
}
Loading

0 comments on commit 8c2ed45

Please sign in to comment.