|
| 1 | +<div class="range range-xs-left"> |
| 2 | +<div class="cell-xs-10 cell-lg-6 text-md-left inset-md-right-80 cell-lg-push-1 offset-top-50 offset-lg-top-0"> |
| 3 | +<h2 id="content" class="h1">Load testing with AWS</h2> |
| 4 | +<div class="offset-top-30 offset-md-top-30"> |
| 5 | +</div> |
| 6 | +</div> |
| 7 | +</div> |
| 8 | + |
| 9 | +<p>An instance of AWS with <a href="https://openvidu.io" target="_blank">Openvidu</a> 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.</p> |
| 10 | + |
| 11 | +<div class="run-div"> |
| 12 | + <hr /> |
| 13 | + <div class="row row-run-demo no-margin"> |
| 14 | + <div class="col col-md-2 col-sm-4 col-xs-12"> |
| 15 | + <img src="/docs/images/logo-dark.png" style="border: none; padding-top: 14px;" alt="" /> |
| 16 | + </div> |
| 17 | + <div class="col col-md-10 col-sm-8 col-xs-12"> |
| 18 | + <a href="http://live.elastest.io/#/projects/9" target="_blank" class="btn btn-xs btn-primary" title="Try it now">Take a look</a> |
| 19 | + </div> |
| 20 | + </div> |
| 21 | + <hr /> |
| 22 | + <div class="row row-run-demo no-margin"> |
| 23 | + <div class="col col-md-2 col-sm-4 col-xs-12"><img src="/docs/images/docker.png" style="border: none;" alt="" /></div> |
| 24 | + <div class="col col-md-10 col-sm-8 col-xs-12"> |
| 25 | + <div class="row no-margin"> |
| 26 | + <div class="col-lg-1 col-md-2 col-sm-2 no-padding"> |
| 27 | + <button id="btn-copy-2" class="btn btn-xs btn-primary" data-toggle="tooltip" data-placement="button" |
| 28 | + title="Copy to Clipboard">Copy</button> |
| 29 | + </div> |
| 30 | + <div class="col-lg-11 col-md-10 col-sm-10 no-padding"> |
| 31 | + <code id="code-2">docker run --rm -v ~/.elastest:/data -v /var/run/docker.sock:/var/run/docker.sock elastest/platform start</code> |
| 32 | + </div> |
| 33 | + <br/> |
| 34 | + <div class="row no-margin docker-info-div"> |
| 35 | + <div class="col-lg-1 col-md-2 col-sm-2 no-padding docker-info-icon"> |
| 36 | + <i class="fas fa-info-circle"></i> |
| 37 | + </div> |
| 38 | + <div class="col-lg-11 col-md-10 col-sm-10 no-padding"> |
| 39 | + <h4 class="small-subtitle">Recommended system specifications</h4> |
| 40 | + <p>ElasTest needs some minimum system specifications in order to run smoothly:</p> |
| 41 | + <table> |
| 42 | + <tr> |
| 43 | + <td>Processor</td> |
| 44 | + <td>1GHz or faster</td> |
| 45 | + </tr> |
| 46 | + <tr> |
| 47 | + <td>RAM</td> |
| 48 | + <td>16GB</td> |
| 49 | + </tr> |
| 50 | + <tr> |
| 51 | + <td>SWAP</td> |
| 52 | + <td>4GB (if RAM < 16GB)</td> |
| 53 | + </tr> |
| 54 | + <tr> |
| 55 | + <td>Hard Disk</td> |
| 56 | + <td>30GB</td> |
| 57 | + </tr> |
| 58 | + </table> |
| 59 | + </div> |
| 60 | + </div> |
| 61 | + </div> |
| 62 | + </div> |
| 63 | + </div> |
| 64 | + <hr /> |
| 65 | + <div class="row row-run-demo no-margin"> |
| 66 | + <div class="col col-md-2 col-sm-4 col-xs-12"><img src="/docs/images/amazonAWS.png" style="border: none;" alt="" /></div> |
| 67 | + <div class="col col-md-10 col-sm-8 col-xs-12"> |
| 68 | + <a href="/docs/deploying/aws/" class="btn btn-xs btn-primary" title="Deploy on Amazon">Deploy on Amazon</a> |
| 69 | + </div> |
| 70 | + </div> |
| 71 | + <hr /> |
| 72 | + <div class="row row-run-demo no-margin"> |
| 73 | + <div class="col col-md-2 col-sm-4 col-xs-12"><img src="/docs/images/kubernetes.png" style="border: none; max-height: 124px; padding-top: 8px;" alt="" /></div> |
| 74 | + <div class="col col-md-10 col-sm-8 col-xs-12"> |
| 75 | + <a href="/docs/deploying/kubernetes" class="btn btn-xs btn-primary" data-toggle="tooltip" data-placement="button" |
| 76 | + title="Deploy on Kubernetes">Deploy on Kubernetes</a> |
| 77 | + </div> |
| 78 | + </div> |
| 79 | + <hr /> |
| 80 | +</div> |
| 81 | + |
| 82 | +<h5 class="small-subtitle">Load testing with AWS</h5> |
| 83 | + |
| 84 | +For **execute this TJob** it is necessary carry out the **following steps**: |
| 85 | + |
| 86 | +<h6>Preparing Sut</h6> |
| 87 | + |
| 88 | +- **Start OpenVidu Sut instance** |
| 89 | + |
| 90 | +It will be necessary to create the instance in CloudFormation with <a href="https://github.com/elastest/demo-projects/blob/master/aws/junit5-qe-openvidu/src/test/resources/openvidu-sut.yml" target="_blank">this file</a> |
| 91 | + |
| 92 | +- **Set OpenVidu Sut IP** |
| 93 | + |
| 94 | +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. |
| 95 | + |
| 96 | +<div class="docs-gallery inline-block"> |
| 97 | + <a data-fancybox="gallery-1" href="/docs/demos/images/load-testing-with-aws/sutip.png"><img class="img-responsive img-wellcome" src="/docs/demos/images/load-testing-with-aws/sutip.png"/></a> |
| 98 | +</div> |
| 99 | + |
| 100 | +- **Set AWS Private Key for OpenVidu** |
| 101 | + |
| 102 | +In th same page, replace the value of **Private Key** with your private key |
| 103 | + |
| 104 | +- **Save the Sut configuration** |
| 105 | + |
| 106 | +Only do click to Save button. |
| 107 | + |
| 108 | +<h6>Preparing TJob</h6> |
| 109 | + |
| 110 | +- **Edit the TJob to set values to the predefined parameters** |
| 111 | + |
| 112 | + - AWS_ACCESS_KEY_ID |
| 113 | + - AWS_SECRET_ACCESS_KEY |
| 114 | + - AWS_KEY_NAME |
| 115 | + - AWS_SSH_PRIVATE_KEY |
| 116 | + |
| 117 | + The ssh private key must have a specific format: the line breaks must be replaced by the literal character string **`\r\n`**. Example: |
| 118 | + |
| 119 | + -----BEGIN RSA PRIVATE KEY-----\r\naaaaaaaaaaaaaaaaaaaaaaa\r\nbbbbbbbbbbbbbbbbbbbbbbbb\r\ncccccccccccccccccccccc\r\n-----END RSA PRIVATE KEY----- |
| 120 | + |
| 121 | + - AWS_SECURITY_GROUPS |
| 122 | + |
| 123 | + Security groups shall be established in the following format: **`["GROUP1","GROUP2",...]`**. If only one group is to be established, it must have the same format: **`["GROUP"]`** |
| 124 | + |
| 125 | + <p></p> |
| 126 | + |
| 127 | + - AWS_TAG_SPECIFICATIONS |
| 128 | + |
| 129 | + Tag specifications must have the following format: |
| 130 | + |
| 131 | + [ { "resourceType":"instance", "tags":[ {"key":"KEY", "value":"VALUE"} ] } ] |
| 132 | + |
| 133 | + You can use the following if you want: |
| 134 | + |
| 135 | + [ { "resourceType":"instance", "tags":[ {"key":"Type", "value":"OpenViduLoadTest"} ] } ] |
| 136 | + |
| 137 | +* **Activate WebRTC stats (Optional)** |
| 138 | + |
| 139 | +If you want to receive **WebRTC statistics** from browsers, you should check the **`webRtcStats`** checkbox within **EUS** at **Test Support Services**. |
| 140 | + |
| 141 | +<div class="docs-gallery inline-block"> |
| 142 | + <a data-fancybox="gallery-1" href="/docs/demos/images/load-testing-with-aws/webrtcstats.png"><img class="img-responsive img-wellcome" src="/docs/demos/images/load-testing-with-aws/webrtcstats.png"/></a> |
| 143 | +</div> |
| 144 | + |
| 145 | +- **Save the TJob** |
| 146 | + |
| 147 | +Only do click to Save button. |
| 148 | + |
| 149 | +<h6>Run TJob</h6> |
| 150 | + |
| 151 | +Just run the TJob and enjoy! |
| 152 | + |
| 153 | +Once the execution is finished, the result will be shown: |
| 154 | + |
| 155 | +<div class="docs-gallery inline-block"> |
| 156 | + <a data-fancybox="gallery-1" href="/docs/demos/images/load-testing-with-aws/result.png"><img class="img-responsive img-wellcome" src="/docs/demos/images/load-testing-with-aws/result.png"/></a> |
| 157 | +</div> |
0 commit comments