What is distributed locking? With loosely coupled distributed systems, several instances of a microservice might be accessing the same shared resource. For example, several instances of a microservice might attempt to write to the same database. We have two kinds of locks: Optimistic: instead of blocking a potentially invalid process, the process continues, in the
Context and problem In traditional architectures, the same data model is used to query and update a database. That’s simple and works well for basic CRUD operations. In more complex applications, however, this approach can become unwieldy. For example, on the read side, the application may perform many different queries, returning data transfer objects (DTOs)
Introduction This is one of the topics that is not very common. Even though we are always interacting with Dates and Times in our application, they can be very complex depending on your use case. Our entire application broke because of some DateTime concepts that wasn’t properly though through so ideally, I am writing an
Introduction Most of today’s programming languages support Enums. These types have the power to be very descriptive while being a value type: An enum is a named constant that corresponds to an integer value type. Each member maps to a number that is used implicitly when calling this constant. You may tend to use them
Introduction Tests can arguably be more important than the code itself. You always get asked about your test coverage, what tests do you use, how did you implement them… People even discuss the famous Pyramid of Tests and try to implement as much as they can in their codebase. Architecture Tests are like the hidden