pub struct SessionHistory { /* private fields */ }Implementations§
Source§impl SessionHistory
impl SessionHistory
pub fn open(config: Config) -> Result<Self>
pub fn health(&self) -> Result<(), Error>
pub fn create_session(&self, input: NewSession) -> Result<Session>
pub fn open_session(&self, metadata: SessionMetadata) -> Result<Session>
pub fn open_session_with_provider_model( &self, metadata: SessionMetadata, provider_model: Option<&str>, ) -> Result<Session>
Sourcepub fn legacy_provider_cost_summary_for_archive(
&self,
archive: &Value,
session_state: Option<&Value>,
) -> Result<Option<ProviderCostSummary>>
pub fn legacy_provider_cost_summary_for_archive( &self, archive: &Value, session_state: Option<&Value>, ) -> Result<Option<ProviderCostSummary>>
Reconstructs only the display-cost fields for an immutable session archive.
The configured compatibility callbacks own model recovery and pricing. The
archive and its checksummed event stream are never modified. Metadata-free
session-log archives predate this Chatend projection and return None.
pub async fn register( &self, input: RegisterSession, ) -> Result<SessionRecord, Error>
pub async fn start( &self, input: StartSession, ) -> Result<Created<SessionRecord>, Error>
pub async fn enqueue_ingress( &self, input: NewIngressSession, ) -> Result<Created<SessionRecord>, Error>
pub async fn list(&self) -> Result<Vec<SessionRecord>, Error>
pub async fn get(&self, id: &str) -> Result<SessionRecord, Error>
pub async fn enqueue( &self, id: &str, input: NewCommand, ) -> Result<Created<SessionCommand>, Error>
pub async fn command_heads(&self) -> Result<Vec<SessionCommand>, Error>
pub async fn claim_command(&self, id: &str) -> Result<SessionCommand, Error>
pub async fn complete_command( &self, id: &str, outcome: CommandOutcome, ) -> Result<SessionCommand, Error>
pub async fn request_stop( &self, id: &str, input: NewStopRequest, ) -> Result<Created<SessionStopRequest>, Error>
Sourcepub async fn request_current_work_stop(
&self,
id: &str,
input: NewCurrentWorkStop,
) -> Result<Created<SessionStopRequest>, Error>
pub async fn request_current_work_stop( &self, id: &str, input: NewCurrentWorkStop, ) -> Result<Created<SessionStopRequest>, Error>
Requests the stop appropriate to the session’s current durable work.
Interactive sessions stop only their current turn, self-time stops its current run, and all other work stops through ordinary session completion. Scope derivation, queued-command cancellation, durable request creation, and live-listener notification are one owner-level operation.
Sourcepub fn listen_for_stop(&self, id: &str) -> Result<StopListener, Error>
pub fn listen_for_stop(&self, id: &str) -> Result<StopListener, Error>
Registers the orchestration owner for prompt notification of a stop.
Registration is restart-safe: an already-pending durable request signals the returned listener before this method returns.
pub async fn stop_heads(&self) -> Result<Vec<SessionStopRequest>, Error>
pub async fn complete_stop( &self, id: &str, outcome: StopOutcome, ) -> Result<SessionStopRequest, Error>
pub async fn stage_object( &self, id: &str, object: NewObject, ) -> Result<String, Error>
pub fn object(&self, id: &str, pending_id: &str) -> Result<StoredObject, Error>
pub async fn checkpoint( &self, id: &str, input: Checkpoint, ) -> Result<SessionRecord, Error>
pub async fn request_ingress( &self, id: &str, input: Checkpoint, ) -> Result<SessionRecord, Error>
pub async fn start_ingress( &self, id: &str, input: StartIngress, ) -> Result<SessionRecord, Error>
pub async fn complete_ingress( &self, id: &str, input: ExpectedVersion, ) -> Result<SessionRecord, Error>
pub async fn fail_ingress( &self, id: &str, input: IngressFailure, ) -> Result<SessionRecord, Error>
pub async fn retry_ingress( &self, id: &str, input: RetryIngress, ) -> Result<SessionRecord, Error>
pub async fn release_interrupted_ingress(&self) -> Result<Vec<String>, Error>
pub async fn complete( &self, id: &str, input: Checkpoint, ) -> Result<SessionRecord, Error>
pub async fn record_completion( &self, input: RecordCompletion, ) -> Result<(), Error>
Trait Implementations§
Source§impl Clone for SessionHistory
impl Clone for SessionHistory
Source§fn clone(&self) -> SessionHistory
fn clone(&self) -> SessionHistory
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more