Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
ec3028c
quest: claim m1/archive/producer
kixelated Oct 21, 2026
0cca85e
wip(archive): archive::Producer records every track of one broadcast
kixelated Oct 21, 2026
b29b857
wip(archive): moq export archive records every broadcast under its pr…
kixelated Oct 21, 2026
11fe890
Merge remote-tracking branch 'origin/main' into quest/m1/archive/prod…
kixelated Oct 21, 2026
d7da5f1
chore(archive): drop the unused moq-mux dependency and format
kixelated Oct 21, 2026
d606088
fix(archive): box group consumers and keep producer tests on the ambi…
kixelated Oct 21, 2026
7b3715b
style(archive): sort imports
kixelated Oct 21, 2026
bbddb04
docs(archive): link the MIGRATE entries to #6160
kixelated Oct 21, 2026
d64f542
Merge remote-tracking branch 'origin/main' into iterate-6160
kixelated Oct 21, 2026
6c48d17
fix(archive): record partial groups and covering routes
kixelated Oct 21, 2026
47c801a
revert(cli): leave paths under a covering route unrecorded
kixelated Oct 21, 2026
5212f06
fix(archive): a fresh track waits for a group below its first arrival
kixelated Oct 21, 2026
a9da64e
Merge remote-tracking branch 'origin/main' into iterate-6160
kixelated Oct 21, 2026
5d4f7c4
fix(cli)!: export archive keys each instance <path>/@<epoch>, prefix-…
kixelated Oct 21, 2026
b2d5a0d
fix(archive)!: split untimed groups and order arrivals through one co…
kixelated Oct 21, 2026
9b4a7ed
fix(archive): date a gap from its first sight, and read an older .inf…
kixelated Oct 21, 2026
79b2e5a
fix(archive): store a run under its subscribed instance's properties
kixelated Oct 21, 2026
dc0e354
fix(archive): bound arrivals and queued infos, and record re-announce…
kixelated Oct 21, 2026
8fc2784
Merge remote-tracking branch 'origin/main' into iterate-6160
kixelated Oct 21, 2026
15ae0bc
fix(cli): resolve each archive announcement when read, and record a b…
kixelated Oct 21, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

41 changes: 23 additions & 18 deletions doc/bin/cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ Docker; see [Install](/setup/install).
| `export` | `fmp4`, `mkv`, `ts`, `flv`, `h264`, `h265` | Write a container to stdout. |
| `export` | `hls --listen` | Serve the broadcast as HLS over HTTP. |
| `export` | `rtmp`, `srt`, `rtc` | Serve plays (`--listen`) or push to a remote (`--connect`). |
| `export` | `archive <url>` | Record the broadcast into an object store. |
| `export` | `archive <url>` | Record every broadcast under the prefix into an object store. |
| `play` | | Decode and play in a native window with sound. |
| `transcode` | | Publish a just-in-time rendition ladder next to a broadcast. |
| `announced` | `[prefix]` | Follow the broadcasts announced on a relay. |
Expand Down Expand Up @@ -298,26 +298,31 @@ equivalents.
## Archive

```bash
# Record a broadcast until it ends
moq --connect https://relay.example.com/anon --broadcast event.hang export archive s3://recordings/event
# Record every broadcast announced under `event`
moq --connect https://relay.example.com/anon --broadcast event export archive s3://recordings

# Replay it under another name
# Replay a timeline recording under another name
moq --connect https://relay.example.com/anon --broadcast event-replay.hang import archive s3://recordings/event
```

`export archive` records one broadcast with
[moq-archive](https://docs.rs/moq-archive), cutting each track into 2-10 s
spans at group boundaries. An [untimed](/concept/moq-lite#subscriptions) track,
as every track is over moq-lite before 05 and moq-transport 14-16, is stored
one group per span and replays untimed. A store that already holds the recording is
continued, unless the source now announces another
[epoch](/concept/moq-lite#publisher-epochs): that is a restart, so the export
fails; record it under a new prefix. `--retention 1h` keeps only the last
hour, a DVR, which refuses an untimed track since it has no time to measure.

`import archive` republishes a recording as live tracks, fetching spans on
request. It ends where the recording ends; `--follow 2s` keeps polling a
recording still being made.
`export archive` records every broadcast announced at or under `--broadcast`
Comment thread
coderabbitai[bot] marked this conversation as resolved.
Resolved
with [moq-archive](https://docs.rs/moq-archive), each publisher instance under
`<broadcast>/@<epoch>` in the store, until the connection ends. Like
`announced`, it leaves out a broadcast whose name starts with `.` unless
`--broadcast` names it. A broadcast path segment that starts with `@` is
stored as `%40`, so no recording lands inside another. Every track is stored as its own objects, cut about every 2 s
of media (or wall clock for an [untimed](/concept/moq-lite#subscriptions)
track) and at least every 4 s, splitting a long group between frames. A broadcast restarted under a new
[epoch](/concept/moq-lite#publisher-epochs) records under its own key; a route
without an epoch gets a fresh one each time it announces, so it never resumes
or stitches into an older recording. Any recording that fails ends the export.
`--retention 1h` keeps only the last hour, a DVR, deleting older objects
`--retention-grace` (default 30 s) after they leave the window.

`import archive` republishes a timeline recording made by an older `moq` as
live tracks, fetching spans on request. It ends where the recording ends;
`--follow 2s` keeps polling a recording still being made. It does not yet read
the per-track layout that `export archive` writes.

Store URLs are `file:///absolute/path`, `s3://bucket/prefix`,
`gs://bucket/prefix`, or `az://container/prefix`, with credentials from the
Expand All @@ -332,7 +337,7 @@ over one connection:
moq --connect https://relay.example.com/anon \
import --broadcast event.hang srt --listen 0.0.0.0:9000 \
-- export --broadcast event.hang hls --listen 0.0.0.0:8080 \
-- export --broadcast event.hang archive file:///recordings/event
-- export --broadcast event.hang archive file:///recordings
```

## Publisher runs
Expand Down
2 changes: 1 addition & 1 deletion doc/lib/rs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ links cover crates awaiting their first release.
| [moq-uring](https://docs.rs/moq-uring) | Experimental Linux io\_uring server for moq-lite. |
| [hang](/lib/rs/hang) | The media layer: catalog, containers, ordered frame delivery. |
| [moq-mux](/lib/rs/moq-mux) | Import and export fMP4/CMAF, MPEG-TS, Matroska, FLV, and Annex-B. |
| [moq-archive](https://docs.rs/moq-archive) | Record and replay hang broadcasts on any `object_store` backend. |
| [moq-archive](https://docs.rs/moq-archive) | Record and replay MoQ broadcasts on any `object_store` backend. |
| [moq-video](/lib/rs/moq-video) | Native capture, hardware encode/decode (Apple, Windows, NVIDIA, VAAPI, V4L2, Android), and GPU rendering. |
| [moq-v4l](https://docs.rs/moq-v4l) | Safe Video4Linux 2 bindings. |
| [moq-audio](/lib/rs/moq-audio) | Microphone and speaker, Opus/PCM/AAC codecs, echo cancellation. |
Expand Down
Loading
Loading