David Heinemeier Hansson: Microservices vs. Monolith - https://www.youtube.com/watch?v=rkXGSLf-rVQ
For the last several years, one of the big titanic battles in how to structure your application has been to go microservices or to go monolith. This debate has been raging on and off, sometimes intensively, otherwise dulling down. But as of recent note, it's kind of blossomed up again, because a lot of applications who've gone with a microservices architecture when that was the hot, hot thing, have I realized that perhaps it wasn't so hot for them? Even the likes of Amazon has backed off on microservices for at least some of their applications. And I think there's a really good reason for that. Microservices is a pattern that is about organizational structure much more than it is about how to organize your code. If you have incredibly large teams working on single applications and you have to break those up such that the individual teams can own a sub area of it, yeah, microservices can make sense in some cases. But if you're a team of 10, 20, maybe even 50 or 100 developers, going with a monolith is just so much simpler. Instead of replacing all your method calls with network calls, you can just keep it on the same computer. When you don't have to worry about network connectivity to make the app do its most basic functions, you cut out a huge swath of complexity that otherwise bogs you down, makes things hard to debug, makes it hard for any individual to understand the whole system. And I think what's really key here is to realize that different patterns fit different organizations. Microservices, and that whole approach came out of companies like Netflix, with thousands and thousands of developers who needed a different approach to building their systems and making it scale for that level of an organization. And if you take those kinds of patterns, the patterns that were built and extracted from companies of thousands of developers, and you apply them to companies of 5, 10, or 100 developers, you very often get really poor results. You are paying a heavy complexity tax for an environment and a context that just doesn't exist in your organization. That, to me, is one of the most foolish things that you can do. So I love the monolith. I love it so much. I coined the term the Majestic Monolith many years ago. I've been advocating for keeping things as simple as possible for as long as possible. And the Majestic Monolith does exactly that.
David Heinemeier Hansson: Microservices vs. Monolith - https://www.youtube.com/watch?v=rkXGSLf-rVQ
지난 몇 년 동안, 애플리케이션을 어떻게 구조화할지에 대한 큰 논쟁 중 하나는 마이크로서비스로 갈 것인지 모놀리스로 갈 것인지였습니다. 이 논쟁은 때로는 격렬하게, 때로는 잠잠하게 계속 이어져 왔습니다. 하지만 최근 들어 이 논쟁이 다시 부상하고 있는데, 그 이유는 마이크로서비스 아키텍처가 인기였을 때 그 방향으로 간 많은 애플리케이션들이 자신들에게는 그렇게 좋지 않았다는 것을 깨달았기 때문입니다. 심지어 아마존 같은 회사도 적어도 일부 애플리케이션에서는 마이크로서비스에서 물러났습니다. 그리고 이에 대한 정말 좋은 이유가 있다고 생각합니다. 마이크로서비스는 코드를 어떻게 구성할지보다는 조직 구조에 관한 패턴입니다. 만약 하나의 애플리케이션에서 작업하는 매우 큰 팀이 있고, 개별 팀이 하위 영역을 소유할 수 있도록 그들을 분리해야 한다면, 네, 마이크로서비스가 어떤 경우에는 의미가 있을 수 있습니다. 하지만 만약 10명, 20명, 심지어 50명이나 100명의 개발자 팀이라면, 모놀리스로 가는 것이 훨씬 간단합니다. 모든 메소드 호출을 네트워크 호출로 대체하는 대신, 같은 컴퓨터에 그냥 둘 수 있습니다. 앱이 가장 기본적인 기능을 수행하기 위해 네트워크 연결을 걱정할 필요가 없을 때, 많은 복잡성을 제거할 수 있습니다.복잡성의 거대한 덩어리가 당신을 옥죄고, 디버깅을 어렵게 만들고, 개별 개발자가 전체 시스템을 이해하기 어렵게 만듭니다. 여기서 정말 핵심은 다른 패턴이 다른 조직에 맞다는 것을 깨닫는 것입니다. 마이크로서비스와 그 전체 접근법은 수천 명의 개발자를 둔 Netflix 같은 회사에서 나온 것으로, 그런 규모의 조직에서 시스템을 구축하고 확장하기 위해서는 다른 접근법이 필요했습니다. 만약 그런 종류의 패턴들을, 수천 명의 개발자를 둔 회사에서 구축되고 추출된 패턴들을 5명, 10명, 또는 100명의 개발자를 둔 회사에 적용한다면, 매우 자주 정말 좋지 않은 결과를 얻게 됩니다. 당신은 무거운 복잡성 세금을 내고 있는 것입니다 당신의 조직에는 존재하지 않는 환경과 맥락을 위해서 말이죠. 그것은 제가 보기에 가장 어리석은 일 중 하나입니다. 그래서 저는 모노리스를 사랑합니다. 정말 많이 사랑해요. 몇 년 전에 웅장한 모노리스(Majestic Monolith)라는 용어를 만들었습니다. 저는 가능한 한 오랫동안 가능한 한 간단하게 유지하는 것을 옹호해왔습니다. 그리고 웅장한 모노리스가 정확히 그것을 해냅니다.