這是一個建立於 的文章,其中的資訊可能已經有所發展或是發生改變。
A service is a process that:
1. is designed to do a small number of things (often just one).
2. has no user interface and is invoked solely via some kind of API.
An application, on the other hand, is pretty much the opposite of that. It has a user interface (even if it’s just a command line) and often performs lots of different tasks. It can also expose an API, but that’s just bonus points.
個人理解,service
一般專註做一件事,沒有使用者介面,並且通過API
與application
互動。而application
會有使用者介面,並且通常可以運行很多任務。舉個例子,web browser
就是application
,而web server
即為service
。
A Kubernetes cluster does not manage a fleet of applications. It manages a cluster of services.A service running in a container managed by Kubernetes is designed to do a very small number of discrete things.
If your services are small and of limited purpose, then they can more easily be scheduled and re-arranged as your load demands. Otherwise, the dependencies become too much to manage and either your scale or your stability suffers.
K8s
即是用來管理service
的。