Ensuring Availability of a Server-Side Rendered React Application: A Case Study

Loading...
Thumbnail Image
Journal Title
Journal ISSN
Volume Title
Perustieteiden korkeakoulu | Master's thesis
Date
2019
Department
Major/Subject
Software and Service Engineering
Mcode
SCI3043
Degree programme
Master’s Programme in Computer, Communication and Information Sciences
Language
en
Pages
64 + 4
Series
Abstract
Service availability is an essential factor for service providers affecting customer satisfaction and the business of the service providers. This thesis presents methods to ensure availability of the service under high load as a case study for Iltalehti, one of the two largest online newspapers in Finland. The main techniques to ensure availability found in the literature review were the use of load balancing, content delivery networks (CDNs), auto-scaling and improving the performance of server-side rendered React application. Load balancing ensures that all server instances are not affected if one availability zone suffers from failures such as power outage or hardware fails. Content delivery networks lessen the load on the server by caching popular content and therefore improve server performance. To improve the server performance action research was used where each action research cycle aimed to improve the performance. During each cycle, changes were evaluated by stress testing the test server. The results show that server performance was increased by about a hundred times. Some of the performance increase was achieved by adding more computing power to servers. However, the technical solutions that improved the performance most were client-side rendering fallback, upgrades for Node.js and React versions and reductions of DOM content rendered on the server. Especially, client-side rendering fallback provided great results by improving server performance by slightly over eight times.

Palvelun saatavuus on tärkeä tekijä palveluntarjoajille vaikuttaen asiakkaiden tyytyväisyyteen ja palveluntarjoajien liiketoimintaan. Tämä diplomityö esittelee tapoja varmistaa palvelun saatavuus korkean kuormituksen alla. Työ on tapaustutkimus Iltalehdelle, joka on toinen Suomen kahdesta suurimmasta Internetissä toimivasta uutispalveluista. Kirjallisuuskatsauksen aikana löydetyt tärkeimmät tekniikat saatavuuden varmistamiseen ovat kuormituksen tasaaminen, sisällönjakeluverkot, automaattinen skaalaus ja palvelimella renderöidyn React-sovelluksen suorituskyvyn parantaminen. Kuormituksen tasaus varmistaa, että ainakin osa palvelininstansseista toimii, vaikka yksi saatavuusalue kärsisi ongelmista, kuten esimerkiksi sähkökatkosta tai laitteistoviasta. Sisällönjakeluverkot vähentävät kuormaa palvelimella ja parantavat palvelinten suorituskykyä tallentamalla suositut sisällöt muistiinsa ja jakamalla niitä suoraan muististaan. Työssä tehtiin toimintatutkimusta ja jokaisen toimintatutkimussyklin tarkoitus oli parantaa palvelun suorituskykyä. Jokaisen syklin aikana tehdyt muutokset evaluoitiin kuormitustestaamalla testipalvelinta. Työn tulokset osoittavat, että palvelun suorituskyky parani lähes satakertaisesti. Osa suorituskyvyn parannuksesta tuli palvelinten laskentatehon lisäyksestä. Tekniset ratkaisut, jotka paransivat suorituskykyä eniten, olivat selainrenderöintivarasuunnitelma, päivitykset Node.js ja React-versioihin sekä palvelimella renderöitävän sisällön vähentäminen. Erityisesti selainrenderöintivarasuunnitelma toi hyvät tulokset parantamalla suorituskykyä kahdeksan kertaisesti.
Description
Supervisor
Lassenius, Casper
Thesis advisor
Kauppi, Ville
Keywords
availability, action research, stress testing, server-side rendering, Node.js, React
Citation