Load testing with AWS

An instance of AWS with Openvidu initiated by the user is used as Sut and a parameterized test is executed whose values must be provided by the user (since they are AWS credentials). The test will start an Openvidu session with three users and check that they are all connected and receiving video and audio from the other users. Once checked, if everything is correct, it will start a second session with 3 other users.



docker run --rm -v ~/.elastest:/data -v /var/run/docker.sock:/var/run/docker.sock elastest/platform start

Recommended system specifications

ElasTest needs some minimum system specifications in order to run smoothly:

Processor 1GHz or faster
RAM 16GB
SWAP 4GB (if RAM < 16GB)
Hard Disk 30GB



Load testing with AWS

For execute this TJob it is necessary carry out the following steps:

Preparing Sut
  • Start OpenVidu Sut instance

It will be necessary to create the instance in CloudFormation with this file

  • Set OpenVidu Sut IP

Once created you must copy the Public DNS of the instance. In ElasTest, navigate to the Sut edit page and replace the value of Sut Ip field (Your OpenviduServer ip here) with the Public DNS.

  • Set AWS Private Key for OpenVidu

In th same page, replace the value of Private Key with your private key

  • Save the Sut configuration

Only do click to Save button.

Preparing TJob
  • Edit the TJob to set values to the predefined parameters

    • AWS_ACCESS_KEY_ID
    • AWS_SECRET_ACCESS_KEY
    • AWS_KEY_NAME
    • AWS_SSH_PRIVATE_KEY

      The ssh private key must have a specific format: the line breaks must be replaced by the literal character string \r\n. Example:

      -----BEGIN RSA PRIVATE KEY-----\r\naaaaaaaaaaaaaaaaaaaaaaa\r\nbbbbbbbbbbbbbbbbbbbbbbbb\r\ncccccccccccccccccccccc\r\n-----END RSA PRIVATE KEY-----
      
    • AWS_SECURITY_GROUPS

      Security groups shall be established in the following format: ["GROUP_NAME1","GROUP_NAME2",...]. If only one group is to be established, it must have the same format: ["GROUP_NAME"]

    • AWS_TAG_SPECIFICATIONS

      Tag specifications must have the following format:

      [ { "resourceType":"instance", "tags":[ {"key":"KEY", "value":"VALUE"} ] } ]
      

      You can use the following if you want:

      [ { "resourceType":"instance", "tags":[ {"key":"Type", "value":"OpenViduLoadTest"} ] } ]
      
  • Activate WebRTC stats (Optional)

If you want to receive WebRTC statistics from browsers, you should check the webRtcStats checkbox within EUS at Test Support Services.

  • Save the TJob

Only do click to Save button.

Run TJob

Just run the TJob and enjoy!

Once the execution is finished, the result will be shown: