容器集群的web应用是指使用软件引擎如Docker在服务器集群的操作系统上部署软件容器,再在其中部署web应用程序的开发方案,它最初是由Docker公司在2013年设计开发的。由于Docker引擎提供了一个额外的软件抽象层,以及操作系统层虚拟化的自动管理机制,使得web应用的部署兼备灵活性和便携性,于是使用Docker容器集群的web应用逐渐成为业界的热门方案。为了使容器集群的web应用能够承载海量的数据和服务并发量,达到较高的可用性和可靠性,开发设计人员必须尽可能地使容器中的应用充分利用服务器资源。但是在实际操作中,开发设计人员由于需要通过繁琐的操作进行手动管理,往往难以观察到容器集群的实时性能,进而影响了负载不均问题的解决。所以,解决以上问题的最好办法是实现一个基于容器集群的web应用性能的自动化分布式测试工具来处理容器集群的性能问题。
本文研究内容包括:容器集群应用的部署和测试工具、web应用性能的检测、性能数据的可视化表示。Docker容器集群的应用有其独特的体系架构,课题需要研究Kubernetes集群配置的过程和原理,比如包括部署Ectd集群、Kucectl命令行工具、Flannel 网络等,并优化部署分配模块,优化测试页面结构,使用户可以通过简易操作实现自动化分布式部署和测试。最后,实现集群部署和测试工具的用户交互界面,性能数据导出后生成可视化界面,提供直观形象的集群性能反馈。
关键字:容器;集群;Web;分布式;Kubernetes
Container cluster web applications refer to the deployment of software containers on server cluster operating systems using software engines such as Docker, which was originally designed and developed by Docker in 2013.Because the Docker engine provides an additional software abstraction layer, as well as an automated management mechanism for operating system layer virtualization, web applications are deployed with both flexibility and portability.Therefore, the web application using Docker container cluster has gradually become a hot solution in the industry.To enable container cluster web applications to carry the sea Since the amount of data and service concurrency can achieve high availability and reliability, developers and designers must make full use of server resources in the container as far as possible.However, in practice, developers and designers often find it difficult to observe the real-time performance of container clusters because of the need for manual management through cumbersome operations, thus affecting the solution of the problem of uneven load.Therefore, the best way to solve the above problem is to implement an automated distributed testing tool for web application performance based on container cluster to deal with the performance problems of container cluster.
The research contents of this paper include: the deployment and testing tool of container cluster application, the visual representation of performance data, the application of Docker container cluster has its unique architecture.We need to study the process and principle of Kubernetes cluster configuration, such as deploying ECTD cluster Kucectl command-line tool and Flannel network, optimizing deployment allocation module, optimizing test page structure, etc.Enables users to automate distributed deployment and testing through simple operations.Finally, the user interface for cluster deployment and testing tools is implemented, After the output of the performance data, the visual interface is generated to provide visual and visual cluster performance feedback.
Keywords: Container;cluster;Web;distributed;Kubernetes
目 录
2.2.3 Replication Controller10
4.2.1 RestartPolicy和Replication Controller22
4.2.2 Replication Controller的工作机制24
4.2.3 Replication Controller的应用场景25
5.3.2 例1:Predicates.PodFitsPorts43
5.3.3 例2:Priorities.LeastRequestedPriority45