Question

How to improve routing between microservices?

Hi @all,

in short: I’ve deployed an application which is separated in several microservices.

The requests from outside are all going to one microservice which redirects the message to other microservices (API Gateway Patten).

Then, the microservices must communicate with each other by also going over the API Gateway.

Everything works fine, but now with my droplets I’ve noticed something: The requests going between several microservices take between 50ms and 3000ms. Since it’s definitely not an internal microservice problem, I assume it’s the routing.

How can I improve the routing and get rid of these delays? Static routing? Would it also make it faster to have the microservice in an internal network?

Help and suggestions are highly appreciated!


Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

Hi @badaemon, that’s a cool question! I believe that you are right, I would definitely suggest trying with an internal network to see how it performs.

Besides that, is your whole setup with droplets or are you using a cluster like Kubernetes? Are you running the application on the droplets directly or do you use containers like Docker?