A social game using serverless architecture on AWS cloud

A social game using serverless architecture on AWS cloud

GuessMyLife is a social guessing game, developed for an award-winning Swedish author. It was designed to entice users to register and spend time on the website. It was developed as a cloud-native distributed system on a serverless architecture, using Go, AWS Lambda, AWS API Gateway, AWS SES, and AWS SNS among others.

The project started as an abstract idea by the client involving a game to engage users online. The main aim of the application was to engage the user as soon as they landed on the website, and keep them motivated to stay engaged.

The client, Stefan Ekberg, Swedish author and screenwriter, with writing experience of over two-and-a-half decades has written multiple books on marketing, management, and business.

LiteBreeze’s team of software developers and design experts collaborated with the client to improve upon the original idea. The client being open to new ideas, made it easy for us to share our inputs and insights.

Keeping the game simple and instantly rewarding the user with results were key inputs we provided when designing the game. This aligned very well with the overall aim of the application, and was both approved and appreciated by the client.

This social game involves guessing people’s traits through their photographs. The photographs are displayed as a scrollable set of horizontal cards, with each card containing a photograph and a question.

The question is for the user to guess traits like age, nationality, education etc. After a few guesses, a card prompting users to sign up is displayed. Upon registration, users can submit their own photographs, which will then be added as cards to the game.

The application generates weekly reports with statistics of site visitor engagement details. Facebook and Twitter APIs are integrated to enable users to share these reports on social media platforms. This will boost return rates and also attract new users to the application.

The application has been developed with multi-language support built in. Currently, it is available in both Swedish and English. In the future, other languages can be added, with minimum code changes involved.

What did we learn?

This was one of the first few projects developed by LiteBreeze using Golang. The dedicated team of software programmers was able to confidently develop a secure and robust application. We now have a full-fledged team of Go developers  – or Gophers, as they’re called.

Deploying custom applications on a serverless architecture was a relatively new concept for us. We did extensive research before starting the project to identify and avoid common pitfalls of using the architecture.

The serverless architecture significantly decreases the cost of hosting the application, thus it is more cost-effective for the client.

The AWS Lambda service is charged as per the number of requests processed. In the initial stages of app launch, when the traffic is expected to be low, the costs would be minimal.

If we had gone for a traditional architecture the client would have had to pay for the provisioned resources, irrespective of the traffic or usage.

Technical information

  • Golang – It is a perfect language when the need is to combine safety, concurrency, and simplicity of the code. It is fast when compared to languages like PHP, and its efficient concurrency management would effectively help with a smooth user experience even when catering to heavy traffic on site.
  • Serverless architecture – One of the challenges we faced was to design the system to handle variable traffic, from a few hundred to many thousand requests per second. Our solution was to deploy the system on a serverless architecture, which would auto-scale according to the load. This was implemented using the serverless framework, using the following AWS services: Lambda, Simple Notification System, and API Gateway.
  • The Amazon Cognito service – This was integrated to handle user sign-up and login. The AWS S3 service was used to ensure that the application assets were stored in a safe, secure and highly available manner.
  • The Amazon Simple Email Service – This was set up to handle email sending, and the DNS management was handled using Amazon Route 53 service.

The database was hosted on Amazon RDS MySQL instances, with multi-AZ enabled for high availability and failover support.

Next priorities

We look forward to developing a mobile app version of the application, as we believe the game would be more engaging as a mobile app. The push notifications in mobile apps would help with improving user engagement and getting users back into the system on a more frequent basis.

A social game using serverless architecture on AWS cloud
Working with LiteBreeze was wonderful. I had a few concerns outsourcing my project to a team in India - different region, culture, etc. Their team put all my concerns to rest once the project started. They easily understood my thought processes and goals. Their technical competence and valuable inputs improved my ideas and the project. They are more of a responsible development partner rather than just a software team. I happily recommend LiteBreeze! - Stefan Ekberg (Stockholm, Sweden)
Team of developers who worked on this project: Jithin, Priyesh, Sahal, Bijil, Vince C