-
Notifications
You must be signed in to change notification settings - Fork 55
Add selfstreaming feature to the runners #1657
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
base: dev
Are you sure you want to change the base?
Conversation
|
Fixes #1654 |
7c51588 to
0ebe546
Compare
Co-authored-by: Joscha Henningsen <[email protected]>
Co-authored-by: Joscha Henningsen <[email protected]>
Co-authored-by: Joscha Henningsen <[email protected]>
Co-authored-by: Joscha Henningsen <[email protected]>
8e9e776 to
dc7caa9
Compare
dc7caa9 to
515502a
Compare
joschahenningsen
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry for being so verbose reviewing some of the old worker code, I think it's worthwile to re-think how it was done back then now and get rid of some of that tech depth :)
Overall, I really love the approach of having gocast be the initiator of self-streams as though they were normal lecture-hall streams!
joschahenningsen
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One concern with this, otherwise looks great! 💯
| return nil, err | ||
| } | ||
|
|
||
| resp, err := m.requestStreamVersion(ctx, stream, client, model.LectureHall{}, protobuf.StreamVersion_STREAM_VERSION_COMBINED) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to make sure, this is requested at the same runner, that this request originates from, otherwise it will break as soon as we have more than one runner
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You're right, I forgot to implement this. An alternative would be to have only one mediaMTX instance at a time and then distribute the load of selfstreams evenly to the runners as every runner could fetch the stream from this instance and we wouldn't rely on only one machine for a stream (except for the mediaMTX). What do you think about this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd like all runners to be treated the same, let's design this to work without magic knowledge of what which runner does
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we need load balancing to multiple ingest servers, let's use traefik and DNS rr to distribute streams to multiple runners
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This means we only have one mediamtx for all instead of having one for each runner?
|
Whole functionality of requesting a selfstream now moved to main instance (gocast), so that every runner can handle the selfstreaming requests. |
Motivation and Context
This PR adds the selfstreaming to the runners
Important
Please first merge #1656, as these PRs build on top of each other