>>>> 😜😜😜 Github: 👉 github.com/black-ant CASE Backup: 👉 gitee.com/antblack/ca…

A. The preface

2021 is a historic year. In this year, my attitude towards technology has changed from use to research. In this period of time, think a lot of things, here is a summary, to plan a follow-up technical route.

< 2021: source code

So far, I have gone through three stages, to sum it up: using the > sedimentation > theory, I think most practitioners go through the same process.

Stage 1: Use (early graduation)

I remember the first time I wrote a blog in September 2017. At that stage, I was rapidly expanding my scope. Most of the documents were based on usage, but the articles using classes were too common and my writing was not as good as others’.

After thinking about it, I thought that the technology was too broad and lacked depth, so I left the unit at that time, changed from a full stack to focus on the back-end, and began to focus on the back-end knowledge, and the blog also stopped at this stage.

Stage 2: Precipitation (1-3 years)

Since the second phase, Java has gained a lot of use on the server side, and its ecosystem has grown very large.

At this stage, it is important to understand the use of various frameworks to familiarize yourself with various business scenarios.

With the continuous accumulation of technology, I found myself unconsciously accumulating precious wealth, a Git project containing hundreds of framework Demo gitee.com/antblack/ca…

The precipitation period is boring: forced to learn frameworks that have nothing to do with the business, to learn about uses I’ve never heard of, to think about, to practice. But as time goes by, I find these are valuable assets.

With more and more deposits, I found that I could quickly build a framework and easily integrate external tools. However, with the growth of years and business, ordinary use and basic processing have been far from meeting the needs.

Thus, the third stage is entered

Stage 3: Theory (3-5 years)

In the last phase, two open source semi-products were released:

  • AntSSO: An extensible single point of authentication project
  • Engine: A data cleaning project

At that time, I gave up the book before finishing it, mainly because of the lack of theoretical support. So it’s stage three. >>>

The third stage is also in the nuggets issued a year, in this year, in the Nuggets published a total of 114 articles, of which 80% is the source code analysis @ juejin.cn/post/694164…

Source code analysis can quickly help me locate the problem, can solve some complex business needs from the source code level, but if you read more source code will know, read the source code is actually the most basic entry

So what’s waiting for me behind the source code?

Iii. 2022: Practice

In the process of reading source code, we can learn a lot of low-level things, such as:

  • The extensive use of NIO, which has no obvious surface effect, at the bottom of various frameworks
  • Flexible use of various design patterns in the framework
  • The most elegant way to stop

Yes, read the source can see a lot of different scenery, but the promotion of technology is more and more difficult, the role of the business is less, so how to go down the road?

As they say in practice? Should be more! What am I missing at this stage?

  1. Details: In details of a small module of the framework, typical cases include: expansion mode of Redis field,
  2. Concurrency for more comprehensive processes: Some of the problems are very common performance bottlenecks in concurrency, such as IO bottlenecks, which are low-level but sometimes easy to overlook
  3. Practice-based demos: I’ve written a lot of demos before, but none of them are really practical.
  4. A more comprehensive solution: Learn more and discover a high-performance system that is not limited to one framework, or even one language, or one system

This involves various fields, aspects, and a long way to go.

conclusion

The last day of the Spring Festival, I wish you all a happy New Year, promotion.

Appendix: analysis of source code reading ideas

// Note the following:- Do not read all the source code, first trace the main process, and then open branches to see their interest in the module - read the source code as far as possible to draw flow charts, diagrams, according to personal habits to take notes - pay attention to agents and multithreading, do not delve intoCopy the code

Main reading process:

Most open source frameworks are monolithic or Maven aggregators, so a quick look at the overall code is helpful

2 breakpoint choice to read the source code is not necessary to start from scratch, you can rely on experience to guess the business, through the breakpoint directly into the code process. One of my favorite ways to do this is to use Log to determine which classes are being processed, so that you can break into business.

Breakpoints have a lot of in-depth operations that make it easier to get into breakpoints, such as the Condition of breakpoints and expressions, etc. It is helpful to know these

3. Multithreading processing multithreading is more troublesome, after multithreading runs, breakpoints are difficult to deal with. My common approach to multithreading is traceability. Create a breakpoint before the new Thread.

Another scenario is thread pools, which can be used similarly but not obviously.

Can think of only through the Debug tool Threads processing, do you have practical experience to teach 🎁🎁

4. Handling by proxy

Whether AOP or other aspects of the proxy approach, it will eventually pass a class name + method name to proxy, find the reflection of the place directly query the class name.