Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Orchestrating different bounded contexts, whose responsibility is it?

I have 3 separated services using different databases with REST interfaces:

  • First service: Information about Customers
  • Second service: Information about Customer Trades
  • Third service: Information about Customer Documentation

Problem: Every customer has a Status that should be evaluated based on his trades and documents.

Which service should be responsible for this evaluation and how should I implement the orchestration between the other services?

like image 915
Marcelo Oliveira Avatar asked Dec 02 '25 02:12

Marcelo Oliveira


1 Answers

If you can, I'd create a 4th service. This way you have a service that returns what you need, avoiding the problem (and over chattiness) of calling 2 services and merging the result set. Otherwise, if you don't have access to be able to create a 4th service, maybe write a proxy service that through one call, calls the other 2 services and uses data caching to cache data where possible, to try help cut down on multiple calls in the future for commonly queried customers.

like image 79
Adrian Thompson Phillips Avatar answered Dec 06 '25 04:12

Adrian Thompson Phillips



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!