Skip to content

feat: introduce LiveVOD service and consolidate storage backend to S3#330

Open
4627488 wants to merge 14 commits intobinbat:mainfrom
4627488:s3-based-recorder
Open

feat: introduce LiveVOD service and consolidate storage backend to S3#330
4627488 wants to merge 14 commits intobinbat:mainfrom
4627488:s3-based-recorder

Conversation

@4627488
Copy link
Copy Markdown
Contributor

@4627488 4627488 commented Jan 31, 2026

This pull request introduces LiveVOD, a new lightweight playback service, and refactors the storage architecture to exclusively support S3-compatible backends. It also implements asynchronous upload logic using presigned URLs and adds new REST APIs for recording index synchronization.

Key Changes

1. LiveVOD Service Introduction

  • Added a new binary target livevod.
  • Added configuration template conf/livevod.toml.
  • LiveVOD allows playback using only index files and S3 storage, decoupling playback from the core recording logic.

2. Storage Backend Consolidation

  • Refactor: Standardized the recording storage backend to S3-only.
  • Removal: Removed code, configuration, and documentation references for local filesystem and OSS backends.

3. Asynchronous Upload & API Extensions

  • Async Upload: Implemented asynchronous upload support using presigned URLs via the Liveman API.

  • Configuration: Added the [recorder.upload] section to the configuration.

  • New Endpoints: Added APIs for recording index synchronization and state management:

  • GET /api/recordings: List recordings.

  • POST /api/recordings/ack: Acknowledge recordings (updates status to Acked).

  • POST /api/recordings/delete: Delete recordings.

  • Model Update: Updated RecordingStatus enum to support the Acked variant.

4. Documentation & Dependencies

  • Added docs/guide/livevod.md (EN/ZH).
  • Updated existing documentation to reflect the removal of non-S3 backends.
  • Updated Cargo.toml dependencies (axum, opendal, anyhow, etc.).

Breaking Changes

  • Storage Support: Support for local filesystem and OSS backends has been removed. Existing configurations using these backends must be migrated to S3-compatible storage.

Configuration Updates

  • New: conf/livevod.toml created for the new service.
  • Modified: recorder.toml now requires S3 configuration and supports the optional [recorder.upload] section.

@codecov
Copy link
Copy Markdown

codecov bot commented Jan 31, 2026

Codecov Report

❌ Patch coverage is 7.39300% with 238 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
src/livevod.rs 0.00% 185 Missing ⚠️
liveion/src/route/admin.rs 0.00% 21 Missing ⚠️
liveman/src/tick.rs 0.00% 21 Missing ⚠️
liveion/src/route/recorder.rs 37.50% 5 Missing ⚠️
liveman/src/route/mod.rs 0.00% 3 Missing ⚠️
libs/api/src/recorder.rs 0.00% 2 Missing ⚠️
liveman/src/route/proxy.rs 0.00% 1 Missing ⚠️
Files with missing lines Coverage Δ
libs/api/src/path.rs 85.71% <100.00%> (+2.38%) ⬆️
libs/storage/src/config.rs 100.00% <100.00%> (+27.27%) ⬆️
libs/storage/src/operator.rs 63.93% <ø> (-6.78%) ⬇️
liveion/src/config.rs 50.00% <ø> (+1.02%) ⬆️
liveion/src/forward/internal.rs 63.54% <ø> (+7.31%) ⬆️
liveion/src/forward/mod.rs 50.76% <ø> (+2.75%) ⬆️
liveman/src/route/proxy.rs 0.00% <0.00%> (ø)
libs/api/src/recorder.rs 0.00% <0.00%> (ø)
liveman/src/route/mod.rs 0.00% <0.00%> (ø)
liveion/src/route/recorder.rs 21.42% <37.50%> (-2.90%) ⬇️
... and 3 more

... and 54 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@4627488 4627488 marked this pull request as ready for review January 31, 2026 09:32
@a-wing
Copy link
Copy Markdown
Member

a-wing commented Mar 30, 2026

Need add local file system storage

@4627488 4627488 force-pushed the s3-based-recorder branch from 5a4e6a7 to 94f8f0c Compare March 30, 2026 07:07
# Need enabled `--features=source-rtsp`
# - RTSP: rtsp://username:password@host:port/path
# url = "rtsp://username:password@host:port/path"

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't delete this...

# auto_streams = ["*"] # Record all streams
# Optional path for recorder index file (index.json)
# index_path = "./storage/index.json"
# index_path = "./records/index.json"
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In conf/livevod.toml index_path = "./recordings/index.json"

In docs ./storage/index.json ?

Which one is right?

# liveman_url = "http://127.0.0.1:8888"
# liveman_token = "live777"
# queue_path = "./recordings/upload_queue.jsonl"
# local_dir = "./recordings"
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤔

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants