Microservices Interview Questions & Answers
Microservices Interview Questions & Answers
sh
to
👉
Git & GitHub -
hu
https://github.com/AshutoshG1?tab=repositories
As
👉
Whatsapp Group -
https://chat.whatsapp.com/Iy2Ag6hE35WENehlmNcctV
ith
👉
Telegram Group -
W
https://t.me/+3jqmwqzNp3xlMTZl
de
👉
YouTube
https://youtube.com/@codewithashutosh247?si=rXike59WnLhUEUkL
co
1
sh
to
Interview hu
As
Preparation
ith
W
de
co
2
Microservices
sh
● In microservices architecture we develop the whole application into
smaller mini projects.
to
● Those mini projects are also called microservices.
● These microservices can be developed , deployed and maintained
hu
independently.
● We can implement security at each microservices.
● Each micro service can be developed in a different programming
As
language.
● Each microservices are loosely coupled.
● It is good for large size applications but not for small size applications
because it will cost more.
ith
Architecture?
3
sh
to
Q. What is an API Gateway?
hu
As
● An API Gateway is a server that acts as an entry point for client
requests, routing them to appropriate microservices.
ith
4
services.
sh
Q. What is an Aspect oriented programming language
?
to
● Aspect-Oriented Programming is a programming paradigm that
focuses on separating cross-cutting concerns from the main business
hu
logic by using aspects, which encapsulate these concerns and apply
them across multiple parts of an application.
As
Q. What is a spring actuator ?
● Spring Actuator provides production-ready features for monitoring
and managing Spring Boot applications, including health checks,
ith
spring boot ?
● Yes, you can change the default port number in Spring Boot by
de
Q. What is OAuth ?
● OAuth is an authorization framework that allows third-party
applications to obtain limited access to a user's resources without
exposing their credentials.
● It uses tokens to grant access.
5
Q. What are SOLID principles ?
● The SOLID principles are a set of design rules in object-oriented
programming that help create more maintainable, scalable, and
understandable software.
● Here SOLID is an acronym which stands for -
○ Single Responsibility Principle (SRP):A class should do one
thing and therefore it should have only a single reason to
change.
sh
○ Open/Closed Principle (OCP):A class should be open for
extension but closed for modification.
to
○ Liskov Substitution Principle (LSP):Derived or child classes
must be substitutable for their base or parent class.
hu
○ Interface Segregation Principle (ISP):Classes should not be
forced to implement a method that they do not need.
○ Dependency Inversion Principle (DIP):High level classes
As
should not depend on low level classes. Both should depend
upon abstraction e.g. Interfaces , abstract classes
ith
Q. @EnableEurekaServer ?
● The @EnableEurekaServer annotation is used to mark a Spring
co
Q. @EnableEurekaClinet ?
● The @EnableEurekaClient annotation is used to mark a Spring
Boot application as a Eureka Client, enabling it to register with a
Eureka Server and discover other services.
6
Q. What is fault tolerance?
● Fault tolerance refers to the capability of a system to continue
functioning correctly even in the event of failures or faults, ensuring
reliability and resilience.
sh
● Cookies are small pieces of data stored on a user's device by a web
browser that are used to remember user preferences, session
information, or track user behavior.
to
Q. How do microservices communicate with each
hu
other ?
● Microservices communicate with each other through APIs, typically
using HTTP/REST, gRPC, or messaging queues. This allows them to
As
exchange data and commands.
ith
👉
https://youtube.com/@codewithashutosh247?si=rXike59WnLhUEUkL
W
https://chat.whatsapp.com/Iy2Ag6hE35WENehlmNcctV
de
co
7
sh
to
👉
Git & GitHub -
hu
https://github.com/AshutoshG1?tab=repositories
As
👉
Whatsapp Group -
https://chat.whatsapp.com/Iy2Ag6hE35WENehlmNcctV
ith
👉
Telegram Group -
https://t.me/+3jqmwqzNp3xlMTZl
W
👉
YouTube
de
https://youtube.com/@codewithashutosh247?si=rXike59WnLhUEUkL
co