Squash: Microservices Debugger

“What vegetable scares all the bugs? Squash!”
one of my 8-year old daughter’s favorite riddles

Recently I was sitting with a friend who was working on a microservice application, and had asked for my help. He was getting frustrated, because his application wasn’t doing what it was supposed to. Even worse, repeated runs were giving different results. This was a multi-microservice application, and it was very hard to understand what was the problem, or even which service was at fault.

In an attempt to figure out what was going on, my friend scattered many print lines throughout his code to log the states of many variables. But he ended with a ream of logs, and sorting through them seemed a daunting task. Instead, I suggested that we should use a debugger to add some breaking points to the code, which would allow us to interact with the program as it runs and have a complete view of its state. But my friend — who belongs to the generation who was “born in the cloud”, and had never developed old-fashioned applications — didn’t quite know what I was talking about. This made me realize that one of the most powerful tools I had had back when I was a young system developer — namely, a strong debugger with a friendly IDE — is totally missing from the toolbox of microservice developers.

However, I did not think there is anything inherent to the microservise architecture — or distributed applications in general — that should prevent the use of modern debuggers. Moreover, I thought that this can be done by the very same debuggers that are currently popular with developers of monolithic applications. What was required is to coordinate and integrate the simultaneous debugging of the different services.

This is exactly what Squash, the first project from my new company solo.io, is doing. Squash allows devs to trace a thread, using breakpoints on each microservice to reveal the full state of the microservice at that point in operations. Users can pick the debugger of their choice, and use any IDE that supports that debugger. If — just like me — you already have a debugger you’re used too, or and IDE whose keyboard shortcuts you already memorized, you can keep using it to debug your microservices.

On the other side, squash interfaces with different cluster managers/paas such as Kubernete, Cloud Foundry, Docker Swam and Mesos. This seemless integration between the debugger and the platform gives devs the same debugging experience independent of the platform they’re using. The architecture of Squash is modular and expandable. It is straightforward to add support to additional debuggers and platforms.

I was thrilled about the great feedback Squash got when I described and demonstrated it in my talk at the O’Reilly OSCON open source conference last week. With the help of the community, I expect that pretty soon Squash will support even more debuggers and platforms.

Please visit our repository and try our Getting Started with Squash tutorial.