在这里插入图片描述
Author: OpenYurt Community

background

In 2021, the China Open Source Software Promotion Alliance COPU led the release of the "2021 China Open Source Development Blue Book", which covers the overall situation analysis, developer analysis, project analysis, and field cases of global open source today, and draws an "open source digital ecological map". Let us fully see the Chinese power in the open source field. The report pointed out that among domestic enterprises, Alibaba's open source activity ranks first, and some indicators are even the sum of other companies, and they have also done a good job in community/opening.

In the same year, in the second "Open Source Software Supply Chain Lighting Program Series Summer Activities" initiated by the Institute of Software of the Chinese Academy of Sciences for college students, namely the "Summer of Open Source", a total of 14 major open source projects have joined the Alibaba Cloud native open source family. . Through active participation in the activities, under the guidance of top open source tutors, the students deeply experienced software development in the real world, felt the charm of open source technology co-construction, and contributed to the vigorous development of the domestic excellent open source software community. .

Although more than half a year has passed since the "Summer of Open Source", the OpenYurt project, which was originally open sourced by Alibaba Cloud, with its non-intrusive design idea, silky smooth experience in the deployment process , has been mentioned many times " " Ease of use ”, community active and open atmosphere and promising development direction still attract more and more partners who love open source to participate. In the "Summer of Open Source - OpenYurt Experience Center", students can quickly get started and participate in the project with a low threshold to solve practical problems. From bystanders to community contributors, let's take a look at what they really feel and what unexpected benefits they have through interviews.

Interview Q&A

Tao Chen, graduate student at School of Software, Zhejiang University
Liu Jiawen, a graduate student at the School of Software, Zhejiang University
Chen Lu, a graduate student at the School of Software, Tongji University

1. Please introduce yourself and let everyone know you well~

Chen Tao: Hello, everyone, my name is Chen Tao, and I am currently a graduate student in software engineering at Zhejiang University.
Liu Jiawen: Hello, everyone, my name is Liu Jiawen, and I am currently a second-year graduate student at the School of Software, Zhejiang University.
Chen Lu: Hi, everyone, my name is Chen Lu. Now he is a graduate student at the School of Software, Tongji University.

2. What hobbies do you usually have? When did you first fall in love with programming? And how to get in touch with the "open source" culture?

Chen Tao: My usual hobbies are reading, watching movies, and running. Aside from the computer courses in high school, the real understanding of in-depth programming is because the undergraduate chooses software engineering as a major. As a novice, I encountered many difficulties in the process of establishing "communication" with the computer at first, but with the continuous expansion of professional knowledge, I gradually fell in love with programming, a direct and logical way of human-computer communication. .

With the rapid development of computing technology, many technical problems may not be found in books. In the process of solving problems, you will naturally come into contact with open source projects, because the problems you encounter are likely to be solved in the latest discussions , this open and shared open source culture is also an important source of innovation for the rapid development of computer technology in my opinion.

Liu Jiawen: In addition to moving bricks in daily life, it is generally a drama. For programming, it is because of professional reasons, and when you get in touch slowly, when you produce something, it brings positive feedback, which motivates you to keep learning new knowledge. In the process, I came into contact with open source projects.

Chen Lu: I usually like reading, table tennis, chasing dramas, and basketball (ranked in order: >). I got into programming because I chose a computer major in college, but I was fortunate to find that the major I chose by mistake unexpectedly fit the nerdy temperament I like to toss.

Contacting open source is naturally a logical thing on the road of "tossing". Build a blog on the server, try a personal RSS service, go to StackOverflow to search for answers, go to GitHub to file an issue, and sometimes write PR by yourself when you encounter problems that cannot be solved. In this process, I unconsciously participated in the open source community.

3. Why did you choose to participate in the "Summer of Open Source" and what do you hope to gain?

Chen Tao: I was mainly diving in the community before, and most of the time I just looked to see if there were any "wheels" available to solve the problem, but I always had the idea of building a wheel in my heart, and I also hoped to participate in the process of open source summer, from A bystander turned contributor.

Jiawen Liu: Before participating in the Open Source Summer, I was already participating in the OpenYurt community. Later, I saw that OpenYurt also participated in the Open Source Summer, so I chose to participate in this event. On the one hand, I want to have a deeper understanding of related technologies, and on the other hand, I can actively participate in community contributions.

Chen Lu: The "Summer of Open Source" activity was attended by classmate Amway. At the beginning, I participated in this activity just to find something to do for my summer vacation with the mentality of giving it a try. Now it seems that the harvest this activity has brought me far exceeded my initial expectations.

4. Did you know anything about OpenYurt before participating in the Open Source Summer event? Why choose OpenYurt among many projects?

Tao Chen: Since the graduate student's direction is edge computing, he focused on projects related to edge computing. chose OpenYurt because of its non-invasive design idea. When I first came into contact with OpenYurt, I only used Docker and Kubernetes. I subconsciously felt that projects involving the edge would be more complicated to use, but is very smooth in both deployment and use, and is compatible with cloud-native technologies such as Kubernetes and containers. It was well integrated. I think that while supports many edge features and scenarios, it is compatible with cloud native features, which is a good design pattern.

Chen Lu: Before participating in the event, I was completely a novice in the field of edge cloud native. I only heard about OpenYurt in a few technical articles, and OpenYurt was still in a state of "holding a pipa and covering my face" to me. Choosing OpenYurt also hopes to "see the world" in a new field through this project and open up a new map.

5. How do you view the technical value of the edge cloud native field where OpenYurt is located?

Chen Tao: With the continuous decline of cloud computing capabilities, it has become a trend to manage scattered but abundant edge computing resources. At the same time, cloud native technology, as a series of technologies born under the cloud background, can make full use of cloud computing resources and has gradually become a standard. Therefore, in the process of edge devices, it is a very challenging and valuable direction to use cloud native technology to shield the differences in underlying devices and unify the environment on and off the cloud.

Jiawen Liu: Compared with other solutions, is non-intrusive to , and both developers and users can feel its of . In addition, OpenYurt has also designed various solutions to solve the problems in edge scenarios, providing different solutions to the problems in the field of edge cloud native.

Chen Lu: OpenYurt is committed to building an infrastructure platform in the edge cloud-native field. Since Kubernetes, as the de facto standard for cloud native, was originally designed for data centers, it did not consider the special needs of many edge scenarios (such as unstable network environments, etc.). What OpenYurt is doing is to make some non-intrusive improvements and extensions to Kubernetes for such scenarios.

6. Did you encounter any difficulties when you first started the OpenYurt project? If so, please expand the introduction~

Chen Tao: The difficulties I encountered at the beginning were mainly in the source code reading. This is the first time I have faced a large architecture and faced many components. In other codes, there may even be cases where you forget the previous code while reading... It will indeed cause some frustration for me who is a first-timer, but I think it is touching every unfamiliar project. stages that must be passed through. Later, I gradually gained some experience in the process of getting familiar with it, such as: grasp the main context, do not indulge in unimportant details; use debugging skillfully, you can observe the running logic well during the running process; and take more notes , record key points and thoughts.

Liu Jiawen: When I first started, the main difficulty was the construction of the cluster. At that time, the functions of the tools for building a community cluster were relatively simple, and the problems encountered in the process still needed to be checked manually. But now the community-related tools are perfect and friendly to newbies.

Chen Lu: Frankly speaking, OpenYurt has a certain learning cost. First of all, it requires a basic understanding of Kubernetes. To understand its design background, you need to combine some knowledge of edge computing. Then, if you want to get started, you need at least a distributed environment and certain hands-on ability. Of course, the community has also noticed these problems. For example, the experience center project I participated in is trying to lower the threshold for using OpenYurt.

7. I understand that your main contribution is the OpenYurt Developer Experience Center, please introduce this component, including the design background, implementation method, challenges faced, problems solved, etc.

Chen Tao: OpenYurt has attracted many developers and users who are concerned about edge computing since it was open sourced. However, due to the different backgrounds of users, they may lack relevant knowledge in the field of cloud computing such as Kubernetes. When using and building OpenYurt clusters, There will be various problems, and the ability of OpenYurt cannot be exerted.

In this context, the OpenYurt community is considering launching an OpenYurt experience center. Users only need to apply for an account through the experience center to obtain and connect to an OpenYurt cluster. At the same time, since the experience account is not in the production environment, and in order to improve resource utilization, the OpenYurt Experience Center will use soft multi-tenancy technology to enable multiple tenants to share an OpenYurt cluster to ensure that users can see the complete OpenYurt cluster while ensuring that Isolation and security of resources.

In this project, I am mainly responsible for developing operators to manage the life cycle of tenants and related resources, including the design of tenant CRDs, the development of controllers, and the issuance of tenant certificates. Among them, the most impressive challenge may involve the tenant certificate, because to carry out the identity authentication of the tenant, the relevant tenant information must be added to the certificate. Therefore, it is necessary to sort out the certificate management logic related to the entire Kubernetes and OpenYurt in a short time, and design the In a non-intrusive case, the injection of authentication information was completed, which took a long time at the time.

Liu Jiawen: The OpenYurt Experience Center consists of multiple parts. I am mainly responsible for the design and development of multi-tenant components. In short, I check and modify the request based on the tenant's information in the request, so that the tenant cannot see the resources of other tenants. .

In the process of design and development, it is necessary to comprehensively consider various requests of tenants and how to handle the corresponding requests. Ultimately, the experience center can have high security for tenants. In addition, in order to realize the whole process of request processing, it is also necessary to have a detailed understanding of the process of API-Server processing requests, so it is required to read the API-Server source code in a short period of time and be able to master the application. This is quite a challenge for me.

Chen Lu: The architecture of the experience center is relatively complex. For the specific design and implementation, please refer to the introduction document of OpenYurt Experience Center [1]. I'm mainly responsible for the yurt-dashboard part, which is actually a web application with front and back ends. Since the front-end and back-end development of this project are all done by myself, I have high requirements on my development ability. In the process of design and implementation, I also encountered some trivial problems. Here I give an example:

How to design the Kubernetes API Client? In order to use the ability to access the Kubernetes API provided by client-go more conveniently in the project, how to design a set of access interfaces that meet the ease of use and scalability. This problem has troubled me for a long time. For this part of the logic, I have refactored several versions before and after, hoping to find a reasonable solution.

a. Directly call the interface functions provided in client-go, abstract common functions, and do not encapsulate classes. (Insufficient scalability, serious code redundancy, difficult to test)
b. Abstract a resourceClient class through which all access requests are sent. (Insufficient scalability, different resources need different request logic to be distinguished by switch, which does not meet the design principle that expansion is greater than modification )
c. Define a Client class for each resource, and put the common logic of all resources in the baseClient base class. (with certain redundancy, strong scalability)

In addition, unlike the toy project of "defense-oriented programming" that I was familiar with before, this project will eventually be launched for actual users to try out. This pressure of facing users directly puts forward high requirements on my coding standardization and design rationality. In the development process, many places need to carefully consider whether it is practical, whether it will affect the availability of the system, and whether it will affect the scalability of the system. There is a famous saying in software development, "Make it work, make it right, make it fast". If my previous development experience mostly stayed at the stage of "make it work", this project has allowed me to stand on a higher level and try to think from the perspective of "make it right, make it fast". Of course, limited by the personal level, the final effect is only unsatisfactory, but I am very grateful to have such a precious opportunity in the open source summer project.

8. More than half a year has passed since the 2021 Open Source Summer. What motivates you to stay in the OpenYurt community and contribute?

Chen Tao: In addition to his own research direction, there is also a promising development direction because of the active and open atmosphere of the community. In the OpenYurt community, you can find points of interest for in-depth participation. From solving some good-first-issues at the beginning, to taking on important features and being recognized, you can gain a great sense of accomplishment.

Liu Jiawen: On the one hand, because his research direction is edge cloud native, his daily learning work revolves around this content; on the other hand, choosing a high-quality open source project and making continuous contributions will also give him a sense of accomplishment.

Chen Lu: Of course, the driving force is the constant iteration of the experience center (escape> Haha, just kidding. I think it is OpenYurt's great community atmosphere makes people happy. To sum it up in one sentence, " A group of professional people" , trust each other and do a worthwhile thing".

9. Looking back on your contribution experience in the OpenYurt community, did you meet your expectations for participating in the Summer of Open Source activities? Do you have any unexpected gains, or interesting stories to share with you?

Chen Tao: It has perfectly met my expectations, that is, from a bystander to a participant. The unexpected gain may be that in the process of continuous review of code and documents, it becomes more and more standardized. I may not have paid too much attention to this aspect before, but after participating in this , I will not know it in the process of writing code. Unconsciously considering the ease of use, portability and other , I think this is a relatively big gain for me.

Liu Jiawen: If there is an unexpected harvest, it should be at the beginning of the registration activity, thinking that it is only for development according to the needs, and the end of the project is the end point. Unexpectedly, during and after the event, the community continued to follow up on our project, giving us the opportunity to share it with you. These continuous feedbacks made me feel the charm of open source.

Chen Lu: As mentioned earlier, the gains from this project far exceeded my expectations. In the process of completing the project, two mentors, Changpu and Xinsheng , gave me a lot of help Take the trouble of to help me, a Kubernetes beginner, answer some silly questions . The completion of this project is inseparable from their guidance and help. In addition, since this project also involves cooperation with two students, Chen Tao and Jiawen, we will have regular sync meetings to synchronize the progress. The experience of analyzing and solving problems together was also very pleasant, which made me meet these new friends.

10. Finally, do you have anything to say to students who are participating in open source community contributions or participating in open source summer activities?

Chen Tao: Through this experience, I realized that in the process of participating in open source, it is not just to solve problems. Due to the open nature of open source projects, all the integrated code must consider legibility and scalability. , including standardizing the code, how the design can be more elegant and generic, and all aspects of the project such as writing related documentation. In the process of continuous review and modification of code and documents, it will also greatly improve their ability to participate in cooperation in complex projects.

Liu Jiawen: I think for students who have already participated in the contribution of the open source community, they may pay more attention to being more active in the community and actively participating in the discussion of the community to enhance their participation. For students who have not participated in the contribution, take me as an example, I didn't know what to contribute to the community and how to contribute. Based on my own experience, if there are students who have participated in open source, you can ask more, if No, you can also submit an issue in the community for help.

Chen Lu: Don't worry too much, just relax, the threshold for participating in the community is definitely not as high as you think. Participate in a discussion, mention a PR to fix the typo, these are all your contributions to making the community better. And Once you get past the initial unfamiliar stage, the community will eventually reward you with unexpected rewards.

About OpenYurt

Built on native Kubernetes, OpenYurt was open sourced by Alibaba Cloud in May 2020, and was selected into the CNCF SandBox project in September of the same year. It is the industry's first non-intrusive edge computing cloud-native open source platform for Kubernetes.

OpenYurt focuses on the concept of "integration of cloud and edge", and provides edge autonomy, cloud-edge O&M channels, unitized deployment, one-click operation, and other pain points in edge computing scenarios such as complex network environment, large-scale application delivery, and difficulty in operation and maintenance. Cluster transformation and other capabilities, through the unified management of cloud edge nodes, enables edge nodes to have the same capabilities as the cloud, helping developers easily complete large-scale application delivery, operation and maintenance, and management and control on massive edge resources.

In the past two years, OpenYurt has achieved full network coverage and local coverage in all scenarios. The application scenarios covered by the entire network include CDN, audio and video live broadcast, Internet of Things, logistics, industrial brain, city brain, etc.; application scenarios of local coverage and Examples include Alibaba Cloud LinkEdge, Youku, Hema, AIBox, Intime Mall, etc.

Welcome to the OpenYurt Experience Center

As an edge cloud native project, OpenYurt involves edge computing and cloud native. Many edge computing developers are not familiar with cloud native knowledge. In order to lower the threshold for using OpenYurt and help more developers get started with OpenYurt quickly, the community has launched the OpenYurt Experience Center platform. New users who want to try the OpenYurt capabilities do not need to build an OpenYurt cluster from scratch. They only need to apply for a test account on the platform, and they can immediately have an available OpenYurt cluster.

Related Links

[1]OpenYurt Experience Center:
https://openyurt.io/docs/installation/openyurt-experience-center/overview
[2] OpenYurt official website:
https://openyurt.io/en-us/

Click here to learn about the OpenYurt project now!


阿里云云原生
1k 声望302 粉丝