Service Discovery, deployment Update and expansion of Advanced docker (7)
Original articles, welcome to reprint. Reprint please indicate: reproduced from IT Story Association, thank you!
Original link address: "Advanced article" docker service discovery, deployment update and expansion (7)
Service discovery
All the representations are in the form of ip+ ports.
Traditional service
If there are few services, you can do it in the following way. If there are a lot of services, the basic operation and maintenance staff will collapse to death.
Micro service
If there are too many services, a mechanism for service discovery is needed.
Discovery of the client, discovery of the server
Deploy updates and expansion
Traditional service
Suitable for small projects, few services and few servers.
The deployment of the new service, the code is written, the intranet test passed, went online, and negotiated with the operation and maintenance that the server is relatively idle and resources are tight, so we need to wait for the server to arrive before deployment. The server has told the operation and maintenance staff to copy that application to our server, perhaps through ftp or automation. If it is a web method, it will need to copy a tomcat and assign a port number. Query which ports of the server are used, find one that is not occupied, do domain name resolution with your domain name, modify nginx, and reverse proxy to point to the tomcat just now. Update ftp directly or update the old code automatically, and update it directly with the new code. Any application is 2 instances, making the service highly available, so you need to update the code twice. Offline one, update the code, go online. If the automation is not very good, the basic labor cost is very high and expansion is as troublesome as deployment. Micro service
Most of the service data are updated online frequently. How can microservices solve these problems?
What is service typesetting, service discovery, service deployment, service update, expansion, simplification.
Popular service orchestration tools
It can solve the problems encountered by micro-services in this section.
Mesosdocker swarmk8s
PS: come up with a solution for microservices, and then continue to learn.