Technical Environment
Overview
This section details the technical environment for YaMa. It will detail the tools used to complete the project, why those specific tools were chosen, and how the team came to that conclusion.
Source Control - GitHub
For source control, the option was going to be straightforward. Within the development team we all had high levels of experience with GitHub. GitHub is the leader for source control solutions with a wide variety of features that also will increase developer productivity. One key extra feature is GitHub actions.
Backend Hosting/Infrastructure - AWS
For the back-end functions used by YAMA we chose to utilise Amazon Web Services, or AWS.
AWS allows the easy provisioning of services based on application load without the need for procurement, configuration or maintenance of the underlying hardware or operating systems.
Within the AWS ecosystem, we are utilising Amazon Gateway and Lambda functions.
The gateway allows us to rapidly built API endpoints that can be accessed directly by the front-end, while the Lambda functions called by the gateway offer optimised containers that spin up only when required. This provides efficiency, scalability, and cost benefits. Each Lambda function is launched only when required and terminates when complete, limiting service charges, while many Lambda functions can be launched simultaneously to handle increased load.
The Lambda functions provide secure access to all the database CRUD operations that will be required.
Database - MongoDB
The database system we chose to store all our data, is MongoDB.
MongoDB provides a fast NO-SQL database that stores information as collections of documents in a highly optimised binary JSON format.
It was estimated that MongoDB would offer efficiencies for accessing YAMA chat messages, as NO-SQL databases such as Mongo are great at streaming data that does not require complex relationships or joins. The lack of an SQL command interpreter that can be utilised in a relational SQL database means that data can be processed more quickly, while server load is significantly reduced.
With the free-tier offered by MongoDB’s ATLAS, we are able to manage the database, view all the data, and perform queries online via any browser. This allows the team to easily collaborate using the same data store and test query results that will be integrated into the application.
Frontend Framework - Svelte
The front-end of the YAMA chat app has been developed as a reactive single page application using Svelte with components adhering to Google’s Material Design specification.
Svelte offers similar benefits of other reactive JavaScript frameworks such as React or Vue, where changes in state or value of a variable can be kept synchronised with the DOM with little effort by the developer. However Svelte has one key difference, it is a compiler rather than a traditional bundled framework.
With Svelte, any code that is written to take advantage of the enhanced reactive capabilities offered is compiled to native JavaScript. This way no framework needs to be loaded by the client. This reduces the size of the JavaScript payload, as well as increasing speed by running the code natively in the browser rather than requiring commands to be first interpreted by a framework.
CI/CD - GitHub Actions and Vercel
GitHub Actions
GitHub actions allow us to create automated processes that trigger based on changes to our code repository. We use GitHub actions for a multitude of purposes including running automated tests once our code is uploaded. As well as automatically deploying the latest development or productive branch to Vercel, they are highly dynamic and can support multiple helpful use cases.
Vercel
For deploying YAMA to the internet, we needed to ensure that we found a deployment platform that filled three key criteria. Firstly, deploying development builds quickly. As we are a small dev team that are geographically distant it is important that we are keeping up to date with the project. Secondly, low effort. Due to our small manpower, it is important that we can setup the tool quickly. Finally, cost, as the goal of this project is to keep costs to a minimum, this is arguable the most important factor. Software that we found that fits all three requirements perfectly is Vercel.