Practical documentation: thoroughly understand JVM+Linux+MySQL+Netty+Tomcat+ concurrent programming

Insufficient preparation for the interview is actually irresponsible to yourself and a waste of your time. Today, I have compiled a practical document for everyone, so that you can systematically understand the content of architect building: Linux basics and advanced+ High-performance Netty framework + MySQL + advanced concurrent programming + JVM performance tuning + Tomacat

Note: All the documents and notes of the following materials (including answers) can be shared with everyone for free. Those who need these materials

Practical documentation: thoroughly understand JVM+Linux+MySQL+Netty+Tomcat+ concurrent programming

 

Let's first look at an architect's special content map:

Practical documentation: thoroughly understand JVM+Linux+MySQL+Netty+Tomcat+ concurrent programming

 

1. Linux related content:

(1) Linux interview topics

  • What are the main types of kernel locks in Linux?
  • What is the meaning of user mode and kernel mode in Linux?
  • How to apply for a large chunk of kernel memory?
  • What are the main ways of communication between user processes?
  • What are the functions to apply for kernel memory through the partner system?
  • What are the key data structures of the Linux virtual file system? (Write at least four)
  • In which data structure is the operation function of the file or device stored?
  • What are the files in Linux?
  • What are the system calls to create a process?
  • What are the ways to call schedule() for process switching?
  • Does the Linux scheduler schedule processes based on their dynamic priority or static priority?
  • What is the core data structure of process scheduling?
  • How to load and unload a module?
  • Where are the modules and applications running in?
  • Are floating-point operations in Linux implemented by the application or by the kernel?
  • Can module programs use linkable library functions?
  • What is cached in the TLB?
  • What kinds of devices are there in Linux?
  • What is the key data structure of the character device driver?
  • What functions does the device driver include?
  • How to uniquely identify a device?
  • How does Linux implement system calls?
  • What is the function of Linux soft interrupt and work queue?

Linux interview topics and answers:

Practical documentation: thoroughly understand JVM+Linux+MySQL+Netty+Tomcat+ concurrent programming

 

2. Netty related content

(1) Netty interview topics

  • What is the difference between BIO, NIO and AIO?
  • What is the composition of NIO?
  • What are the characteristics of Netty?
  • Netty's threading model?
  • The reasons and solutions for TCP sticking/unpacking?
  • Know which serialization protocols
  • How to choose a serialization protocol?
  • Netty's zero copy implementation?
  • What are the high performance of Netty?
  • NIOEventLoopGroup source code?

Practical documentation: thoroughly understand JVM+Linux+MySQL+Netty+Tomcat+ concurrent programming

 

(2) Netty actual combat

  • Netty concept and architecture
  • Codec
  • Network protocol
  • Case studies of Droplr, Firebase, Urban Airship, Facebook and Twitter

Practical documentation: thoroughly understand JVM+Linux+MySQL+Netty+Tomcat+ concurrent programming

 

Three, MySQL related content

(1) MySQL interview topics

  • What are the three database paradigms?
  • What are your experience in database optimization?
  • What are the mysql tables related to permissions?
  • Please briefly describe the types of commonly used indexes?
  • Basic operation commands of mysql:
  • The principle and process of mysql replication:
  • Replication types supported by mysql
  • The difference between myisam and innodb in mysql
  • The difference between varchar and char in mysql and the meaning of 50 in varchar(50)
  • The names of the four transaction isolation levels supported by InnoDB in mysql, and the difference between the levels
  • There is a large field X in the table (for example: text type), and the field X will not be updated frequently. Reading is the main focus. What is the advantage of splitting the field into sub-tables?
  • What does the row lock of the InnoDB engine in mysql accomplish (or realize) by adding it?
  • If there is only one field of type VARCHAR(N) in a table, utf8 encoding, what is the maximum value of N (accurate to the order of magnitude)?
  • Principles of index creation
  • Three ways to create an index, delete an index

Practical documentation: thoroughly understand JVM+Linux+MySQL+Netty+Tomcat+ concurrent programming

 

3. Advanced related content of concurrent programming:

(1) Concurrent programming interview topics (Synchronized related questions)

  • Have you ever used Synchronized and what is its principle?
  • You just mentioned acquiring a lock on an object. What is this "lock"? How to determine the lock of an object?
  • What is reentrancy? Why is Synchronized a reentrant lock?
  • What optimizations has JVM made to Java's native locks?
  • Why is Synchronized an unfair lock?
  • What is lock elimination and lock coarsening?
  • Why is Synchronized a pessimistic lock? What is the principle of optimistic locking?
  • What is CAS and what are its characteristics?
  • Is optimistic locking necessarily good?

(2) ReentrantLock and other display lock related issues

  • Compared with Synchronized, how is the implementation principle of reentrant ReentrantLock different?
  • Please talk about the AQS framework
  • Please compare the similarities and differences between Synchronized and ReentrantLock in as much detail as possible
  • How does ReentrantLock achieve reentrancy?
  • Apart from ReentrantLock, what other concurrency tools in JUC have you been exposed to?
  • Please talk about ReadWriteLock and StampedLock
  • How to synchronize Java threads with each other? What synchronizers do you know about? Please introduce separately
  • CyclicBarrier and CountDownLatch look very similar, please compare

(3) Java thread pool related issues

  • How is the thread pool implemented in Java?
  • Several core construction parameters for creating thread pools
  • How are threads in the thread pool created? Was it created at the beginning with the thread pool started?
  • Since it is mentioned that different thread pools can be created by configuring different parameters, what thread pools are implemented by default in Java? Please compare their similarities and differences
  • How to submit threads in Java thread pool?

(4) Java model related issues

  • What is Java's memory model, and how do threads in Java see each other's variables?
  • Please talk about the characteristics of Volatile and why it can guarantee the visibility of variables to all threads?
  • Since Volatile can guarantee the visibility of the variables seen in the county, does it mean that operations based on Volatile variables are concurrently safe?
  • Please compare the similarities and differences between Volatile and Synchronized
  • Please talk about how RhreadLocal solves concurrency safety?
  • Many people say that you should use TheadLocal with caution. Talk about your understanding. What should you pay attention to when using TheadLocal?

Practical documentation: thoroughly understand JVM+Linux+MySQL+Netty+Tomcat+ concurrent programming

 

Four, JVM performance tuning related content

(1) JVM interview topics

  • Memory model and partition, you need to detail what to put in each area
  • Partitions in the heap: Eden, survival (from + to), old age, their own characteristics
  • Object creation method, object memory allocation, object access location
  • Two judgment methods of GC
  • What is SafePoint
  • The three collection methods of GC: the principles and characteristics of mark removal, mark sorting, and copying algorithms. Where are they used? If you are asked to optimize the collection method, what ideas do you have?
  • What are the GC collectors? Features of CMS Collector and G1 Collector
  • When do Minor GC and Full GC happen respectively?
  • Several processes of class loading
  • JVM memory is divided into several areas, what is the role of each area?
  • How to judge whether an object is alive? (or how to judge GC objects)
  • Briefly describe the java garbage collection mechanism
  • What are the methods of garbage collection in java?
  • java class loading process
  • Briefly describe the java class loading mechanism
  • Class loader parent delegation model mechanism
  • What are class loaders and what are the class loaders?
  • Briefly describe the java memory allocation and recovery strategy and Minor GC and Major GC

Practical documentation: thoroughly understand JVM+Linux+MySQL+Netty+Tomcat+ concurrent programming

 

Five, Tomcat related content

(1) Tomcat interview topics

  • What is the default port of Tomcat and how to modify it?
  • What kinds of connector operating modes (optimization) does Tomcat have?
  • How many ways to deploy Tomcat?
  • How does the Tomcat container create instances of the servlet class? What principle was used?
  • How to optimize Tomcat?
  • Memory tuning
  • Garbage collection strategy tuning
  • Shared session processing
  • Add JMS remote monitoring
  • About the number of Tomcat sessions
  • Monitor Tomcat's memory usage
  • The loading status of the printing class and the recycling status of the object
  • Tomcat complete process of a request
  • Tomcat working mode

Practical documentation: thoroughly understand JVM+Linux+MySQL+Netty+Tomcat+ concurrent programming

 

6. Design pattern interview topics

  • Please list several commonly used design patterns in JDK?
  • What is a design pattern? Have you used any design patterns in your code?
  • What is the singleton design pattern in Java? Please write a thread-safe singleton pattern in Java
  • In Java, what is the observer design pattern (observer design pattern)?
  • What are the main benefits of using the factory model? Where is it used?
  • Give a decorator design pattern implemented in Java? Does it act on the object level or the class level?
  • In Java, why is it not allowed to access non-static variables from static methods?
  • Design an ATM machine, please tell me your design ideas?
  • In Java, when do you use overloading and when do you use rewriting?
  • Give examples to illustrate when you would prefer to use abstract classes instead of interfaces?

Practical documentation: thoroughly understand JVM+Linux+MySQL+Netty+Tomcat+ concurrent programming

 

At last

In response to the above interview questions, I summarized most of the interview questions and answers involved in the Internet company java programmer interview. Documents and architecture video materials are shared for free (including Dubbo, Redis, Netty, zookeeper, Spring cloud , Distributed, high concurrency and other architecture technical materials), hope to help you review before the interview and find a good job, and also save everyone's time to search for materials on the Internet to learn.

Use every minute and every second of your time to learn to improve yourself, and don't use "no time" to hide your mental laziness! Try hard while you are young, and give your future self an explanation!

collection method:

Practical documentation: thoroughly understand JVM+Linux+MySQL+Netty+Tomcat+ concurrent programming

 

Practical documentation: thoroughly understand JVM+Linux+MySQL+Netty+Tomcat+ concurrent programming

 

Practical documentation: thoroughly understand JVM+Linux+MySQL+Netty+Tomcat+ concurrent programming

 

Guess you like

Origin blog.csdn.net/qq_46388795/article/details/109575632