Introduction In the ecosystem of microservices, establishing a common foundation(template) for all services not only promotes uniformity but also significantly enhances development efficiency and system maintainability. Spring Boot, known for its “convention over configuration” approach, provides an ideal platform for implementing such a foundation through a template configuration. This blog will explore how to create…
Tackling Technical Debt
Introduction Version control is a valuable tool that can be used to identify areas that need attention to tackle technical debt effectively. By using version control to analyze file frequency and code changes, developers can prioritize their efforts and address the most critical areas first. Analyzing File Frequency and Code Changes Using version control, developers…
Clean Architecture – Notes
There are lot of details in the book – clean architecture. The points below just capture what impacted me the most. Hope the points below would nudge you to go through the book yourself. The higher the number of dependencies on a class/module, the more legacy it becomes. Keep your business logic protected from details…
Integration Testing – Docker Maven Plugin vs TestContainers
Docker Maven Plugin vs TestContainers – Integration Testing Why do we need these? With the advent of containerization, it has become possible to test how our code would behave and interact with each other when placed across containers. One of the most common use-cases is to be able to test database interactions. Although, we will…
Kubernetes Probes
Issue – Liveness probes causing other containers to restart While migrating from mesos to kubernetes cluster we transformed the marathon configuration files to kubernetes yaml file. Upon deployment it was observed that all the containers were restarting all the time. One of the configurations was health checks. Mesos health checks were migrated to kubernetes liveness…
Mesos CPU vs Kubernetes CPU requests, limits and docker
Recently, while migrating a mesos/marathon cluster to kubernetes, it was observed that the response time on kubernetes was substantially slow when compared to that of marathon. So, what can be compared out of the two that can give further insight into the issue. In both the setups, docker was the being used to run and…
Multi-tenant Database Design
Partition ID column New tenant creation – A new row is added to table with the new value in partition/tenant Id column. Other information for this tenant is correlated(with other tables) using the partition Id. Usage – This is useful in cases where the data being inserted into the tables from multiple tenants is not…
Design – Distributed Task Scheduler
Let’s go through the design depicted by the above image. Event scheduling manager This is the interface for creating, deleting or getting status of a job. Workflow Scheduling manager receives a request to create a job. Job metadata is stored in the Jobs DB via a rest call. Although depending on the influx of calls,…
TDD done wrong
TDD stands for test driven development. This translates to tests being written BEFORE the actual code. Let’s look at some of the code smells(and their possible remedies) which happen especially when tests are written AFTER the actual code. Lots of setup These are the tests where a lot of setup is required to get to…
Setting up opengrok using docker-compose
Opengrok is a code search engine. I have been using this tool from a few years and my dependency on this tool has only increased over time. Setting up opengrok has been a pain point for me in the past. Even recently when I tried upgrading from version 1.4 to 1.7, there were a number…