Skip to content

Feat/media pipeline completion - #14

Merged
alescis-wuin merged 41 commits into
mainfrom
feat/media-pipeline-completion
Jun 18, 2026
Merged

alescis-wuin merged 41 commits into
mainfrom
feat/media-pipeline-completion

Conversation

@alescis-wuin

Copy link
Copy Markdown
Owner

This pull request introduces significant improvements to media upload, validation, and publication workflows, along with enhancements to metadata handling and documentation. The main changes include support for publication status management, advanced media validation, improved metadata extraction, and updates to how media is stored and processed.

Media Upload & Publication Workflow:

  • Added support for specifying and updating the publication status (DRAFT/PUBLISHED) for videos during upload and update operations, including input validation and propagation throughout search and sorting features. [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11]

Media Validation & Processing:

  • Introduced advanced media validation on upload, including checks for extension, MIME type, container signature, duration, video stream presence, and codec policy. [1] [2]
  • Media uploads now support memory-first storage for small files, and jobs are automatically submitted for transcoding after upload if enabled. [1] [2]

Metadata Extraction Enhancements:

  • Extended media probe and metadata extraction to include video codec, and boolean flags for presence of video and audio streams, improving the information available for validation and display. [1] [2] [3] [4] [5]

Storage & Persistence Updates:

  • Updated MinIO usage to store original media, subtitles, and generated HLS/thumbnails, with documentation and configuration reflecting these changes. [1] [2] [3]

Documentation & Configuration:

  • Updated README.md to document new validation steps, publication status, storage changes, and added new environment variables for source validation and HLS variants. [1] [2] [3]

These changes collectively improve the robustness, flexibility, and clarity of the media management workflow.

Propagate cancellation tokens to every FFmpeg variant and thumbnail command.
Externalize HLS variants, thumbnail count, playlist flags and CPU/NVIDIA presets.
Keep default overloads for existing callers while workers can now stop running encodes.

Refs: streamfolio-media-pipeline-completion
Pass each job cancellation token to FFmpeg-backed transcode calls.
Clear cancellation state once jobs reach terminal outcomes.

Refs: streamfolio-media-pipeline-completion
Adapt the fake FFmpeg service to the cancellable command API.
Add a focused assertion that an already-cancelled token stops HLS generation.

Refs: streamfolio-media-pipeline-completion
Adapt worker tests to the cancellable transcoding signatures.
Cover cancelled child jobs as a distinct terminal state.

Refs: streamfolio-media-pipeline-completion
Create a bounded executor dedicated to file persistence.
Keep transcode workers isolated from request-side media storage work.

Refs: streamfolio-media-pipeline-completion
Buffer small media files in memory before asynchronous disk persistence.
Publish stored originals and subtitles to MinIO when object storage is enabled.
Keep large files on streaming disk persistence to avoid excessive heap pressure.

Refs: streamfolio-media-pipeline-completion
Start a transcode job after upload when local or MinIO-backed media storage is active.
Keep classpath demo storage read-only and configurable through application properties.

Refs: streamfolio-media-pipeline-completion
Return video codec and stream presence from ffprobe metadata.
Keep existing metadata extraction behavior while enabling stricter upload validation.

Refs: streamfolio-media-pipeline-completion
Expose stream details returned by the backend probe service.
Use these fields in validation and admin diagnostics.

Refs: streamfolio-media-pipeline-completion
Validate stored sources with container signatures, duration, stream presence and codec policy.
Keep strict rejection configurable so development fixtures can stay lightweight.

Refs: streamfolio-media-pipeline-completion
Run advanced source validation after media persistence and before catalog creation.
Allow admin upload and edit flows to set DRAFT or PUBLISHED states explicitly.

Refs: streamfolio-media-pipeline-completion
Allow admin uploads to set DRAFT or PUBLISHED at creation time.
Preserve the existing default when the field is omitted.

Refs: streamfolio-media-pipeline-completion
Require at least one published video in public catalog specifications.
Keep admin listings unaffected by the public visibility rule.

Refs: streamfolio-media-pipeline-completion
Filter public details, playback, progress and watchlist operations to published videos only.
Allow HLS playback discovery for both local and MinIO-backed generated outputs.

Refs: streamfolio-media-pipeline-completion
Add publication controls to upload and edit flows without changing existing route modules.
Add cancel and retry job actions that call the hardened admin transcode APIs.

Refs: streamfolio-media-pipeline-completion
Register the admin enhancement module after the main application bundle.
Keep the existing route module unchanged while adding publication and job controls.

Refs: streamfolio-media-pipeline-completion
Add upload persistence, validation and auto-transcode settings.
Expose the complete HLS variant policy through configuration.

Refs: streamfolio-media-pipeline-completion
…dation

Require valid duration, readable video streams and configured source validation in prod.
Keep MinIO and secure-cookie defaults production-oriented.

Refs: streamfolio-media-pipeline-completion
Disable automatic transcodes for controller fixtures to keep integration tests deterministic.
Assert that DRAFT videos stay out of the public catalog and PUBLISHED videos reappear.

Refs: streamfolio-media-pipeline-completion
Assert container signature rejection in strict mode.
Assert valid signatures and codecs pass the production validation path.

Refs: streamfolio-media-pipeline-completion
Verify the upload page exposes the state selector.
Keep the existing required-field coverage unchanged.

Refs: streamfolio-media-pipeline-completion
Document cancellable jobs, source validation, MinIO originals and configurable HLS policy.
Align the phase validation notes with the current implementation.

Refs: streamfolio-media-pipeline-completion
…dation

Read only the container header needed for signature detection.
Keep large uploaded media files off heap during advanced validation.

Refs: streamfolio-media-pipeline-completion
Delete the narrower work-item migration because V2__transcode_queue_hardening already applies the same columns idempotently.
This fixes Docker startup with PostgreSQL and Flyway.

Refs: streamfolio-media-pipeline-completion
Use an in-memory session store for default and local development profiles.
Keep Redis sessions explicit for Docker, PostgreSQL and production profiles.

Refs: streamfolio-media-pipeline-completion
Prefer the local store when it is explicitly enabled for development.

Refs: streamfolio-media-pipeline-completion
Enable the memory session store when no explicit session-store mode is configured.
Docker and production profiles set the mode to redis.

Refs: streamfolio-media-pipeline-completion
Set the security session-store mode explicitly for Docker Compose.
This keeps local default runs in memory while compose uses Redis.

Refs: streamfolio-media-pipeline-completion
Remove the primary marker from the legacy test store now that local sessions are primary in development profiles.

Refs: streamfolio-media-pipeline-completion
Avoid a Java record accessor conflict by renaming the boolean component from valid to ok.
Keep the existing static factory methods unchanged.

Refs: streamfolio-media-pipeline-completion
Allow local media mode to read bundled demo originals and subtitles when no local file exists.
Provide a staging helper so FFmpeg can transcode bundled media from a local path.

Refs: streamfolio-media-pipeline-completion
Ask media storage to prepare a local source path before running FFmpeg.
This lets the default local mode transcode bundled demo media as well as uploaded media.

Refs: streamfolio-media-pipeline-completion
Default the development profile to local media storage so upload and transcode flows work without an explicit profile.
MediaStorageService still falls back to bundled classpath media when local demo files are absent.

Refs: streamfolio-media-pipeline-completion
…plicit

Guard local streaming fallback behind streamfolio.media.classpath-fallback.
Keep FFmpeg staging able to copy bundled demo sources for transcode jobs.

Refs: streamfolio-media-pipeline-completion
… media test

Keep the local media integration contract strict: missing local originals return 404.
Default application runs can still opt into bundled classpath fallback.

Refs: streamfolio-media-pipeline-completion
Keep security assertions independent from local HLS files produced by media pipeline tests.
Streaming-specific tests continue to cover local media and HLS availability.

Refs: streamfolio-media-pipeline-completion
Automate git update, Docker rebuild, container log capture, E2E, validate and local boot checks.
Store every command output in a unique run directory while keeping console progress concise and colored.

Refs: streamfolio-media-pipeline-completion
Generate tiny FFmpeg fixtures for accepted video containers and verify HLS outputs, variants, segments and thumbnails.
Cover local and MinIO-backed storage in CPU mode, with optional GPU-profile runs enabled by environment flags.

Refs: streamfolio-media-pipeline-completion
Explain the full-check script output layout and the opt-in transcoding matrix.
Document CPU, MinIO and optional GPU-profile validation commands.

Refs: streamfolio-media-pipeline-completion
Avoid mutating the step counter inside command substitution subshells.
Produce correctly numbered console lines and log files.

Refs: streamfolio-media-pipeline-completion
Do not pass -ss 0 before non-seekable inputs such as generated SWF fixtures.
Use output seeking only when a positive timestamp is requested.

Refs: streamfolio-media-pipeline-completion
@alescis-wuin alescis-wuin self-assigned this Jun 18, 2026
@alescis-wuin
alescis-wuin merged commit 1991366 into main Jun 18, 2026
1 check passed
@alescis-wuin
alescis-wuin deleted the feat/media-pipeline-completion branch June 18, 2026 11:43
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.

1 participant