Versions Compared

Key

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

Table of Contents

Overview

WebRTC stream pulling from another WCS server may be useful to load testing according to the following test scenario:

  1. Stream is published on server 1.
  2. Server 2 makes a specified number of Websocket connections (100 for example), as a standalone browser client.
  3. Server 2 pulls a specified number of copies of stream published on server 1, as a viewer.

Testing

1. For the test we use:

...

3. Install ACAO extension, allow Cross-Origin-Resource-Sharing

4. Enter server name wcs5-us.flashphoner.com and press 'Add node'. The server will be a subscriber which pulls streams. Then, add server demoserver demo.flashphoner.com which will be a stream source to test.

...

5. Open Two Way Streaming application https://demo.flashphoner.com/client2/examples/demo/streaming/two_way_streaming/two_way_streaming.html, then publish the stream from web camera

6. Select wcs5Select wcs5-eu.flashphoner.com in Console application, press 'Pull streams' button, set the test parameters:

  • Choose node - choose demochoose demo.flashphoner.com server to test
  • Local stream name, Remote stream name - set the stream published name
  • Qty - set the viewers quantity (100 for example)

...

7. Press 'Pull' button. The test begins.

8. Select demoSelect demo.flashphoner.com server. The page displays a list of media sessions in which the published stream is played. Current server load information is displayed at top right corner.

CDN Edge server load testing

CDN Edge server load testing is performed by the following scenario:

  1. Streams are published on Origin server.
  2. Testing server makes a specified number of Websocket connections (100 for example) to Edge server, as a standalone browser client.
  3. Testing server pulls a specified number of copies of all the streams available to Edge server, as a viewer.

Quick manual on Edge server testing

1. For test we use:

2. Deploy CDN with the following server roles:

  • test1 - Origin
  • test2 - Edge

Add the foolowing parameter to Edge server settings

Code Block
themeRDark
wcs_activity_timer_timeout=86400000

3. Open Console application over HTTP (not HTTPS!) http://demo.flashphoner.com:9091/client2/examples/demo/streaming/console/console.html

...

4. Allow Cross-Origin-Resource-Sharing

5. Enter Edge server name test2name test2.flashphoner.com, press 'Add node'. This server will be tested. Add demoAdd demo.flashphoner.com server similarly, this server will be a subscriber which pulls streams.

...

6. Open Two Way Streaming application, publish stream from web camera

7. Selet demoSelet demo.flashphoner.com server in Console application, press 'Stress play stream', set the following test parameters:

  • Choose node - select server for testing test2testing test2.flashphoner.com
  • Choose test mode - select Random
  • CDN - set the checkbox
  • Max streams - set the number of viewers (100 for example)

...

7. Press 'Start'. The test begins.

RTMP pulling test

Since build 5.2.767 it is possible to pull streams via RTMP while testing. This can be enabled using the following parameter on testing server

Code Block
themeRDark
rtmp_pull_allow_to_reuse_uri=true

In test configuration window, choose "Proto pull: RTMP" 

Image Added

The test itself works like WebRTC test

Tuning recommendations

If the load test was failed, it is recommended to change the following setver settings.

...

Code Block
languagebash
themeRDark
-Xmx16g -Xms16g

Known issues

1. By default, no more than 1000 streams are pulled

...