Microservice architecture questions

  1. What is the difference between Monolithic, SOA and Microservices Architecture
  • Monolithic Architecture: It is “like a big container” where all the software components of an application are bundled together tightly. It is usually built as one large system and is one code-base.
  • SOA (Service-Oriented Architecture): It is a group of services interacting or communicating with each other. Depending on the nature of the communication, it can be simple data exchange, or it could involve several services coordinating some activity.

(Three layered architecture – UI, service, and database)

  • Microservice Architecture: It involves structuring an application in the form of a cluster of small, autonomous services modeled around a business domain. The functional modules can be deployed independently, are scalable, are aimed at achieving specific business goals, and communicate with each other over standard protocols.
  1. What are main features of Microservices

Decoupling: Within a system, services are largely decoupled into small components. The application can therefore be easily constructed, altered, and scalable

Componentization: Microservices are viewed as independent components that can easily be exchanged or upgraded

Business Capabilities: Microservices are relatively simple and only focus on one service

Team autonomy: Each developer works independently of each other, allowing for a faster project timeline

Continuous Delivery: Enables frequent software releases through systematic automation of software development, testing, and approval

Responsibility: Microservices are not focused on applications as projects. Rather, they see applications as products they are responsible for

Decentralized Governance: Choosing the right tool according to the job is the goal. Developers can choose the best tools to solve their problems

Agility: Microservices facilitate agile development. It is possible to create new features quickly and discard them again at any time.

  1. What are the pros and cons of Microservices

Pros:

  • Self-contained, and independent deployment module.
  • Independently managed services.
  • In order to improve performance, the demand service can be deployed on multiple servers.
  • It is easier to test and has fewer dependencies.
  • A greater degree of scalability and agility.
  • Simplicity in debugging & maintenance.
  • Better communication between developers and business users.
  • Development teams of a smaller size.

Cons:

  • Due to the complexity of the architecture, testing and monitoring are more difficult.
  • Lacks the proper corporate culture for it to work.
  • Pre-planning is essential.
  • Complex development.
  • Requires a cultural shift.
  • Expensive compared to monoliths.
  • Security implications.
  • Maintaining the network is more difficult.
  1. What are the core concepts proven by the Microservices

Coupling: It is defined as a relationship between software modules A and B, and how much one module depends on or interacts with another one. Couplings fall into three major categories. Modules can be highly coupled (highly dependent), loosely coupled, and uncoupled from each other. The best kind of coupling is loose coupling, which is achieved through interfaces.

Cohesion: It is defined as a relationship between two or more parts/elements of a module that serves the same purpose. Generally, a module with high cohesion can perform a specific function efficiently without needing communication with any other modules. High cohesion enhances the functionality of the module.

  1. What is the asynchronized microservice implementation

This is a way to implement independent API calls between each microservices using a queue or pub sub model. So, using this all the microservice will be independent and can be up and running individual without any disturbance each other and will be more Coupling.