Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagejs
themeRDark
rtmp://myrtmpserver.com:1935/liveapp_name/stream?param1user=test1user1&param2pass=test2

...

pass1

or, if a stream supposed to be published to a specified instance of RTMP server application

Code Block
languagebashjs
themeRDark
rtmp_transponder_full_url=true

When REST query  /push/startup is sent to WCS server or createstream() method is called with parametes

Code Block
languagejs
themeRDark
{
"streamName": "rtmp_test",
"rtmpUrl": "rtmp://myrtmpserver.com:1935/live/stream?param1=test1&param2=test2"
}

RTMP-server will receive the request on connection establishing to republish stream as follows

Code Block
languagejs
themeRDark
onConnect: AMFDataList: [0] connect, [1] 1.0, [2] object
{Obj[]: app: "live/stream?param1=test1&param2=test2", type: "nonprivate", flashVer: "FMLE/3.0 (compatible; Lavf54.59.106)", swfUrl: "://myrtmpserver.com:1935/app_name/app_instance/?user=user1&pass=pass1

Where

  • myrtmpserver.com is the RTMP server name
  • app_name is the application on the RTMP server name
  • app_instance is the instance name of the RTMP server application

Stream name is set in REST query /push/startup parameter 'streamName' or in corresponding stream creation option.

This is the example on RTMP connection establishing with query parameters passing

Image Added

Stream name passing in sever URL

In some cases, a stream publishing name shoukd be passed in the server URL. To do this, the following option must be set in flashphoner.properties file

Code Block
languagebash
themeRDark
rtmp_transponder_full_url=true

Then, the URL to publish should be set in REST query /push/startup 'rtmpUrl' parameter or in corresponding stream creation option like this:

Code Block
languagejs
themeRDark
rtmp://myrtmpserver.com:1935/live/stream?param1=test1&param2=test2", tcUrl: "app_name/stream_name

or, to publish to another application instance

Code Block
languagejs
themeRDark
rtmp://myrtmpserver.com:1935/live/stream?param1=test1&param2=test2"}/app_name/app_instance/stream_name

In this case, 'streamName' parameter or REST query /push/startup or corresponding stream creation option is ignored.

Automatic republishing to a specified RTMP server

WCS server can automatically republish all the streams published to a specified RTMP server. To activate this feature, set the next options in flashphoner.properties file:

...