The third round of registration in Malaysia for the AstraZeneca vaccine closed leaving many (including myself and loved ones) in frustration because the system was (again) unable to handle the load — “frustration” a bit understated here given how Malaysia is now leading the world in Covid cases per million.

To cope, I can only try to diagnose where it went wrong.

Designing for traffic spikes is a challenge

The litmus test for application design is dealing with traffic spikes— especially for transactional use-cases. …


In part 1 I wrote about the challenge of minimizing costs for content websites, in this piece I focus on maximizing performance.

Frontend development is a curious beast. Much has been said of the proliferation of Javascript libraries and frameworks — my favourite quip (I can’t remember the source) being that if you pick a word from the dictionary and add .js to it, a Javascript package of that name probably exists.

The mainstream solutions I’ve seen on the frontend coalesce on the following, to solve what’s seen as the main problems:

  • Interactive components, state management, and routing: A framework…


When some friends approached me recently to build a new site, I thought it would be a good chance to try out some development techniques that I had been itching to validate. After working off and on over the past couple months and in overdrive over the new year holidays, Periuk.my was released and it’s a site I’m really proud of!

Two things I wanted to focus on were:

  1. Creating the cheapest, but most scalable, site possible.
  2. Creating the most performant site possible.

Part 1: Pay-as-you go Wordpress with headless mode and static site generation

If you’re like me, you remember the days before VMs and containers. Wordpress sites were something you…


Gitlab CE is one of the best options available today for self-hosting Git, and one of its best features is Gitlab CI, its continuous integration service.

Gitlab CI works off decentralized runners. Your pipelines don’t run on your Gitlab instance itself, but on Gitlab runners that can be hosted in the cloud or even on laptops.

image credit: gitlab.com

On top of that, Gitlab runners can have different execution strategies, the most popular being:

  • shell: The simplest kind, which runs jobs directly on the machine.
  • docker: Runs jobs in containers.
  • docker-machine: Like docker runners, but can spin up runner instances on-the-fly (this requires…


Instead of just for loops

Frontend Malaysia recently highlighted a post titled You don’t need Array.reduce() which attracted some minor controversy. The author tries to argue that Array.reduce() is always better simplified using simple for loops.

In the example he cited, a dataset of trips needed to be summed up, with the result being the total trip distance by type:

const trips = [
{type: 'car', dist: 42},
{type: 'foot', dist: 3},
{type: 'flight', dist: 212},
{type: 'car', dist: 90},
{type: 'foot', dist: 7}
]

Using Array.reduce() solves the problem like this:

const distanceByType = trips.reduce((currState, trip) => {
const { type…

Behind the scenes at carpool.pulangmengundi.com

In the run-up to the 14th General Elections, I was part of pulangmengundi.com, an initiative created for Malaysians helping Malaysians home to vote. It was an incredible experience, and I thought I’d share what I learnt, from a tech perspective (although as you’ll see, the non-tech parts were even more important!).

1. Ship fast, distribute the load, and seek out partners

The news spread quickly on Tuesday evening (April 10th) that GE14 was going to take place on a weekday — an obvious voter suppression tactic. By dinnertime the hashtags #undirabu and #pulangmengundi were trending in Twitterjaya, and people were already offering travel subsidies and organizing carpools.


This post was written for the Laravel Blog Contest , see the entries here and vote if you find this interesting!

For small projects, pretty much anything will do to host Laravel. For larger organizations or complex apps spanning multiple services, these problems become common:

  • How do you provision clusters of apps dynamically and securely, and in a reproducible, disposable way?
  • How do you ensure the runtime environment of your apps are both reproducible yet flexible?
  • What is the best way to avoid having to run npm install and composer install in production?

The answer is inevitably Kubernetes.

Openshift from…


Part 4: https://medium.com/@timothyteoh/new-zealand-pt-4-little-paradise-lodge-f802ea297fe6

We chose Wanaka for tandem skydiving instead of Queenstown because we’d heard the view in Wanaka was better.

There were a few different packages: a 12k-ft or 15k-ft fall, and the choice of videoing the jump with a handheld camera from your tandem jumper, or from a dedicated videographer who would do the jump with you.

We all decided on a 12k-ft fall with a videographer — that was really expensive but we felt recording the jump for posterity would be important.

Mimi didn’t want to do the jump with us at first but she eventually got…


Part 3: https://medium.com/@timothyteoh/new-zealand-pt-2-arriving-in-nz-8b51429a3061

When Karen and I started looking for our accommodation in NZ we knew that it was quite important as we would be spending 3 days there and it would be the main “base” for our activities.

She found a place called “Little Paradise Lodge” in Tripadvisor that had rave reviews but didn’t seem like the typical hostel or apartment lodgings.

First off, this was the map there as shown on their site. It basically said “20 minutes from Queenstown to Glenorchy”. That was it.


Part 1: https://medium.com/@timothyteoh/new-zealand-pt-1-sydney-stopover-b20782dc0310

We headed to the airport in the morning and had breakfast there. Yup Subway is a lot more generous with their helpings outside Malaysia!

I also made it a point to have bacon with every meal I had on this trip. It usually costs AUD/NZD 1 which is relatively cheap.

Timothy Teoh

Architect @ REA Group Asia. Passionate about software and cloud architecture.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store