actr_protocol/generated/
actr.rs

1// This file is @generated by prost-build.
2/// Payload types for traffic segregation (message type + transport characteristics)
3/// Format: <MessageType>_<TransportMode>
4#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
5#[repr(i32)]
6pub enum PayloadType {
7    /// RpcEnvelope types
8    ///
9    /// RpcEnvelope with reliable ordered transmission - DEFAULT
10    RpcReliable = 0,
11    /// RpcEnvelope with high-priority signaling channel
12    RpcSignal = 1,
13    /// StreamChunk types
14    ///
15    /// StreamChunk with reliable ordered transmission
16    StreamReliable = 2,
17    /// StreamChunk with low latency partial-reliable transmission
18    StreamLatencyFirst = 3,
19    /// MediaFrame types
20    ///
21    /// MediaFrame over WebRTC RTP MediaTrack
22    MediaRtp = 4,
23}
24impl PayloadType {
25    /// String value of the enum field names used in the ProtoBuf definition.
26    ///
27    /// The values are not transformed in any way and thus are considered stable
28    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
29    pub fn as_str_name(&self) -> &'static str {
30        match self {
31            Self::RpcReliable => "RPC_RELIABLE",
32            Self::RpcSignal => "RPC_SIGNAL",
33            Self::StreamReliable => "STREAM_RELIABLE",
34            Self::StreamLatencyFirst => "STREAM_LATENCY_FIRST",
35            Self::MediaRtp => "MEDIA_RTP",
36        }
37    }
38    /// Creates an enum from field names used in the ProtoBuf definition.
39    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
40        match value {
41            "RPC_RELIABLE" => Some(Self::RpcReliable),
42            "RPC_SIGNAL" => Some(Self::RpcSignal),
43            "STREAM_RELIABLE" => Some(Self::StreamReliable),
44            "STREAM_LATENCY_FIRST" => Some(Self::StreamLatencyFirst),
45            "MEDIA_RTP" => Some(Self::MediaRtp),
46            _ => None,
47        }
48    }
49}
50/// ===========================================================================
51/// Basic Components
52///    Realm (Security Realm)
53///    ActrType (manufacturer + name)
54///    ActrId (Realm + serial number + type)
55///    ServiceSpec (fingerprint + proto bundle + tags)
56///    ActrNode (ActrId + ServiceSpec)
57/// ===========================================================================
58#[derive(Ord, PartialOrd, serde::Serialize, serde::Deserialize)]
59#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
60pub struct Realm {
61    #[prost(uint32, required, tag = "1")]
62    pub realm_id: u32,
63}
64#[derive(Ord, PartialOrd, serde::Serialize, serde::Deserialize)]
65#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
66pub struct ActrType {
67    #[prost(string, required, tag = "1")]
68    pub manufacturer: ::prost::alloc::string::String,
69    #[prost(string, required, tag = "2")]
70    pub name: ::prost::alloc::string::String,
71}
72#[derive(Ord, PartialOrd, serde::Serialize, serde::Deserialize)]
73#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
74pub struct ActrId {
75    #[prost(message, required, tag = "1")]
76    pub realm: Realm,
77    #[prost(uint64, required, tag = "2")]
78    pub serial_number: u64,
79    #[prost(message, required, tag = "3")]
80    pub r#type: ActrType,
81}
82#[derive(Clone, PartialEq, ::prost::Message)]
83pub struct ServiceSpec {
84    #[prost(string, optional, tag = "1")]
85    pub description: ::core::option::Option<::prost::alloc::string::String>,
86    /// Deterministic hash combining all proto semantic fingerprints
87    #[prost(string, required, tag = "2")]
88    pub fingerprint: ::prost::alloc::string::String,
89    #[prost(message, repeated, tag = "3")]
90    pub protobufs: ::prost::alloc::vec::Vec<service_spec::Protobuf>,
91    /// Publication timestamp (Unix epoch seconds)
92    #[prost(int64, optional, tag = "4")]
93    pub published_at: ::core::option::Option<i64>,
94    /// Tags like "latest", "stable"
95    #[prost(string, repeated, tag = "5")]
96    pub tags: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
97}
98/// Nested message and enum types in `ServiceSpec`.
99pub mod service_spec {
100    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
101    pub struct Protobuf {
102        /// Package name (e.g., "user.v1", "acme.payment.v2")
103        #[prost(string, required, tag = "1")]
104        pub package: ::prost::alloc::string::String,
105        /// Merged and normalized content for this package
106        #[prost(string, required, tag = "2")]
107        pub content: ::prost::alloc::string::String,
108        /// Semantic fingerprint of merged package content
109        #[prost(string, required, tag = "3")]
110        pub fingerprint: ::prost::alloc::string::String,
111    }
112}
113#[derive(Clone, PartialEq, ::prost::Message)]
114pub struct ActrNode {
115    #[prost(message, required, tag = "1")]
116    pub actr_id: ActrId,
117    #[prost(message, optional, tag = "2")]
118    pub service_spec: ::core::option::Option<ServiceSpec>,
119}
120/// Geographic location for load balancing
121#[derive(Clone, PartialEq, ::prost::Message)]
122pub struct ServiceLocation {
123    /// Region identifier (e.g., "us-west", "cn-beijing")
124    #[prost(string, optional, tag = "1")]
125    pub region: ::core::option::Option<::prost::alloc::string::String>,
126    /// Latitude in decimal degrees (-90 to +90)
127    #[prost(double, optional, tag = "2")]
128    pub latitude: ::core::option::Option<f64>,
129    /// Longitude in decimal degrees (-180 to +180)
130    #[prost(double, optional, tag = "3")]
131    pub longitude: ::core::option::Option<f64>,
132}
133/// Credential structure for ActrId authentication
134#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
135pub struct AIdCredential {
136    #[prost(bytes = "bytes", required, tag = "1")]
137    pub encrypted_token: ::prost::bytes::Bytes,
138    #[prost(uint32, required, tag = "2")]
139    pub token_key_id: u32,
140}
141/// A single ACL rule: from -> me : permission
142#[derive(Clone, PartialEq, ::prost::Message)]
143pub struct AclRule {
144    #[prost(message, repeated, tag = "1")]
145    pub principals: ::prost::alloc::vec::Vec<acl_rule::Principal>,
146    #[prost(enumeration = "acl_rule::Permission", required, tag = "2")]
147    pub permission: i32,
148}
149/// Nested message and enum types in `AclRule`.
150pub mod acl_rule {
151    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
152    pub struct Principal {
153        #[prost(message, optional, tag = "1")]
154        pub realm: ::core::option::Option<super::Realm>,
155        #[prost(message, optional, tag = "2")]
156        pub actr_type: ::core::option::Option<super::ActrType>,
157    }
158    #[derive(
159        Clone,
160        Copy,
161        Debug,
162        PartialEq,
163        Eq,
164        Hash,
165        PartialOrd,
166        Ord,
167        ::prost::Enumeration
168    )]
169    #[repr(i32)]
170    pub enum Permission {
171        Deny = 0,
172        Allow = 1,
173    }
174    impl Permission {
175        /// String value of the enum field names used in the ProtoBuf definition.
176        ///
177        /// The values are not transformed in any way and thus are considered stable
178        /// (if the ProtoBuf definition does not change) and safe for programmatic use.
179        pub fn as_str_name(&self) -> &'static str {
180            match self {
181                Self::Deny => "DENY",
182                Self::Allow => "ALLOW",
183            }
184        }
185        /// Creates an enum from field names used in the ProtoBuf definition.
186        pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
187            match value {
188                "DENY" => Some(Self::Deny),
189                "ALLOW" => Some(Self::Allow),
190                _ => None,
191            }
192        }
193    }
194}
195/// Access Control List (ordered; first match wins)
196#[derive(Clone, PartialEq, ::prost::Message)]
197pub struct Acl {
198    #[prost(message, repeated, tag = "1")]
199    pub rules: ::prost::alloc::vec::Vec<AclRule>,
200}
201#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
202pub struct ErrorResponse {
203    #[prost(uint32, required, tag = "1")]
204    pub code: u32,
205    #[prost(string, required, tag = "2")]
206    pub message: ::prost::alloc::string::String,
207}
208/// =========================================================================
209/// Register
210/// =========================================================================
211/// Allocate a new ActrId and register node metadata and API info.
212#[derive(Clone, PartialEq, ::prost::Message)]
213pub struct RegisterRequest {
214    #[prost(message, required, tag = "1")]
215    pub actr_type: ActrType,
216    #[prost(message, required, tag = "2")]
217    pub realm: Realm,
218    /// API / contract metadata
219    #[prost(message, optional, tag = "3")]
220    pub service_spec: ::core::option::Option<ServiceSpec>,
221    #[prost(message, optional, tag = "4")]
222    pub acl: ::core::option::Option<Acl>,
223}
224#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
225pub struct RegisterResponse {
226    #[prost(oneof = "register_response::Result", tags = "1, 2")]
227    pub result: ::core::option::Option<register_response::Result>,
228}
229/// Nested message and enum types in `RegisterResponse`.
230pub mod register_response {
231    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
232    pub struct RegisterOk {
233        /// Allocated identity and credentials
234        #[prost(message, required, tag = "1")]
235        pub actr_id: super::ActrId,
236        #[prost(message, required, tag = "2")]
237        pub credential: super::AIdCredential,
238        /// bootstrap keying material
239        #[prost(bytes = "bytes", optional, tag = "3")]
240        pub psk: ::core::option::Option<::prost::bytes::Bytes>,
241        #[prost(message, optional, tag = "4")]
242        pub credential_expires_at: ::core::option::Option<::prost_types::Timestamp>,
243        /// Operational advice: heartbeat interval for subsequent Signaling Server connection
244        #[prost(uint32, required, tag = "5")]
245        pub signaling_heartbeat_interval_secs: u32,
246    }
247    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
248    pub enum Result {
249        #[prost(message, tag = "1")]
250        Success(RegisterOk),
251        #[prost(message, tag = "2")]
252        Error(super::ErrorResponse),
253    }
254}
255#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
256pub struct CredentialUpdateRequest {
257    #[prost(message, required, tag = "1")]
258    pub actr_id: ActrId,
259}
260#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
261pub struct UnregisterRequest {
262    #[prost(message, required, tag = "1")]
263    pub actr_id: ActrId,
264    #[prost(string, optional, tag = "2")]
265    pub reason: ::core::option::Option<::prost::alloc::string::String>,
266}
267#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
268pub struct UnregisterResponse {
269    #[prost(oneof = "unregister_response::Result", tags = "1, 2")]
270    pub result: ::core::option::Option<unregister_response::Result>,
271}
272/// Nested message and enum types in `UnregisterResponse`.
273pub mod unregister_response {
274    #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
275    pub struct UnregisterOk {}
276    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
277    pub enum Result {
278        #[prost(message, tag = "1")]
279        Success(UnregisterOk),
280        #[prost(message, tag = "2")]
281        Error(super::ErrorResponse),
282    }
283}
284/// =========================================================================
285/// Heartbeat
286/// =========================================================================
287/// Periodic liveness and load indicators.
288/// NOTE: Currently measures Node-to-Signaling latency only.
289/// For P2P latency-based routing, consider adding:
290///    - optional uint64 signaling_rtt_ms = 4;  // Node-to-Signaling RTT
291///    - LatencyReport message for P2P measurements
292/// See RouteCandidatesRequest.LOWEST_LATENCY for design discussion.
293#[derive(Clone, PartialEq, ::prost::Message)]
294pub struct Ping {
295    #[prost(enumeration = "ServiceAvailabilityState", required, tag = "1")]
296    pub availability: i32,
297    #[prost(float, required, tag = "2")]
298    pub power_reserve: f32,
299    #[prost(float, required, tag = "3")]
300    pub mailbox_backlog: f32,
301    /// Sticky session support: list of client IDs that must route to this instance.
302    /// Used by LoadBalancer's CLIENT_AFFINITY factor for session persistence.
303    /// Actor instances report their currently connected sticky clients.
304    #[prost(string, repeated, tag = "4")]
305    pub sticky_client_ids: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
306}
307#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
308pub struct Pong {
309    #[prost(uint64, required, tag = "1")]
310    pub seq: u64,
311    /// advisory
312    #[prost(uint32, optional, tag = "2")]
313    pub suggest_interval_secs: ::core::option::Option<u32>,
314}
315/// =========================================================================
316/// Load-balancing: find best route candidates
317/// =========================================================================
318/// Request route candidates for a target actor type with optional selection policy.
319#[derive(Clone, PartialEq, ::prost::Message)]
320pub struct RouteCandidatesRequest {
321    #[prost(message, required, tag = "1")]
322    pub target_type: ActrType,
323    #[prost(message, optional, tag = "2")]
324    pub criteria: ::core::option::Option<
325        route_candidates_request::NodeSelectionCriteria,
326    >,
327    /// Client's geographic location for NEAREST ranking
328    #[prost(message, optional, tag = "3")]
329    pub client_location: ::core::option::Option<ServiceLocation>,
330}
331/// Nested message and enum types in `RouteCandidatesRequest`.
332pub mod route_candidates_request {
333    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
334    pub struct NodeSelectionCriteria {
335        #[prost(uint32, required, tag = "1")]
336        pub candidate_count: u32,
337        #[prost(
338            enumeration = "node_selection_criteria::NodeRankingFactor",
339            repeated,
340            packed = "false",
341            tag = "2"
342        )]
343        pub ranking_factors: ::prost::alloc::vec::Vec<i32>,
344        #[prost(enumeration = "super::ServiceDependencyState", optional, tag = "3")]
345        pub minimal_dependency_requirement: ::core::option::Option<i32>,
346        #[prost(enumeration = "super::ServiceAvailabilityState", optional, tag = "4")]
347        pub minimal_health_requirement: ::core::option::Option<i32>,
348    }
349    /// Nested message and enum types in `NodeSelectionCriteria`.
350    pub mod node_selection_criteria {
351        /// Ranking factors for candidate ordering
352        #[derive(
353            Clone,
354            Copy,
355            Debug,
356            PartialEq,
357            Eq,
358            Hash,
359            PartialOrd,
360            Ord,
361            ::prost::Enumeration
362        )]
363        #[repr(i32)]
364        pub enum NodeRankingFactor {
365            MaximumPowerReserve = 0,
366            MinimumMailboxBacklog = 1,
367            BestCompatibility = 2,
368            Nearest = 3,
369            ClientAffinity = 4,
370        }
371        impl NodeRankingFactor {
372            /// String value of the enum field names used in the ProtoBuf definition.
373            ///
374            /// The values are not transformed in any way and thus are considered stable
375            /// (if the ProtoBuf definition does not change) and safe for programmatic use.
376            pub fn as_str_name(&self) -> &'static str {
377                match self {
378                    Self::MaximumPowerReserve => "MAXIMUM_POWER_RESERVE",
379                    Self::MinimumMailboxBacklog => "MINIMUM_MAILBOX_BACKLOG",
380                    Self::BestCompatibility => "BEST_COMPATIBILITY",
381                    Self::Nearest => "NEAREST",
382                    Self::ClientAffinity => "CLIENT_AFFINITY",
383                }
384            }
385            /// Creates an enum from field names used in the ProtoBuf definition.
386            pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
387                match value {
388                    "MAXIMUM_POWER_RESERVE" => Some(Self::MaximumPowerReserve),
389                    "MINIMUM_MAILBOX_BACKLOG" => Some(Self::MinimumMailboxBacklog),
390                    "BEST_COMPATIBILITY" => Some(Self::BestCompatibility),
391                    "NEAREST" => Some(Self::Nearest),
392                    "CLIENT_AFFINITY" => Some(Self::ClientAffinity),
393                    _ => None,
394                }
395            }
396        }
397    }
398}
399#[derive(Clone, PartialEq, ::prost::Message)]
400pub struct RouteCandidatesResponse {
401    #[prost(oneof = "route_candidates_response::Result", tags = "1, 2")]
402    pub result: ::core::option::Option<route_candidates_response::Result>,
403}
404/// Nested message and enum types in `RouteCandidatesResponse`.
405pub mod route_candidates_response {
406    #[derive(Clone, PartialEq, ::prost::Message)]
407    pub struct RouteCandidatesOk {
408        #[prost(message, repeated, tag = "1")]
409        pub candidates: ::prost::alloc::vec::Vec<super::ActrId>,
410    }
411    #[derive(Clone, PartialEq, ::prost::Oneof)]
412    pub enum Result {
413        #[prost(message, tag = "1")]
414        Success(RouteCandidatesOk),
415        #[prost(message, tag = "2")]
416        Error(super::ErrorResponse),
417    }
418}
419/// =========================================================================
420/// Discovery request/response
421/// =========================================================================
422/// List (ActrType x fingerprint) combinations present on the network.
423#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
424pub struct DiscoveryRequest {
425    #[prost(string, optional, tag = "1")]
426    pub manufacturer: ::core::option::Option<::prost::alloc::string::String>,
427    #[prost(uint32, optional, tag = "2", default = "64")]
428    pub limit: ::core::option::Option<u32>,
429}
430#[derive(Clone, PartialEq, ::prost::Message)]
431pub struct DiscoveryResponse {
432    #[prost(oneof = "discovery_response::Result", tags = "1, 2")]
433    pub result: ::core::option::Option<discovery_response::Result>,
434}
435/// Nested message and enum types in `DiscoveryResponse`.
436pub mod discovery_response {
437    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
438    pub struct TypeEntry {
439        #[prost(message, required, tag = "1")]
440        pub actr_type: super::ActrType,
441        #[prost(string, optional, tag = "2")]
442        pub description: ::core::option::Option<::prost::alloc::string::String>,
443        #[prost(string, required, tag = "3")]
444        pub service_fingerprint: ::prost::alloc::string::String,
445        #[prost(int64, optional, tag = "4")]
446        pub published_at: ::core::option::Option<i64>,
447        #[prost(string, repeated, tag = "5")]
448        pub tags: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
449    }
450    #[derive(Clone, PartialEq, ::prost::Message)]
451    pub struct DiscoveryOk {
452        #[prost(message, repeated, tag = "1")]
453        pub entries: ::prost::alloc::vec::Vec<TypeEntry>,
454    }
455    #[derive(Clone, PartialEq, ::prost::Oneof)]
456    pub enum Result {
457        #[prost(message, tag = "1")]
458        Success(DiscoveryOk),
459        #[prost(message, tag = "2")]
460        Error(super::ErrorResponse),
461    }
462}
463/// Subscribe to "actor of target_type comes online" events.
464#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
465pub struct SubscribeActrUpRequest {
466    #[prost(message, required, tag = "1")]
467    pub target_type: ActrType,
468}
469#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
470pub struct SubscribeActrUpResponse {
471    #[prost(oneof = "subscribe_actr_up_response::Result", tags = "1, 2")]
472    pub result: ::core::option::Option<subscribe_actr_up_response::Result>,
473}
474/// Nested message and enum types in `SubscribeActrUpResponse`.
475pub mod subscribe_actr_up_response {
476    #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
477    pub struct SubscribeOk {}
478    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
479    pub enum Result {
480        #[prost(message, tag = "1")]
481        Success(SubscribeOk),
482        #[prost(message, tag = "2")]
483        Error(super::ErrorResponse),
484    }
485}
486/// Cancel a previous subscription.
487#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
488pub struct UnsubscribeActrUpRequest {
489    #[prost(message, required, tag = "1")]
490    pub target_type: ActrType,
491}
492#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
493pub struct UnsubscribeActrUpResponse {
494    #[prost(oneof = "unsubscribe_actr_up_response::Result", tags = "1, 2")]
495    pub result: ::core::option::Option<unsubscribe_actr_up_response::Result>,
496}
497/// Nested message and enum types in `UnsubscribeActrUpResponse`.
498pub mod unsubscribe_actr_up_response {
499    #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
500    pub struct UnsubscribeOk {}
501    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
502    pub enum Result {
503        #[prost(message, tag = "1")]
504        Success(UnsubscribeOk),
505        #[prost(message, tag = "2")]
506        Error(super::ErrorResponse),
507    }
508}
509/// Event: a matching actor instance changed presence.
510#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
511pub struct ActrUpEvent {
512    #[prost(message, required, tag = "1")]
513    pub actor_id: ActrId,
514}
515#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
516#[repr(i32)]
517pub enum LifecycleState {
518    Halted = 0,
519    Initializing = 1,
520    Constructing = 2,
521    Running = 3,
522    Destructing = 4,
523    Crashing = 5,
524}
525impl LifecycleState {
526    /// String value of the enum field names used in the ProtoBuf definition.
527    ///
528    /// The values are not transformed in any way and thus are considered stable
529    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
530    pub fn as_str_name(&self) -> &'static str {
531        match self {
532            Self::Halted => "HALTED",
533            Self::Initializing => "INITIALIZING",
534            Self::Constructing => "CONSTRUCTING",
535            Self::Running => "RUNNING",
536            Self::Destructing => "DESTRUCTING",
537            Self::Crashing => "CRASHING",
538        }
539    }
540    /// Creates an enum from field names used in the ProtoBuf definition.
541    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
542        match value {
543            "HALTED" => Some(Self::Halted),
544            "INITIALIZING" => Some(Self::Initializing),
545            "CONSTRUCTING" => Some(Self::Constructing),
546            "RUNNING" => Some(Self::Running),
547            "DESTRUCTING" => Some(Self::Destructing),
548            "CRASHING" => Some(Self::Crashing),
549            _ => None,
550        }
551    }
552}
553#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
554#[repr(i32)]
555pub enum ServiceAvailabilityState {
556    Full = 0,
557    Degraded = 1,
558    Overloaded = 2,
559    Unavailable = 3,
560}
561impl ServiceAvailabilityState {
562    /// String value of the enum field names used in the ProtoBuf definition.
563    ///
564    /// The values are not transformed in any way and thus are considered stable
565    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
566    pub fn as_str_name(&self) -> &'static str {
567        match self {
568            Self::Full => "FULL",
569            Self::Degraded => "DEGRADED",
570            Self::Overloaded => "OVERLOADED",
571            Self::Unavailable => "UNAVAILABLE",
572        }
573    }
574    /// Creates an enum from field names used in the ProtoBuf definition.
575    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
576        match value {
577            "FULL" => Some(Self::Full),
578            "DEGRADED" => Some(Self::Degraded),
579            "OVERLOADED" => Some(Self::Overloaded),
580            "UNAVAILABLE" => Some(Self::Unavailable),
581            _ => None,
582        }
583    }
584}
585#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
586#[repr(i32)]
587pub enum ServiceDependencyState {
588    Healthy = 0,
589    Warning = 1,
590    Broken = 2,
591}
592impl ServiceDependencyState {
593    /// String value of the enum field names used in the ProtoBuf definition.
594    ///
595    /// The values are not transformed in any way and thus are considered stable
596    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
597    pub fn as_str_name(&self) -> &'static str {
598        match self {
599            Self::Healthy => "HEALTHY",
600            Self::Warning => "WARNING",
601            Self::Broken => "BROKEN",
602        }
603    }
604    /// Creates an enum from field names used in the ProtoBuf definition.
605    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
606        match value {
607            "HEALTHY" => Some(Self::Healthy),
608            "WARNING" => Some(Self::Warning),
609            "BROKEN" => Some(Self::Broken),
610            _ => None,
611        }
612    }
613}
614/// Metadata key-value pair
615#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
616pub struct MetadataEntry {
617    #[prost(string, required, tag = "1")]
618    pub key: ::prost::alloc::string::String,
619    #[prost(string, required, tag = "2")]
620    pub value: ::prost::alloc::string::String,
621}
622/// RpcEnvelope wraps State Path RPC messages
623#[derive(Clone, PartialEq, ::prost::Message)]
624pub struct RpcEnvelope {
625    /// Route key: "package.Service.Method"
626    #[prost(string, required, tag = "1")]
627    pub route_key: ::prost::alloc::string::String,
628    /// Payload for successful RPC (request or response)
629    /// Optional: when error is present, payload should be empty
630    #[prost(bytes = "bytes", optional, tag = "2")]
631    pub payload: ::core::option::Option<::prost::bytes::Bytes>,
632    /// System-level error (envelope layer)
633    /// Examples: UnknownRoute, DeserializationError, Panic, InvalidStateTransition
634    /// Business errors should be in the response message payload
635    #[prost(message, optional, tag = "3")]
636    pub error: ::core::option::Option<ErrorResponse>,
637    #[prost(string, required, tag = "100")]
638    pub trace_id: ::prost::alloc::string::String,
639    #[prost(string, required, tag = "101")]
640    pub request_id: ::prost::alloc::string::String,
641    #[prost(message, repeated, tag = "102")]
642    pub metadata: ::prost::alloc::vec::Vec<MetadataEntry>,
643    #[prost(int64, required, tag = "103")]
644    pub timeout_ms: i64,
645}
646/// DataStream - Application data stream packet (Fast Path)
647///
648/// For streaming application data (non-media):
649/// - File transfer chunks
650/// - Game state updates
651/// - Custom protocol streams
652#[derive(Clone, PartialEq, ::prost::Message)]
653pub struct DataStream {
654    #[prost(string, required, tag = "1")]
655    pub stream_id: ::prost::alloc::string::String,
656    #[prost(uint64, required, tag = "2")]
657    pub sequence: u64,
658    #[prost(bytes = "bytes", required, tag = "3")]
659    pub payload: ::prost::bytes::Bytes,
660    #[prost(message, repeated, tag = "4")]
661    pub metadata: ::prost::alloc::vec::Vec<MetadataEntry>,
662    #[prost(int64, optional, tag = "5")]
663    pub timestamp_ms: ::core::option::Option<i64>,
664}