Search code examples
amazon-web-serviceswebrtcrtpjanus-gatewayaws-elemental

Janus-Gateway RTP-Forward to send stream to AWS Elemental MediaLive


I'm using rtp_forward from the videoroom plugin in Janus-Gateway to stream WebRTC. My target pipeline looks like this:

WebRTC --> Janus-Gateway --> (RTP_Forward) MediaLive RTP_Push Input

I've achieved this:

WebRTC --> Janus-Gateway --> (RTP-Forward) Janus-Gateway [Streaming Plugin]

I've tried multiple rtp_forward requests, like:

register = {"request": "rtp_forward", "publisher_id": 8097546391494614, "room": 1234, "video_port": 5000, "video_ptype": 100, "host": "medialive_rtp_input", "secret": "adminpwd"}

But medialive just doesn't receive any stream. Anything I'm missing?


Solution

  • I'm not familiar with AWS MediaLive: initially I thought that, since most media servers like this expect RTMP and not RTP, that was the cause of the issue, but it looks like it does indeed support a plain RTP input mode. At this point this is very likely a codec issue: probably MediaLive doesn't support the codecs your browser is sending (opus and vp8?). Looking at the supported codecs, this seems to be the issue: https://docs.aws.amazon.com/medialive/latest/ug/inputs-supported-containers-and-codecs.html

    You can probably get video working if you use H.264 in the browser, but audio is always Opus and definitely not AAC, so you'll need an intermediate node to do transcoding.