StatefulSet
-
Deployment와 StatefulSetKubernetes 2023. 7. 1. 16:55
대부분의 어플리케이션은 Deployment 또는 StatefulSet 으로 파드를 배포한다. StatefulSet은 stateful(상태가 있는) 서버 (정보 또는 데이터가 있는 서버) Deployment 는 stateless(상태가 없는) 서버 (정보 또는 데이터가 없는 서버) 쉽게 예를들면 콜센터의 상담원 A와 상담을 하던 중 전화가 끊겨서 다시 전화를 했더니, 상담원 B와 연결이 되었다. A가 본인 노트에만 상담내용을 기록했다면, B는 처음부터 다시 상담을 해야한다. 위의 예 처럼 각 파드가 데이터를 각자 가지고 있으면 다른 파드로 연결되었을 때 서비스에 문제가 발생한다. 하지만 독립적인 빌드/배포/스케일링을 위해서 컨테이너를 사용하는 건데 각 파드가 스테이트풀하게 고유의 데이터를 가지면 안된다. ..