pub struct ExecSession {
pub id: String,
pub continuation: bool,
pub lease: Option<SessionLease>,
}Expand description
A long-lived downstream connection (the Responses WebSocket, GET /v1/responses)
whose turns can share upstream state. It travels next to an ExecRequest in
cpa_exec::Executors::execute_in_session. Executors that pool upstream sockets key
them by id and release them in Executors::close_session when the downstream
connection ends (Go: execution session id and CloseExecutionSession).
Fields§
§id: StringStable for the whole downstream connection.
continuation: boolThis turn continues upstream state (previous_response_id or response.append
passed through unchanged), so it must run on the session’s current upstream socket.
An executor that cannot honour that fails with ExecError::replay_required
instead of opening a fresh connection (Go: RequiredUpstreamWebsocket).
lease: Option<SessionLease>The Home pick this attempt runs on, when it came from Home (Go
Options.ExecutionLifecycle). An executor that pools the upstream socket hands
the pick to it; the pick then lasts as long as the socket.
Trait Implementations§
Source§impl Clone for ExecSession
impl Clone for ExecSession
Source§impl Debug for ExecSession
impl Debug for ExecSession
impl Eq for ExecSession
Source§impl PartialEq for ExecSession
impl PartialEq for ExecSession
impl StructuralPartialEq for ExecSession
Auto Trait Implementations§
impl !RefUnwindSafe for ExecSession
impl !UnwindSafe for ExecSession
impl Forget for ExecSession
impl Freeze for ExecSession
impl Move for ExecSession
impl Send for ExecSession
impl Sync for ExecSession
impl Unpin for ExecSession
impl UnsafeUnpin for ExecSession
Blanket Implementations§
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.