1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
//! A drop-in replacement for `apalis-board`: HTTP surface, live updates, and the
//! `apalis-tui` dashboard.
//!
//! This crate mounts a JSON API for `apalis` job queues on an axum or actix-web server, streams
//! live task and log events over SSE, and serves a `ratatui` dashboard compiled to WebAssembly
//! from the bundle it carries. The wire contract matches `apalis-board-api` 1.0.0-rc.8 route for
//! route, and the extra routes on top of it (capabilities, actions, typed status events) are
//! additive. Repository and full documentation:
//! <https://github.com/ngriaznov/apalis-rtui>.
//!
//! Swap one line in `Cargo.toml`:
//!
//! ```toml
//! apalis-board = { package = "apalis-rtui", version = "0.1.0-rc.1", features = ["axum"] }
//! ```
//!
//! and every path a consumer already writes against `apalis-board` keeps working:
//! `apalis_board::axum::framework::{ApiBuilder, RegisterRoute}`,
//! `apalis_board::axum::sse::{TracingBroadcaster, TracingSubscriber}`,
//! `apalis_board::axum::ui::ServeUI`, `apalis_board::axum::push_task`, and the rest of the
//! framework-agnostic handler set. `apalis-rtui` mirrors that exact module shape under its own
//! name: [`axum`] and [`actix`] are each the whole ported API surface, re-exported under a
//! per-framework namespace, gated by the matching Cargo feature.
//!
//! See the crate README for the full drop-in story and feature table.
// The ported `apalis-board-api` surface. Kept private: it is reachable only through the
// per-framework `axum`/`actix` re-exports below, exactly as upstream's `apalis-board-api` is
// reachable only once a consumer opts into `apalis-board`'s `axum`/`actix` feature.
/// The axum HTTP surface: `ApiBuilder`, `RegisterRoute`, the framework-agnostic handler set,
/// live-update SSE types (`events` feature), and `ServeUI` (`ui` feature).
///
/// This module is the whole ported API surface re-exported under the `axum` namespace, mirroring
/// how `apalis_board::axum` is `pub use apalis_board_api::*` behind upstream's own `axum`
/// feature. A consumer migrating from `apalis-board` writes the identical path:
/// `apalis_rtui::axum::framework::{ApiBuilder, RegisterRoute}`.
/// The actix-web HTTP surface: `ApiBuilder`, `RegisterRoute`, the framework-agnostic handler
/// set, live-update SSE types (`events` feature), and `ServeUI` (`ui` feature).
///
/// This module is the whole ported API surface re-exported under the `actix` namespace,
/// mirroring `apalis_board::actix`'s identical role behind upstream's own `actix` feature.