pub struct MiddlewareStack { /* private fields */ }Implementations§
Source§impl MiddlewareStack
impl MiddlewareStack
Sourcepub fn topic_slot(&mut self, topic: &str, depth: usize) -> Arc<TopicSlot>
pub fn topic_slot(&mut self, topic: &str, depth: usize) -> Arc<TopicSlot>
Get-or-create the in-process TopicSlot for topic.
depth is used only when the slot is first created.
Sourcepub fn service_channel(&mut self, service: &str) -> Arc<ServiceChannel>
pub fn service_channel(&mut self, service: &str) -> Arc<ServiceChannel>
Get-or-create the in-process ServiceChannel for service.
Sourcepub fn action_channel<G, F, R>(
&mut self,
action: &str,
) -> Arc<ActionChannel<G, F, R>>
pub fn action_channel<G, F, R>( &mut self, action: &str, ) -> Arc<ActionChannel<G, F, R>>
Get-or-create the in-process ActionChannel for action.
Both client and server must call this with the same G/F/R types;
if the types don’t match the channel stored under action the method
panics (same process, so a type mismatch is always a programming error).
pub fn load_snapshot(&self) -> MiddlewareLoadSnapshot
pub fn serialization(&self) -> &dyn SerializationManager
Source§impl MiddlewareStack
impl MiddlewareStack
pub fn apply_runtime_config(&mut self, config: MiddlewareRuntimeConfig)
pub fn register_topic(&mut self, topic: impl Into<String>)
pub fn register_topic_with_ttl( &mut self, topic: impl Into<String>, ttl: Duration, )
pub fn set_topic_qos(&mut self, topic: impl Into<String>, profile: QosProfile)
pub fn set_topic_qos_if_absent( &mut self, topic: impl Into<String>, profile: QosProfile, )
pub fn topic_qos(&self, topic: &str) -> Option<QosProfile>
pub fn register_service(&mut self, service: impl Into<String>)
pub fn register_service_with_ttl( &mut self, service: impl Into<String>, ttl: Duration, )
pub fn register_mission(&mut self, mission: impl Into<String>)
pub fn register_mission_with_ttl( &mut self, mission: impl Into<String>, ttl: Duration, )
pub fn register_endpoint(&mut self, name: impl Into<String>, endpoint: Endpoint)
pub fn register_endpoint_with_ttl( &mut self, name: impl Into<String>, endpoint: Endpoint, ttl: Duration, )
pub fn unregister_endpoint(&mut self, name: &str) -> bool
pub fn register_topic_subscriber_endpoint_with_ttl( &mut self, name: impl Into<String>, topic: impl Into<String>, endpoint: Endpoint, qos: QosProfile, ttl: Duration, )
pub fn topic_subscriber_endpoints(&self, topic: &str) -> Vec<DiscoveryEndpoint>
pub fn topic_subscriber_counts(&self, topic: &str) -> (usize, usize)
pub fn topic_subscriber_count(&self, topic: &str) -> usize
pub fn topic_local_reliable_subscriber_acks( &self, topic: &str, ) -> Vec<(String, Option<u64>)>
pub fn topic_reliable_subscriber_acks( &self, topic: &str, ) -> Vec<(String, Option<u64>)>
pub fn update_topic_subscriber_ack( &mut self, endpoint_name: &str, acked_seq: Option<u64>, ) -> bool
pub fn find_endpoint(&self, name: &str) -> Option<DiscoveryEndpoint>
pub fn endpoint_entries(&self) -> Vec<DiscoveryEndpoint>
pub fn renew_topic_lease(&mut self, topic: &str, ttl: Duration) -> bool
pub fn renew_service_lease(&mut self, service: &str, ttl: Duration) -> bool
pub fn renew_mission_lease(&mut self, mission: &str, ttl: Duration) -> bool
pub fn renew_endpoint_lease(&mut self, endpoint: &str, ttl: Duration) -> bool
pub fn set_topic_health(&mut self, topic: &str, healthy: bool) -> bool
pub fn set_service_health(&mut self, service: &str, healthy: bool) -> bool
pub fn set_mission_health(&mut self, mission: &str, healthy: bool) -> bool
pub fn set_endpoint_health(&mut self, endpoint: &str, healthy: bool) -> bool
pub fn prune_discovery_inactive(&mut self) -> DiscoveryPruneReport
pub fn snapshot(&self) -> DiscoverySnapshot
pub fn topic_entries(&self) -> Vec<DiscoveryEntry>
pub fn service_entries(&self) -> Vec<DiscoveryEntry>
pub fn mission_entries(&self) -> Vec<DiscoveryEntry>
Source§impl MiddlewareStack
impl MiddlewareStack
Sourcepub fn open_mission(
&mut self,
session_id: SessionId,
open: MissionOpen,
) -> Result<MissionId, RtError>
pub fn open_mission( &mut self, session_id: SessionId, open: MissionOpen, ) -> Result<MissionId, RtError>
Open a new Mission session and register it with the middleware.
Sourcepub fn mission_disconnect(
&mut self,
session_id: SessionId,
reason: impl Into<String>,
)
pub fn mission_disconnect( &mut self, session_id: SessionId, reason: impl Into<String>, )
Mark a mission session as disconnected and transition the transport session to the Reconnecting state.
Sourcepub fn mission_reconnect_reconcile(
&mut self,
session_id: SessionId,
mission_id: MissionId,
peer_state: MissionPeerState,
) -> Result<MissionReconcileSummary, RtError>
pub fn mission_reconnect_reconcile( &mut self, session_id: SessionId, mission_id: MissionId, peer_state: MissionPeerState, ) -> Result<MissionReconcileSummary, RtError>
After a successful reconnect, perform state reconcile with the peer.
This method:
- Marks the transport session as Connected again.
- Calls
reconcile(peer_state)on the storedBasicMissionSession. - Returns the
MissionReconcileSummaryso the caller can schedule replay.
Sourcepub fn mission_complete_replay(
&mut self,
mission_id: MissionId,
replayed: u32,
) -> Result<(), RtError>
pub fn mission_complete_replay( &mut self, mission_id: MissionId, replayed: u32, ) -> Result<(), RtError>
Advance command replay on an active mission session.
Sourcepub fn mission_next_update(
&mut self,
mission_id: MissionId,
) -> Option<MissionUpdate>
pub fn mission_next_update( &mut self, mission_id: MissionId, ) -> Option<MissionUpdate>
Drain the next update from an active mission session.