Resources

Along the years I’ve read many articles, tutorials, and some books (I’ve watched some videos, too, but I prefer reading). Also, I’ve took a look on some tools to get new ideas. It really helped me in my carrier.

Before doing something, you should at least have an idea of how to do it, if not a plan, and this can come from studying.

Make a little effort to read something (even source code) at least a few times a week.

Planning to read someday: Designing Data-Intensive Applications

Isolation

Big fan of isolation here, from code libraries to apps environments.

Code should be organized in reusable and extensible units (package, library, component), isolated from other units, the interaction between them being made on APIs well described by a contract. Also, they should be easily extensible.

Apps should live in isolated environments. I’m talking about servers, virtual machines, and containers. If different services run on the same machine, you can isolate them using containers. As such, you can safely and independently deploy, make upgrades, balance traffic, move over different machines.
If you must work directly in the container (maybe perform some upgrade), and something goes wrong, you just restart the container from the original image.

I remember having some issues upgrading a Python package in an old production environment. The attempted upgrades just crashed. I knew the service could stay offline for a while, but I had to put it back up. As other services were running on that machine, I didn’t want to interfere with them. So I just set up a new environment for the Python app inside a Docker container, installed it from scratch, and it was up again.

Isolation also suites well legacy apps. You can just throw everything inside a container, and never be afraid of moving between machines, interfering with other services, or breaking things.

Fast on the market and software architecture

You want to be ASAP on the market. So you require developers to write code fast.

We should have a decent code at least, so we can overcome future situations.

Yeah, yeah, but not now, let’s release fast. Then we’ll come back, this is just a concept, we need our clients to see something/we need to fix the issue now (cause it’s burning now, we’ve been ignoring it for a while because it was never urgent).

Both are right. You need good code and fast written code. Can you have them both? I would say not really.

Instead, you can have a decent architecture. At least decent. Start your project, feature, class or function in a manner which will allow you to update code in the moment you realize things went wrong, or when you just need to extend.

You don’t understand, you’re not mature enough, we have to work fast.

Great, I look forward for you to ask me why development is taking so much, why we have bugs.

Use frameworks and/or patterns/advices that others are using and working on for years. If at some point you end up on an unpleasant road, it’s going to be easier to change. Don’t be afraid of things you’re not used to.

And try to work as isolate as possible. Build independent components/libraries/modules/packages that are easy to integrate and dispose when needed, do not throw code everywhere.

Do not try to guess the future, make sure the present allows you to adapt. Otherwise, time, effort, money will be invested in maintaining a monster which holds you back from being fast on the market.

If it’s not broken, fix it before it will be

I’ve recently read a discussion on server software upgrades, and someone was recommending not to upgrade if you don’t have a problem.

My approach is a little bit different, as in I advise you to upgrade from time to time (at least) your OS and packages. In “the real world” it’s not often easy to do this, but if context allows, you should do it. You should prevent unwanted situations, instead of fixing them after they’ve done damage, and maybe suffer consequences.

A basic approach (in a decent context) would be to make upgrades in test environments. After you make sure you’re ready for production upgrade, redirect traffic to some new temporary machines before updating main machines. Of course, if you have your own load balancer instead of a DNS one, it’s easier to do this. Don’t upgrade directly on production, don’t assume nothing could go wrong. Back up data before!

The same goes for code libraries. I’ve seen upgrades being ignored because “we don’t have time now”, and ignorance. Then a moment came when they were forced to make the upgrades, because new libraries were depending on new versions of the existing ones. You should have seen the “joy”, and the bugs which followed in production, as there was no time to test everything as it should have been.

Upgrades can be a pain, they can crash, they can take time, new packages can have issues. However, this is not a reason to ignore them.

Hello, interviewe(r/e)!

An interview should be in both directions. Both the interviewer and the interviewee should have questions to ask, as you know, of course.

While the interviewer is expected to have any kind of questions and requests, I’ve seen most interviewees lack some things I always need from a company in order to get to know them better.

I’ve been on both sides, and I really consider that if you go to an interview, you should ask about the following, and I’m really happy when I’m asked about them:

  • Code. There is no reason for a company to refuse to show you code. 100% there is something that can be shown.
  • Frameworks. If they use custom frameworks, ask details on how they manage some basic situations: models, repositories, dependency injection, dependency manager/packages, events, and so on. And why did they need a custom framework?
  • Tests, build, deploy, devops.
  • Databases. Structure can tell you some things about the project.
  • Team. Is there anyone you will learn from? How many members are there in the team?
  • Loading/compile time in development. If it’s a browser app, ask to see a page refresh. If it’s a cli app (even more if it’s a long live app), ask to see how they reload.
  • Code versioning system.
  • Workflow. From specifications to release. How do they manage the whole process?
  • Critical situations management. What happens if something doesn’t go as planned: bugs in productions, servers crashes, people issues.
  • Hardware and software. Your working environment (desktop/laptop/ide) should be with you, not against you.

I’m not saying you should decline a company if they don’t satisfy you regarding all of the above. Just know them better and make the best decision for you.