Skip to main content

TcpRankSession

Struct TcpRankSession 

Source
pub struct TcpRankSession { /* private fields */ }

Implementations§

Source§

impl TcpRankSession

Source

pub fn connect( address: impl ToSocketAddrs, unique_id: UniqueId, rank: u32, world_size: u32, timeout: Duration, ) -> Result<Self, NetworkError>

Source

pub fn connect_with_p2p_rails( address: impl ToSocketAddrs, unique_id: UniqueId, rank: u32, world_size: u32, timeout: Duration, p2p_rails: usize, ) -> Result<Self, NetworkError>

Source

pub fn connect_with_transport( address: impl ToSocketAddrs, unique_id: UniqueId, rank: u32, world_size: u32, timeout: Duration, p2p_rails: usize, transport: CollectiveTransport, ) -> Result<Self, NetworkError>

Source

pub const fn rank(&self) -> u32

Source

pub const fn world_size(&self) -> u32

Source

pub const fn transport(&self) -> CollectiveTransport

Source

pub fn p2p_rails(&self) -> usize

Source

pub fn probe_topology_from_environment( &self, ) -> Result<CollectiveTopology, NetworkError>

Source

pub fn probe_topology( &self, options: TopologyProbeOptions, ) -> Result<CollectiveTopology, NetworkError>

Source

pub fn heartbeat(&self, timeout: Duration) -> Result<Duration, NetworkError>

Source

pub fn send( &self, destination: u32, tag: u64, element_type: ElementType, element_count: u64, payload: Vec<u8>, ) -> Result<(), NetworkError>

Source

pub fn send_on_rail( &self, rail: usize, destination: u32, tag: u64, element_type: ElementType, element_count: u64, payload: Vec<u8>, ) -> Result<(), NetworkError>

Source

pub fn receive( &self, source: Option<u32>, tag: u64, element_type: ElementType, element_count: u64, ) -> Result<Frame, NetworkError>

Source

pub fn receive_on_rail( &self, rail: usize, source: Option<u32>, tag: u64, element_type: ElementType, element_count: u64, ) -> Result<Frame, NetworkError>

Source

pub fn exchange( &self, opcode: Opcode, element_type: ElementType, root_rank: u32, element_count: u64, payload: Vec<u8>, ) -> Result<Frame, NetworkError>

Source

pub fn exchange_with_options( &self, opcode: Opcode, element_type: ElementType, options: ExchangeOptions, payload: Vec<u8>, ) -> Result<Frame, NetworkError>

Source

pub fn barrier(&self) -> Result<(), NetworkError>

Source

pub fn set_timeout(&self, timeout: Duration) -> Result<(), NetworkError>

Source

pub fn abort(&self, message: &str) -> Result<(), NetworkError>

Notify every rank that this process is abandoning the current session. The abort uses the independent P2P channel so it can interrupt a rank waiting in the ordered collective channel.

Trait Implementations§

Source§

impl Debug for TcpRankSession

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl RankTransport for TcpRankSession

Source§

fn rank(&self) -> u32

Source§

fn world_size(&self) -> u32

Source§

fn transport(&self) -> CollectiveTransport

Source§

fn p2p_rails(&self) -> usize

Source§

fn heartbeat(&self, timeout: Duration) -> Result<Duration, NetworkError>

Source§

fn send_on_rail( &self, rail: usize, destination: u32, tag: u64, element_type: ElementType, element_count: u64, payload: Vec<u8>, ) -> Result<(), NetworkError>

Source§

fn receive_on_rail( &self, rail: usize, source: Option<u32>, tag: u64, element_type: ElementType, element_count: u64, ) -> Result<Frame, NetworkError>

Source§

fn exchange_with_options( &self, opcode: Opcode, element_type: ElementType, options: ExchangeOptions, payload: Vec<u8>, ) -> Result<Frame, NetworkError>

Source§

fn set_timeout(&self, timeout: Duration) -> Result<(), NetworkError>

Source§

fn abort(&self, message: &str) -> Result<(), NetworkError>

Source§

fn send( &self, destination: u32, tag: u64, element_type: ElementType, element_count: u64, payload: Vec<u8>, ) -> Result<(), NetworkError>

Source§

fn receive( &self, source: Option<u32>, tag: u64, element_type: ElementType, element_count: u64, ) -> Result<Frame, NetworkError>

Source§

fn exchange( &self, opcode: Opcode, element_type: ElementType, root_rank: u32, element_count: u64, payload: Vec<u8>, ) -> Result<Frame, NetworkError>

Source§

fn barrier(&self) -> Result<(), NetworkError>

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<A, B, T> HttpServerConnExec<A, B> for T
where B: Body,

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more