preamble
Before off and on read part of the JDK common class source code, here I want to study the process of reference in the JDK source code dissection notes to share out, if you can help the need of partners would be great!
This article shares notes on JDK source code dissection.
PS: Because the current mainstream use of the JDK version is still 1.8, so the source code reading is mainly 1.8 version, some places can refer to 1.7 (interview may ask).
The first thing you need is a good tool to do a good job. Not much is needed, a JDK source code dissection notes are enough.
The main purpose of learning the JDK source code:Certainly not for the sake of pretending, after all, who has nothing better to do than abuse themselves ...
1, the interview can not run away. Now as long as the interview Java-related positions, certainly more or less will be involved in JDK source code related issues.
2, understand the principle of not panic. We as users of the JDK, although it is said that every day with a very happy, but sometimes encounter problems or have to follow the underlying source code to see, in order to help us better understand the principle.
3, learning excellent code, ideas and patterns. JDK is, after all, an excellent code base, we use every day, the source code is also inside, as an aspiring programmer, read the source code also allows us to draw more excellent ideas and patterns.
4. Hypnosis before bed. Uh ...... But it does work (funny).
JDK source code dissection notes
Based on JDK 7 and IJDK 8, the entireConcurrentpackage for a comprehensive source code dissection. most of the concurrency features in JDK 8 are implemented the same as in JDK 7, but some additional features have been added. For exampleCompletableFuture, a new implementation of ConcurrentHashMap, StampedLock, LongAdder, and more.
Table of Contents Outline
Multithreading Basics
Atomic class
Lock and Condition
Synchronization tools
concurrent container
Thread Pools and Future
ForkJoinPool
CompletableFuture
Details
Links to related information