Search code examples
amazon-web-servicesmicroservices

Micro Service Architecute - Independent server service or on same server?


I am designing the architecture for software. I am in process of creating micro services related to big component.

Either i can create micro service on different server or on same server. Is it good to create micro service component on same server instance or i can create different micro-services on diffrent server.

I think its good too have different server for bigger components, obviously it will increase the cost. Can any one please let me know your thoughts on this. Thanks


Solution

  • I recommend a combined approach; Services are containerized in a shared server, this provides some level of isolation between the services. While using multiple servers for increasing availability and horizontally scaling.

    From my experience this achieves the lowest cost and highest availability.

    A good container orchestration system like Kubernetes abstracts this and combines all servers in a one virtual cluster, which simplifies the management of the whole infrastructure. In addition it provides some useful services that benefits this type of architecture, like managing the lifecycle of individual services, load balancing and moving services between nodes in case of hardware failure.