preface

I have a college classmate with whom I have collaborated on many projects. As long as he is around, I am particularly at ease, because almost all difficult problems, to him, can be deftly solved. One of his most memorable words to me was, “What can’t be resolved? If you are willing to read the source code.”

Who is suitable to read the source code?

Speaking of source code, I do not recommend novice to read, easy to discourage. No, you ask a schoolboy to read One Hundred Years of Solitude, and I guarantee he will lose interest in reading. Last year, I swallowed the first ten pages of this book, and then nothing — no more. I feel that I am still a little young, life experience has not reached that level, perception, internalization, thinking ability has not reached that level.

Assessment of

I recommend that programmers have at least one or two years of programming experience before reading source code, which is a good time. I was a junior out of the internship, that level really dare not flatter. Still, the company has some patience with us. More than 20 new people, divided into two groups, one group to make a calculator, the other group to make a drawing tool, two months to complete.

To put it bluntly, it is to assess us. If you fail, please withdraw. What I made was a calculator, and the finished product was later put on CSDN’s resource library, and I cheated a lot of C coins. To be honest, I copied and pasted some of the code from the Internet.

I worked on this part of the code for more than a month, but I didn’t understand it, only to say that I fixed a few minor bugs — and with this ability, I got a job that paid for me.

In the next year and a half, I did not force myself to read the source code, but followed the progress of the project team and accumulated programming experience. Just like kids, they have to learn to walk before they can run.

Flex source code

In 2012, I learned that Flex (a new generation of rich client technology combining the advantages of B/S and C/S technologies) would be the focus of the company’s future development, so I began to study the source code of Flex in the gap between projects. At this point, I felt like I was so good at copy-and-paste (or search engine oriented) that I was able to handle normal tasks, but still felt like A mess.

The overall framework of Flex is designed by Japanese personnel, which has made a layer of encapsulation on the original technology, with richer components, somewhat similar to the popular vue.js or React front end.

I was not involved in the Flex project at the time, but because I was close to a senior at the company, I asked him for the source code for a small project, built a local debugging environment, and started to “beat the weird upgrade”.

Have to admit that the Japanese developers write code or very rigorous, annotations more than code. My Japanese is not very good, but with the help of translation software and code awareness, I can dig into it.

A little disclosure here by the way. There are two source code authors to suzhou branch, I have seen them, at least in the age of more than 40 years old, according to colleagues, there are more than 50 years old, it seems to maintain good ah. They are very humble people (learning the essence of our nation) and are completely technical people – where are all the older programmers? Here’s the answer. As long as you’re skilled, companies need you.

Ability increase + salary increase

After more than four months of unremitting efforts, I feel that my programming ability has been rapidly improved, not only can use the existing components of the framework, but also can expand some custom components when necessary – because I have read most of the source code, dare to touch the above.

In the meantime, I built a chat tool in Flex that I mentioned in an earlier post. The Spark chat tool used in the company is archived and cannot be used to discuss some non-work topics. For example, a few colleagues like to share their experience of World of Warcraft. This tool conveniently provides them with the server on my local computer.

It is by virtue of this chat tool, I was chosen by a leader, directly hired me to be the team leader, responsible for the coding part of the project. More importantly, a raise!

That’s why I’ve always felt that reading source code is an important skill — the ability to transform yourself from a code brick-remover to an engineer who builds wheels.

Having trouble finding a job (Not me)

I now 8 years work experience, but a few years ago when came out, did not pay attention to the foundation, did not study the source code, now 30, feel pressure to come up. Lots of resumes, no interviews.

The above paragraph is the day before yesterday a reader Ann shao gave me the information, after reading, really pretty feel sorry for him. Although reading the source code is not a panacea, but to a programmer’s ability to improve, it is really very important, probably equivalent to internal work mind.

If Shao had settled down to “dive” or “swim” in the source code for a while early in his career (three or five years ago), he would not have worried about his future at the age of 30.

As anyone who’s ever interviewed for a Java job knows, interviewers like to ask questions about source code, such as, “What’s the underlying rationale behind HashMap? What if the size exceeds the capacity defined by the load factor?” If the usual willing to go to the source, these questions you must be able to answer fluently, otherwise it is really a face mengbi ah.

The last

In summary, reading source code will not only improve your programming skills, but also help you to face the interviewer’s questions. By the way, I almost forgot that reading source code is a silver bullet for solving bugs.

This is one of the reasons why GitHub is so popular because the source code on it is open source. This means that if a bug occurs in a program that was caused by the source code, you don’t have to wait for the source code author to fix it. After all, the source code author has so many other important things to do that he can’t wait for you to issue online.

Remember the college classmate I mentioned at the beginning of this article, whose first reaction to a problem was to rip the source code off his pants. In his eyes, the source of the problem was either him or the source code, so I always thought he was a bit of a geek.

And I, usually, check their own code first, if you can’t find it, go to a search engine for help, if you can’t find it, will read the source code.

But if you want to grow, you can’t stay in your comfort zone all the time. You have to bite the bullet. When your head is hard (bald), it is really strong!

The last

To the above readers’ questions, my answer is: go deep and keep learning! There is still a lot of room for improvement before the age of 35, 35 is also a hurdle, mainly because enterprises have higher requirements for people at this age, generally also need certain management ability, so it is better to get MBA while improving skills

Avoiding a midlife crisis is simple and difficult: just keep studying and getting to the level people your age should be getting to

So much for that! What? And I share some information? Don’t know where to learn? Don’t know how to learn?

1. Read the source code

Reading and analyzing source code is the most basic code ability of programmers is also the root of code farming, learning the classical design ideas and common design patterns used in the classic source code, can help you understand how daniu is to write code, so as to absorb daniu’s code skills. In ali interview, the underlying principle of MyBatis, Spring and other frameworks is often asked.

2. Distributed architecture

Alibaba has many large teams, and there are many small teams in such large teams. After entering a small team, businesses will be different. If you want to become a versatile player in first-tier Internet companies, you must understand and learn a lot of knowledge in the most mainstream distributed architecture. And in the interview process of Ali, the interviewer will ask questions about practical application scenarios, such as microservitization, number of users, concurrency, business complexity and scalability, which will not be described here.

3. Microservices architecture

Micro-service is one of the hottest topics in Internet architecture technology, and it is also the direction that bloggers are currently studying. During ali’s interview, interviewers rarely ask questions about micro-services. But as a developer, as a programmer with technical aspirations, microservices architecture is now the mainstream technology that must be understood.

The content of micro services is too much, here are only two, need to know more friends can click to viewBlogger pageTo get more microservices mind maps and related materials for free

5. Performance optimization

Performance has always been a headache for programmers. When the system architecture becomes complex and huge, the performance will decline, especially the first-tier Internet companies like Alibaba pay the most attention to it. Therefore, if you want to join Alibaba, performance optimization must be a part of in-depth study and understanding.

6. Design patterns

Design pattern is a set of repeatedly used, most people know, cataloged code Design experience summary. Design patterns are used to re-use code, make it easier for others to understand, and ensure code reliability. There is no doubt that design patterns are a win-win for yourself, others and systems. Design patterns make coding truly engineering. Design patterns are the cornerstones of software engineering, like the bricks and stones of a mansion. The rational application of design patterns in projects can perfectly solve many problems. Each pattern has corresponding principles to correspond to it at present. Each pattern describes a recurring problem around us and the core solution to the problem, which is also the reason why it can be widely used.

Complete advanced architecture outline

The way has been given to you, just go ahead, if you are still confused you can click on the homepage of the blogger to get some relevant advice and learning materials