pub struct DriverHandler { /* private fields */ }
Expand description
The DriverHandler handles incoming gRPC requests. This is effectively what ‘drives’ the driver.
Implementations§
Source§impl DriverHandler
impl DriverHandler
Sourcepub fn new(
node_config_path: impl Into<PathBuf>,
proxy: Arc<ProxyClient>,
) -> Self
pub fn new( node_config_path: impl Into<PathBuf>, proxy: Arc<ProxyClient>, ) -> Self
Constructor for the DriverHandler.
§Arguments
node_config_path
: The path to thenode.yml
file that describes this node’s environment. For the handler, this is the path to theinfra.yml
file (and an optionalsecrets.yml
) and the topic to send commands to the planner on.proxy
: The (shared) ProxyClient that we use to connect to/throughbrane-prx
.planner
: The InstancePlanner that handles our side of planning.
§Returns
A new DriverHandler instance.
Trait Implementations§
Source§impl Clone for DriverHandler
impl Clone for DriverHandler
Source§fn clone(&self) -> DriverHandler
fn clone(&self) -> DriverHandler
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl DriverService for DriverHandler
impl DriverService for DriverHandler
Source§fn create_session<'life0, 'async_trait>(
&'life0 self,
_request: Request<CreateSessionRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<CreateSessionReply>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn create_session<'life0, 'async_trait>(
&'life0 self,
_request: Request<CreateSessionRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<CreateSessionReply>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn check<'life0, 'async_trait>(
&'life0 self,
request: Request<CheckRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<CheckReply>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn check<'life0, 'async_trait>(
&'life0 self,
request: Request<CheckRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<CheckReply>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn execute<'life0, 'async_trait>(
&'life0 self,
request: Request<ExecuteRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<Self::ExecuteStream>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn execute<'life0, 'async_trait>(
&'life0 self,
request: Request<ExecuteRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<Self::ExecuteStream>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§type ExecuteStream = ReceiverStream<Result<ExecuteReply, Status>>
type ExecuteStream = ReceiverStream<Result<ExecuteReply, Status>>
The response type for stream returned by
DriverService::execute()
.Auto Trait Implementations§
impl Freeze for DriverHandler
impl !RefUnwindSafe for DriverHandler
impl Send for DriverHandler
impl Sync for DriverHandler
impl Unpin for DriverHandler
impl !UnwindSafe for DriverHandler
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request