Skip to content

[RTC-308] Make simulcast configurable#68

Merged
sgfn merged 2 commits intomainfrom
sgfn/RTC-308-configurable-simulcast
Aug 11, 2023
Merged

[RTC-308] Make simulcast configurable#68
sgfn merged 2 commits intomainfrom
sgfn/RTC-308-configurable-simulcast

Conversation

@sgfn
Copy link
Copy Markdown
Member

@sgfn sgfn commented Aug 10, 2023

@codecov
Copy link
Copy Markdown

codecov bot commented Aug 10, 2023

Codecov Report

Merging #68 (2271cdc) into main (e2fdff7) will decrease coverage by 0.43%.
The diff coverage is 84.37%.

@@            Coverage Diff             @@
##             main      #68      +/-   ##
==========================================
- Coverage   84.02%   83.59%   -0.43%     
==========================================
  Files          35       36       +1     
  Lines         507      512       +5     
==========================================
+ Hits          426      428       +2     
- Misses         81       84       +3     
Files Changed Coverage Δ
lib/jellyfish/peer.ex 85.71% <50.00%> (-14.29%) ⬇️
lib/jellyfish/peer/webrtc.ex 46.42% <80.00%> (+0.27%) ⬆️
lib/jellyfish/room.ex 83.03% <88.88%> (-0.90%) ⬇️
lib/jellyfish_web/api_spec/peer.ex 100.00% <100.00%> (ø)
lib/jellyfish_web/api_spec/peer/webrtc.ex 100.00% <100.00%> (ø)
.../jellyfish_web/controllers/component_controller.ex 100.00% <100.00%> (ø)
lib/jellyfish_web/controllers/peer_controller.ex 100.00% <100.00%> (ø)

Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update e2fdff7...2271cdc. Read the comment docs.

Comment thread lib/jellyfish/room.ex Outdated
@spec add_peer(id(), Peer.peer()) :: {:ok, Peer.t()} | {:error, :reached_peers_limit}
def add_peer(room_id, peer_type) do
GenServer.call(registry_id(room_id), {:add_peer, peer_type})
@spec add_peer(id(), Peer.peer(), map() | nil) ::
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.

I am wondering, whether the options shouldn't have a defined type instead of just map.
I'm not saying that we necessarily need this new type tho

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Could be, but I think I'll leave it as-is ¯_(ツ)_/¯

Comment thread lib/jellyfish/room.ex Outdated
GenServer.call(registry_id(room_id), {:add_peer, peer_type})
@spec add_peer(id(), Peer.peer(), map() | nil) ::
{:ok, Peer.t()} | :error | {:error, :reached_peers_limit}
def add_peer(room_id, peer_type, options) do
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.

Suggested change
def add_peer(room_id, peer_type, options) do
def add_peer(room_id, peer_type, options \\ %{}) do

Comment thread lib/jellyfish/room.ex Outdated
network_options: state.network_options,
video_codec: state.config.video_codec
},
if(is_nil(options), do: %{}, else: options)
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.

Suggested change
if(is_nil(options), do: %{}, else: options)
options

@sgfn sgfn force-pushed the sgfn/RTC-308-configurable-simulcast branch from e520ffc to 2271cdc Compare August 11, 2023 13:01
@sgfn sgfn merged commit a69d1fc into main Aug 11, 2023
@sgfn sgfn deleted the sgfn/RTC-308-configurable-simulcast branch August 11, 2023 13:07
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