Apache Kafka and RabbitMQ are two popular open-source and commercially-supported pub/sub systems that have been around for almost a decade and have seen wide adoption. Given the popularity of these two systems and the fact that both are branded as pub/sub systems, two frequently asked questions in the relevant online forums are: how do they compare against each other and which one to use? Origins … Continue reading RabbitMQ or Apache Kafka?
Generally any class allows clients to create objects by providing a public constructor. There is another technique which every programmer should be aware of. An Static Factory. A class can provide one static factory, method which is simply an static method which returns object of the class. Note that a static factory method is not the same as the Factory Method pattern from Design Patterns. There are few … Continue reading Static Factory vs Constructors
Terminologies are always an important part of understanding any design pattern. Below are some of the important terms that we come across on a daily basis if we are implementing our application in DDD way. You can read more about DDD in our previous articles here. Ubiquitous language: – In DDD world, Its a language which is understood by every one. i.e. tech guys should … Continue reading DDD Terminologies
Factory design pattern belong to the Creational design pattern category which explain how the objects are created. Factory Design Pattern comes with different flavors and we use the flavor as per our convenience. The very common example of Factory design pattern can be found in Spring. Creation of beans in Spring container is done using Factory design pattern only. The implementation is really simple. Create … Continue reading Factory Design Pattern
This is kind of Behavioral Design Pattern(BDP) and as per the BDP definition, “Behavioral patterns describe how the objects behave when they interact with each other” and as the name explain this design pattern is used when we give command to some one else to get our job done. Example: When you visit any restaurant, you place an order to waiter not to cook and its … Continue reading Command Design Pattern