Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initial replay functionality #3395

Draft
wants to merge 535 commits into
base: replays-clips-recordings
Choose a base branch
from

Conversation

gabek
Copy link
Member

@gabek gabek commented Oct 26, 2023

This is the core internal functionality to support stream replays and clips with Owncast. There is no UI, and it is disabled by default. Use --enableReplayFeatures to enable the feature flag.

Also enables S3 path prefix, to support a custom path within an object storage bucket.

This is not yet useful to people, as it's just a bunch of APIs (that do function), but is the first step to have this functionality.

There is also no cleanup logic. When enabled all video is saved on disk forever.


Details

  • /api/replays returns a list of all the streams that are replayable.

URLs are generated as so:

  • /replay/streamId for master playlists.
  • /replay/streamId/configurationId for media playlists.

Testing in progress stream

  1. Start a live stream
  2. Visit http://localhost:8080/api/replays
  3. Note the "manifest " path.
  4. Put the manifest url in your livestreaming video player of choice.
  5. Play it. It will be treated as an updating (event) style stream.

Testing completed streams

  1. Stop the live stream.
  2. Visit http://localhost:8080/api/replays
  3. Notice this stream is no longer in progress.
  4. Put the manifest url in your livestreaming video player of choice.
  5. Play it. It will be treated as a static (VOD) stream and will not update.

Clips

  • Follow the instructions above to have a replay of a stream.
  • Get the streamId you want to create a clip from.
  • Determine the start and end points, in seconds, for this clip, relative to the beginning of the stream.
  • Use the clip create API to create the clip as a JSON payload to /api/clip with streamId, clipTitle, relativeStartTimeSeconds and relativeEndTimeSeconds
http http://localhost:8080/api/clip streamId="oYk3sL6Vg" clipTitle="Test clip 5" relativeStartTimeSeconds:=10 relativeEndTimeSeconds:=17

image

  • List all clips with the clips api /api/clips.
    image

  • Fetch a single clip with /clip/{clipId}.

  • It will return back a HLS master playlist that is playable.

image

gabek and others added 30 commits October 26, 2023 13:13
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Bumps [postcss](https://github.com/postcss/postcss) from 8.4.29 to 8.4.31.
- [Release notes](https://github.com/postcss/postcss/releases)
- [Changelog](https://github.com/postcss/postcss/blob/main/CHANGELOG.md)
- [Commits](postcss/postcss@8.4.29...8.4.31)

---
updated-dependencies:
- dependency-name: postcss
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [zod](https://github.com/colinhacks/zod) to 3.22.4 and updates ancestor dependency [next](https://github.com/vercel/next.js). These dependencies need to be updated together.


Updates `zod` from 3.22.2 to 3.22.4
- [Release notes](https://github.com/colinhacks/zod/releases)
- [Changelog](https://github.com/colinhacks/zod/blob/master/CHANGELOG.md)
- [Commits](colinhacks/zod@v3.22.2...v3.22.4)

Updates `next` from 13.4.19 to 13.5.4
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](vercel/next.js@v13.4.19...v13.5.4)

---
updated-dependencies:
- dependency-name: zod
  dependency-type: indirect
- dependency-name: next
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Pranav2612000 and others added 18 commits October 26, 2023 13:14
the absolute positioned mobile action button was attached
to the body causing it to float during scrolling. Now, we wrap
the action buttons inside a relative div so that they are attached
to this div which prevents them from scrolling with page
Fixes #3271

Co-authored-by: Gabe Kangas <gabek@real-ity.com>
Co-authored-by: Meisam Farzalipour Tabriz <5204-tbz@users.noreply.gitlab.mpcdf.mpg.de>
* chore(deps): update dependency typescript to v5

* fix: resolve type mismatch

* Commit updated API documentation

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Gabe Kangas <gabek@real-ity.com>
Co-authored-by: Owncast <owncast@owncast.online>
@gabek gabek changed the base branch from replays-clips to replays-clips-recordings October 27, 2023 00:06
Copy link

stale bot commented Dec 15, 2023

This pull request has not had any activity in 30 days. Since things move fast it's best to get PRs merged in. If this PR addresses a previously filed issue that needs to be resolved please work to get it merged in, or allow somebody else to work on a fix. This PR will be closed if no further activity occurs. Thank you for your contributions!

@stale stale bot added the stale label Dec 15, 2023
@gabek gabek removed the stale label Dec 19, 2023
Copy link

stale bot commented Mar 13, 2024

This pull request has not had any activity in 30 days. Since things move fast it's best to get PRs merged in. If this PR addresses a previously filed issue that needs to be resolved please work to get it merged in, or allow somebody else to work on a fix. This PR will be closed if no further activity occurs. Thank you for your contributions!

@stale stale bot added the stale label Mar 13, 2024
@gabek gabek removed the stale label Mar 13, 2024
Copy link

stale bot commented Apr 22, 2024

This pull request has not had any activity in 30 days. Since things move fast it's best to get PRs merged in. If this PR addresses a previously filed issue that needs to be resolved please work to get it merged in, or allow somebody else to work on a fix. This PR will be closed if no further activity occurs. Thank you for your contributions!

@stale stale bot added the stale label Apr 22, 2024
@gabek gabek removed the stale label Apr 22, 2024
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.

None yet

8 participants