The most "hot" Java social recruitment interview experience sharing (40 interview questions in total)

Interview time: October 12, 2020

Insert picture description here

1. The difference between final finally finalize

2. The role of the synchronized keyword and when to use it, other locks in the concurrent package.

3. Have you ever encountered a deadlock problem? (The principle and solution of deadlock)

4. The realization principle of hashmap, the difference between hashmap and hashtable

5. Sub-database and sub-table optimization

6. Generation of unique ID in distributed system (sequential ID needs to use distributed lock, optimization of sequential ID, non-sequential ID)

7. How to ensure data consistency in distributed systems

8. Implementation method of distributed lock

9. Redis memory model and why the performance is so good (memory database, IO multiplexing)

10. Zookeeper is the process of saving data (you need to know the election algorithm)

11. Seven-layer/five-layer architecture, which layer is the router, and which layer is the various protocols such as tcp http

12. The process of tcp connection establishment and disconnection process

13. After the second wave of hands, what will the server do when a large number of packages are sent to the server?

14. Java's IO model

15. Java memory model, the role of the volatile keyword

16. Why elasticSearch searches faster

17. The underlying storage method of hbase and hive

18. The life cycle of spring bean, the difference between BeanFactory and ApplicationContext

19. The realization principle of spring aop (what types of agents are there and what is the default agent)

20. The process of mybatis converting query results into classes

21. What are the benefits of springboot or springioc

22. JVM garbage collector (not garbage collection algorithm), what is the garbage collector used in your project

23, multi-threaded communication

24. The realization principle of threadlocal, precautions and usage scenarios

25. What new technologies have you paid attention to (new features of jdk1.8 are generally asked) or open source projects, and what open source codes have you seen

26. How does the message middleware implement remote calls?

27. The principle of thread pool implementation, several important parameters of thread pool, if the thread pool reaches the maximum number, what will happen to new tasks submitted subsequently

28. Configuration and optimization of the number of tomcat threads (io-intensive, cpu-intensive, pressure test)

29. Why did you choose kafka (the characteristics of kafka)? If you ask more deeply, you will ask about the kafka isr mechanism and partition election

30. What impressive problems have you encountered in the project, or things with a sense of accomplishment?

31. mysql index optimization, index storage structure, execution plan

32. Redis data persistence mechanism, what data structure does redis have

33. The concept of CAP, analyze which types of kakfa or other databases are

34. What is CAS

35.Have you used the spring prototype mode?

36.How does spring singleton mode achieve thread safety

37. What kind of code is good code

Programming questions:

1. There are 9 apples in total, there are 2 monkeys, one monkey takes 2 apples at a time, and one monkey takes 3 apples at a time. If the remaining apples are not enough for the monkeys to take each time, the 2 monkeys stop taking apples. Please use java multithreading to simulate the above description.

2. The number is reversed.

3. Tree traversal.

Design questions:

The A system and the B system need to interact, and the A system needs to update a large amount of data in the B system, but the update fails. What is the solution?

At last

In view of the fact that many people have been interviewing recently, I have also compiled a lot of interview topic materials here, as well as experience from other major companies. Hope it helps everyone.

Insert picture description here

The answers to the above interview questions are organized into document notes. I also sorted out some interview materials & the latest interview questions collected by some big companies in 2020 (all organized into documents, a small part of the screenshots), if necessary, you can click to enter the password: csdn

Insert picture description here

The above is the whole content of this article, I hope it will be helpful to everyone's study, and I hope you can support it. One-click three consecutive!

Guess you like

Origin blog.csdn.net/qq_41770757/article/details/109038253