Skip to main content

Crate tauri_queue

Crate tauri_queue 

Source
Expand description

§Tauri Queue

Tauri integration for the agent-queue background job processing system.

This crate provides a TauriEventEmitter that bridges job-queue events to Tauri’s frontend event system, plus re-exports of all core job-queue types.

§Quick Start

  1. Define a job type implementing JobHandler
  2. Create a QueueManager with a QueueConfig
  3. Add jobs with QueueManager::add()
  4. Spawn the executor with QueueManager::spawn() using a TauriEventEmitter

Modules§

config
db
error
events
executor
queue
types

Structs§

CoalescingEmitter
A throttled event emitter that coalesces rapid-fire events.
EmitterConfig
Configuration for event emission backpressure and coalescing.
JobCancelledEvent
Emitted when a job is cancelled.
JobCompletedEvent
Emitted when a job completes successfully.
JobContext
Context provided to job handlers during execution.
JobFailedEvent
Emitted when a job fails.
JobProgressEvent
Emitted during job execution to report progress.
JobResult
Result returned by a job handler after execution.
JobStartedEvent
Emitted when a job starts executing.
QueueConfig
Configuration for the queue system.
QueueConfigBuilder
Builder for QueueConfig.
QueueJob
A generic queue job carrying a custom data payload.
QueueManager
High-level queue manager providing the public API.
TauriEventEmitter
Event emitter that bridges job-queue events to Tauri’s frontend event system.
TraceCtx
In-process trace context for cross-crate correlation.

Enums§

DropPolicy
Policy for handling event overflow when the downstream consumer is slow.
QueueError
Errors that can occur in the queue system.
QueueJobStatus
Job status lifecycle: Pending -> Processing -> Completed/Failed/Cancelled
QueuePriority
Priority levels for queue jobs.

Traits§

JobHandler
Trait that job types must implement to be processed by the queue.
QueueEventEmitter
Trait for emitting queue lifecycle events.

Functions§

trace_ctx_from_event_trace_id
Extract a canonical TraceCtx from a legacy trace_id string, if present.