Questions tagged [microservices]
Microservices are small, independent processes that communicate with each other to form complex applications which utilize language-agnostic APIs. These services are small building blocks, highly decoupled and focused on doing a small task, facilitating a modular approach to system-building.
1,042 questions
1
vote
2
answers
227
views
Access Token Or Alternative for Microservices For Resource Level Granular Checks
Hi I have following structure :
Client App (layer 1)
Business logic Services ( Layer 2)
Business Logic layer consists of many microservices . Access token can be created and passed from APP layer to ...
0
votes
2
answers
642
views
Clean Architecture with Microservices
I'm fairly new at system architecting and I'm looking for some advice. My company is revamping its order management system. Currently is a monolith system that scales very poorly and is difficult for ...
2
votes
2
answers
353
views
Can chatty microservices be okay to use if there is a specific use case for them?
Introduction
Hi everyone,
in my company we are using microservice approach and of course are trying to do it as correct as possible. There is a new requirement coming up where I have laid out a ...
1
vote
4
answers
3k
views
How to build REST uri that fetches children by parent ID
I am building 2 REST microservices: ParentService and ChildService. I need to build endpoint to fetch all Child resources related to specific Parent, so I have these URI's as options:
GET /parent/{...
-2
votes
3
answers
153
views
Microservices messaging and coupling [duplicate]
So I am designing some microservices that communicate via messaging and event queues.
However, if I update a message class, for example remove a field, this will break several participating ...
1
vote
2
answers
246
views
Designing a microservice architecture
I am looking to enhance my skills in back-end technologies and would need your help in setting up a scalable microservices architecture.
Here's my project.
I have N sensors that send me data (Pressure,...
3
votes
2
answers
499
views
Can multiple producers cause events with the same key to be enqueued out of order within a specific partition of a topic?
I'm aiming to create a simple event-driven system where each microservice operates with its own database. The idea is to share database changes across microservices through events. To ensure proper ...
2
votes
1
answer
673
views
Centralize input validation across multiple Microservices
My company, which specializes in logistics and transportation, delegated the majority of the backend microservices to our team. All of the microservices (which our team inherited from "past ...
4
votes
1
answer
3k
views
Using a single Postgres server process to manage multiple databases in a microservice application
One of the main guidelines I keep seeing for successfully building a microservice application is to use a separate database for each microservice. In diagrams these are usually depicted as physically ...
0
votes
2
answers
309
views
When should we separate common parts of multiple services into one separated service
We have some services (consider 10, some of them already exist and some are yet to come). All of these services have a common part where they keep track of what's being changed, and these so-called &...
0
votes
0
answers
157
views
Can the Enterprise Service Bus in SOA be replaced by multiple service bus implementations and still be SOA?
When and Service Oriented Architecture (SOA) is designed, and the ESB is changed to multiple independent service busses that talk to each other (pub/sub), does the architecture cease to be SOA? Is it ...
0
votes
0
answers
94
views
Using messaging and rest to communicate services at the same time
I have two microservices, USERS and PRODUCTS, the second one creates objects referred to first one so it needs first to check that exists
First I though in a redis cache, but then I realize that for ...
0
votes
0
answers
224
views
JWT Cookie and API Gateway
Background
I have an authentication microservice that handles the user authentication and returns 2 JWT cookies (access_token and refresh_token).
I want to incorporate an API gateway that does the JWS ...
1
vote
2
answers
2k
views
Why do Streamlit applications often consume a FastAPI backend?
I am fond of writing Streamlit applications (when a front-end is needed) and fastAPI backends when I just need a REST API.
I've seen many blog posts where these two are combined - with the Streamlit ...
1
vote
1
answer
2k
views
Single api gateway or one for each microservice
We are going to have multiple microservices and decided to use api gateway. What we couldn't decide is if we should go for a single gateway for all of them or one for each. The reason why one for each ...
0
votes
1
answer
328
views
How to write custom implementation of a service/flow for a tenant in a multi-tenant microservice system?
I have a Java Spring boot microservice in production which supports multi-tenancy and the tenants are isolated at database level. This microservice exposes REST APIs for communication. During a ...
2
votes
1
answer
206
views
Does it make sense to create a new service to house multiple features that are related business-wise but tech-wise independent?
We are beginning to add third-party integrations that all have to do with a certain business concept. (If it helps to make things concrete, in our case it's "measurements," i.e. third-party ...
0
votes
2
answers
225
views
How do you handle using same data in different microservices
We have a microservices application and our User management service is the source of truth for user's first and last name. But we also need these in the Reporting service, where we generate reports ...
9
votes
5
answers
4k
views
Which comes first: CD/Trunk-based development or microservices?
My company* wants
to move from using long-running feature branching (~up to a few weeks) to continuous integration with trunk-based development, and
to break up our monolith into microservices.
We'...
-1
votes
1
answer
527
views
Using a shared enum across 15 nanoservices [closed]
Originally posted here, moved to code review, redirected from code review back here as there is no code to review. I think the question is enough abstract to be asked here.
I have a mono repo with ...
0
votes
2
answers
213
views
Microservice Web app - How will I handle User Login in my project management app
I've just started learning to use this architecture and I'm trying to build a simple project management app. The App works such that a user after registering, creates a workspace. This Workspace is ...
0
votes
1
answer
128
views
Domain Boundary Definition in `proximity service` as a Case Study
While practicing System Design, I decided to create a hypothetical proximity service (like Google Maps) with a microservice architecture. Suppose we have 3 core categories of functionality:
CRUD ...
-1
votes
3
answers
638
views
Avoid race condition using RDBMS transaction
I am working on design of a distributed system which will process some events. For simplicity lets say, multiple instance of same service will be consuming from same queue, every message will have a ...
-1
votes
3
answers
212
views
Choosing an Approach for Microservice Communications
I'm developing a doctor-patient system that consists of two microservices, namely the "doctor" and "patient" microservices. Both doctors and patients share some common attributes, ...
0
votes
1
answer
601
views
Cheap But Effective Solution for Logging in a private rest microservices backend api
I've created a backend following a microservices architecture and now I need to implement logging.
my understanding
After reading some articles about this topic, I've listed below some "pretty ...
3
votes
2
answers
412
views
Best approach to microservice shared databse architecture
I have two microservices, one Flask (python) and one Spring (java), they currently share a database. The Flask microservice handles processing json files (~40mb) for each user (could be 100's or 1000'...
2
votes
1
answer
1k
views
In an event-driven system, what are the best practices around the number of events and size/atomicity?
If you can have one event with multiple "things to process" or one event per thing to process, what is considered the best practice? Bearing in mind, the former option may involve persisting ...
1
vote
4
answers
1k
views
Microservices distributed lock mechanism
I am using spring boot with mongo db (azure cosmos db) in my microservices. Currently I have an Orders collection that stores Orders. These documents have a field userId that is null when the document ...
0
votes
0
answers
128
views
Data producers and consumers: How to connect MySQL with microservices?
Consider a web-app with 5 micro-services deployed with Docker, and a MySQL container dedicated to storing data produced from other services (shared-database pattern). How should I make the connection ...
1
vote
1
answer
715
views
Ordering events across multiple topics in a distributed system
Our platform is growing in the number of events we're raising, and these different events are often related to one another:
ProductCreated
ProductUpdated
ProductTakenOffSale
ProductPutOnSale
...
0
votes
2
answers
163
views
How to handle the consumption of multiple event types when timing is crucial?
I have a distributed platform which allows customers to make purchases, and the items which are purchased are stored in an inventory:
Sales app -> PurchaseEvent -> Inventory app
The Sales app ...
3
votes
2
answers
2k
views
How to design inter-service communication with notifications microservice?
I'm creating an application based on the microservice architecture and stuck on notifications microservice design. Basically it should be a service that notifies users about events happening in the ...
2
votes
3
answers
1k
views
Is layered architecture style inherently monolithic?
Overall cost and simplicity are the primary strengths of the layered architecture style. Being monolithic in nature, layered architectures don’t have the complexities associated with distributed ...
-2
votes
1
answer
125
views
Proper use of microservices within the system
I have an application in which a client interacts with a backend, which interacts with blockchain. Since blockchain executions can be time-consuming, they are executed asynchronously within different ...
2
votes
1
answer
132
views
Is my security pattern correct for authenticating principal users to my microservices?
We are trying to implement an authorization and authentication service for our product.
Now, we would have to cater to different kinds of IAM systems like SSO, LDAP and Basic Username+Password in ...
1
vote
3
answers
2k
views
How to handle dependencies between microservices all called within one large service
We are working on a suite of Python 'services' each of which is basically an application that does some calculations based on a domain (data) model and returns the results. These services are designed ...
0
votes
1
answer
775
views
How to decomposing a single bounded context into multiple microservices for organisational purposes?
I have a monolith implementing what is basically an ETL process, receive data from external system, orchestrate the processing of it, and then pass the results back to an external system. (The ...
3
votes
2
answers
499
views
What make a microservice a microservice?
I am new to microservice.
While learning about them, I was wondering what is the basic rules (the minimum) that make a microservice a microservice.
I have found some rules/characteristics along the ...
0
votes
1
answer
1k
views
Many-To-Many relationships in a Microservice architecture and if the services are correctly identified
I am creating a distributed chat system with a microservice architecture where a user can log in and chat with another user. The services that I identified is a conversation service that handles chat-...
1
vote
1
answer
885
views
Exchanging data between two Microservices
I am facing this problem and would like to review my approach to it here.
A Client sends an HTTP request to Service A and is expecting an answer.
Service A is connected to DB A. When it receives a ...
0
votes
1
answer
171
views
Should I create access control as a microservice or keep the access control logic as part of the specific microservice?
I was wondering if I have a microservice called, for example, Weather, and only certain people can update certain properties around the weather such as Temperature, Precipitation, and Wind.
These ...
-1
votes
1
answer
59
views
Looking for specific paragraph in RFC [closed]
Some decades ago working with IRC, I remember a paragraph of some RFC and now I'm looking for it. I don't remember it by memory, only a concept:
When it comes to communication between two services, ...
5
votes
4
answers
564
views
Should every service have its staging environment?
I'm trying to break down my dockerized monolith into a few services that can be deployed independently.
Right now, I have a development environment, a staging environment and a production environment. ...
0
votes
3
answers
375
views
Using GitHub repository as API
I have a set of complex data, which I use on various subdomains of my project. Data are static most of the time, it changes few times per year.
Currently, it's hardcoded in every project which needs ...
1
vote
1
answer
477
views
Determine when distributed and parallel process is completed
In a distributred system that uses parallel processing to complete tasks and I want to determine when all sub tasks have been completed, what design method or principals can i apply ?
I am using ...
2
votes
1
answer
1k
views
Aggregating responses from several services with reversed proxy (API gateway): where to place code?
We have a system with a few microservices and multiple clients (Web, mobile). Currently, only one microservice (let's call it "Master MS") exposes a public API, which is used by all clients. ...
1
vote
1
answer
600
views
Microservices Pattern - Downstream Services Registering Themselves with an Upstream Orchestrator?
I'm looking for some guidance on a design proposition I have to accomplish the following use case:
We have several small microservices that each generate a unique set of "analytics" or ...
1
vote
1
answer
370
views
How to manage autorization for internal service to service communication in a microservice architecture?
At deployment time, I register my microservices in the following way:
They register themselves in Keycloak to have an identity as a confidential client;
Then they call an endpoint on a dedicated ...
0
votes
1
answer
169
views
Return type abstraction of a service layer that calls an API
I'm trying to find the best solution to abstract the return type of the service layer.
I have a controller that calls a service to create a user. The service calls a REST API and receives an HTTP ...
0
votes
4
answers
218
views
Microservice arcitecture - seperation of services
The Microservice arcitecture is still a new thing for me to work with, so it gives me some unanswered questions.
In my case each MicroService has its own database.
I need a UserService to handle CRUD ...