You can't build instagram posted on 19 June 2024

One of the common design interview questions is to design instagram/twitter/youtube/etc. While I think these are valid interview questions that can foster interesting discussions that allow the interviewer to gather interesting signals about the candidate, you shouldn’t assume that you can actually build such systems.

I see many training/courses/lessons claiming to teach you how to code and how to build these large websites – these are quite misleading. You will learn how to build a blog, a mini social network, but you won’t have to chance to grasp:

  • The technological challenges in scaling a large system
  • The product complexity of scaling your product

To give more colors on the technical challenges, the courses may mention scaling up sharding/replicating a database, but in general there are teams that support such operations because doing so without down-time is not as trivial as it may seem. This is especially true if you are migrating from one system to another. You also have other scalability issues that are often ignored – to give just a few simple examples:

  • Hot keys – e.g. you can have one key that’s heavily more used
  • Irregular traffic patterns – e.g. traffic is not uniform on a daily basis (e.g. different time zones have different amounts of traffic) but also not in general (e.g. if you run a social network, you likely get more traffic during the holidays than during regular week days). Just throwing more machine isn’t always a viable option as it may result in non trivial operational costs
  • Consistency – e.g. how do you handle inconsistent data. Many data stores provide some guarantees, but these sometimes do not hold (see all the articles on and you still have to deal with corrupted/inconsistent data

To give more colors on the product complexity, you can just look at privacy for kids – there are different definitions of kids per country and even from within the same country. These regulations also have different impacts – e.g. you can’t show ads in Quebec for kids under 13, but can do so in the rest of Canada with some limitations. All these product complexity requires you to architect your system in better ways than just piling if conditions – otherwise your code is unmaintainable and likely incorrect. The same goes for many domains, e.g. as soon as you want to handle international payments, you likely need a full team to support these payments operations (in addition to the internationalization of your app)

Basically these systems are never built to scale from scratch by just a few people, they are the results of many iterations, rewrites and changes specific to their scalability/product issues. Every single aspect of them can require a whole team because it’s that complex – not because of paperwork.

Building and operating a large scale system is like riding a bike – you can read about it but you’ll never learn to bike only from reading books.

LinkedIn post

The unhealthy grind posted on 18 June 2024

This is a slightly different post than usual but I think equally important as I write a lot about growing as an engineer. I personally enjoy growing mostly because I want to learn new things, build systems and in general not get bored – the extra income is nice tough.

You may want to grow for different and good reasons, we are all different people living in different environments. For example, I think it’s perfectly fine to want to get promoted for money – the more money you have, the more interesting things you can do outside of work. Not every software engineer can also afford the lifestyle of those senior folks in the bay area too.

With that being said, I do think there are unhealthy reasons to grow – e.g. when your goal is just to crush your peers and to be better than them (in regards to income, title etc.). The main issues being that:

  • You’ll never be satisfied – there is always more money to be made and higher titles to get
  • You will never be happy – there will always be someone who has more money, who grew faster than you or who is above you on the corp ladder. The best illustration of this point is probably the Blind social network where people care so much about compensation that it has become a toxic trait
  • Your drive is actually going to hurt your growth. If your goal is to be better than your peers, you will likely end up being selfish and others won’t enjoy working with you. In the tech industry, promotions are often based on peer feedback, and no one will want to work with you or support your promotion
  • You will focus on practical gaps to get to the next level without being able to take a step back and actually grow. You’ll execute what you’re told you’re lacking but will struggle to understand why and sustain such performance

Engineers want to follow their kind and good leadership rather than their selfish executives. This network again is what will help you grow beyond senior engineer levels.

LinkedIn post

Don't worry about what you don't know posted on 17 June 2024

When joining a company, there will be things you won’t know, and that’s OK. You don’t need to study their stack ahead of time in the hope of being efficient from day 1. Companies are aware that engineers need ramp up time and will give you time to learn everything you need to perform your job.

This is even true if you switch teams inside a large company since you won’t have the technical/product historical context to be able to always do the right trade offs.

I remember during my tenure at Google, one of the new grads in my team didn’t know what a binary is – they weren’t aware we were compiling C++ code to a binary before releasing/executing it. When they asked about it, I didn’t judge them or show a surprised face, I just told them what it was and how things were working. This was the right thing to do:

  • It’s not necessarily common/expected knowledge – if you just used python/ruby/javascript, you never compile code.
  • Their gap in knowledge doesn’t reflect a lack of potential or desire to grow. In the case I mentioned above, I’m pretty proud about that person’s growth – they are currently a senior engineer and on their path to staff!

So don’t sweat about what you don’t know, they are just small details. Surround yourself with a good manager, a good mentor and good peers – from there just learn along the way. We all started from somewhere, and we all have gaps in our knowledge – I personally still haven’t properly learn how to escape my code in bash (I just tweak it until it works 😅)

If you happen to be a seasoned engineer, don’t judge people on what they don’t know – just help them grow. It’s the right and nice thing to do.

LinkedIn post

Leading by example posted on 16 June 2024

Today is father’s day so I thought I would write a personal (and hopefully interesting) story about my dad.

My dad was working when I was a kid but he wasn’t the main breadwinner – my mom was. She was also the one who used to manage all the finances. My dad would however spend more time taking care of me and my siblings (e.g. there was a time when he was working night shifts for us) and doing chores at home – he’s the one doing the dishes, cleaning the floor etc.

The interesting thing from there is that I always assumed that a father (or a husband in general) doing chores at home was normal. I never questioned whether it would be my role to do such chores, it just felt normal. It’s only until fairly late (in my late twenties) that I learn that in some/many households, the woman does everything.

This is where people just follow what they see – you can simply lead by example. For example, if you want your team to fix tech debt, the best way is for you/the leads to fix tech debt. The same is true at a larger scale: if you want your whole engineering organization to do , gather a small group of people passionate about the problem that would be solved by and do the work with them.

Being able to communicate well about such efforts helps but at the core, doing the work and celebrating it is the best way to promote these efforts. The easiest way to lead is by just doing the right thing.

LinkedIn post