To be honest, the interview summary of an 8 years Java experience man, are you afraid that you won't receive an offer?

Personal situation

Coordinate Magic City, 15 years of undergraduate graduated from a general one, worked in a traditional telecommunications company after graduation, and worked in Meituan Dianping after 17 years. Now

Interview situation

Compared to 17 years, thanks to the background of Meituan, this year's resume level has gone a lot smoothly. I have to sigh that Dachang's background is so sweet.

In line with the reason of asking for leave as little as possible, there are fewer companies interviewing, only three companies: Alibaba, NetEase, and Pinduoduo.

All three companies have gone through the interview process, and finally got offers from Ali and Pinduoduo. I am quite satisfied.

As for the reason why NetEase hangs up, the specific reason is not very clear. The interview performed well. When the BOSS met me, I was quite satisfied with me, but I didn't receive the offer in the end.

If you have questions about the interview process of these three companies, you can leave a message on the official account, and I will answer as soon as possible.

What skills should be possessed by 4 years of experience

First of all, let’s briefly talk about what skills I think a good Java programmer should possess with 4 years of experience. According to the two parts of "professional skills" and "projects", including but not limited to the following.

Professional energy saving

  • Foundation: Principles, source code, and usage scenarios of commonly used JDK classes.
  • Design patterns: several common principles, usage scenarios, singletons, dynamic agents, templates, chains of responsibility, etc.
  • Data structure: array, linked list, stack, queue, tree.
  • Network: TCP, HTTP, HTTPS, load balancing algorithm.
  • Framework: Spring IoC principle, Spring AOP principle and use, Spring commonly used extension points, MyBatis core process.
  • Middleware: The core principles and best practices of commonly used middleware, with in-depth learning of 1 to 2 of them, Redis, Kafka (RocketMQ, RabbitMQ), Dubbo, Zookeeper.
  • Database (MySQL): Index principle, isolation level, locking mechanism, sub-database and sub-table, slow SQL positioning and optimization, online problem solving.
  • Netty: NIO principle, core components, I/O multiplexing (epoll), zero copy.
  • JVM: runtime data area, garbage collection algorithm, garbage collector (CMS, G1), common configuration parameters, online problem location and resolution.
  • Stability guarantee: isolation, current limiting, fusing, degradation, etc.
  • Linux: Use basic commands, quickly locate and troubleshoot problems.
  • Distributed theory: CAP, BASE, 2PC, 3PC, TCC.

Project aspect

  • Able to independently complete the requirement analysis, scheme design and final implementation of a complex module.
  • Can keep thinking, looking for better designs and solutions, and actively optimize slow SQL and slow services.
  • Have the ability to troubleshoot problems, locate and repair online problems in time, such as: database deadlock, server downtime, frequent server Full GC, etc.
  • Have the ability to tackle difficult problems, can continuously solve the challenges encountered by the project, and give technical guidance to junior engineers.
  • Initially have the ability to lead a team (about 1-3 people), can reasonably allocate requirements, and do a good job of progress control, risk assessment, and code review.

Strictly speaking, it is a bit difficult to do the above completely, and I don't have it myself, but we can regard it as a goal and continue to work hard.

Common forms of interviews

Dachang interviews are usually in the form of a "serial gun", for example:

Interviewer: Which Maps have been used

我:LinkedHashMap、ConcurrentHashMap、HashMap、TreeMap

Interviewer: The difference between these four types of maps

Me: ConcurrentHashMap is thread-safe, LinkedHashMap can record insertion order and access order, TreeMap can customize sorting, except for these scenarios, other scenarios can basically use HashMap

Interviewer: How does ConcurrentHashMap ensure thread safety

Me: Segmented lock was passed before JDK 1.8, and CAS + Synchronized after JDK 1.8

Interviewer: What is the difference between the locks of ConcurrentHashMap before and after JDK 1.8

Me: Before JDK 1.8 locks segmentation, after JDK 1.8 locks a single node, the lock granularity is reduced, and the concurrency becomes higher.

Interviewer: #%¥%……#%¥

Me: Meow meow~

The questioning method of this model is actually to understand whether the candidate's understanding of a knowledge point is only on the surface, or whether it has really been studied in depth.

Interview content

Here are some common interview content. The interview questions may not be what I actually encountered. They may be collected from other people's interview questions, or they may be knowledge points that I think are important, for reference only.

1. Project

The project is very important for a development with 3-5 years of experience, and the interviewer also values ​​this one very much. The development of this experience is basically the main coding force of major companies, so when interviewing candidates of this age, the project is usually a very important piece. The interviewer usually asks you to introduce yourself the most involved (or most powerful) project, and then ask questions from it. The common ones are as follows:

  • Introduce your most involved projects
  • Draw the architecture diagram of the project
  • If the core process is halfway through and the server crashes, what will happen?
  • What challenges or problems have been encountered in the project and how to solve them
  • How to ensure the stability and availability of the project
  • How to design data security
  • The technical selection of the project, why choose these
  • ...

2. Scenario questions

The more interviewers at the back, the more they like to ask scene questions, which test the candidates' usual accumulation and problem-solving ability. This link is easy to kill a group of people, especially the students who are easily nervous, and it is easy to lose their minds. The core of the scenario question is generally to deal with the problem of large data volume and solve the problem of performance.

Scenario questions are relatively open in nature, and there is no standard answer. As long as your own solution can solve the problem, you can "justify yourself".

In this session, the interviewer may ask questions about real online scenes, which I have encountered myself.

3. Professional skills

set

  • Which maps are often used
  • The difference between these types of maps
  • How does CocurrentHashMap ensure thread safety
  • What is the difference between the locks of CocurrentHashMap before and after JDK 1.8
  • Talk about the principle of HashMap
  • When HashMap is Put, whether the new linked list node is placed at the head or tail
  • The process of HashMap expansion
  • What is the change of HashMap in JDK 1.8
  • What has changed in CocurrentHashMap in JDK 1.8
  • Principle of TreeMap
  • Map, List, Set, respectively, talk about thread-safe classes and thread-unsafe classes you know

Multithreading, lock

  • Which thread pool is used
  • How to configure thread pool parameters
  • The role of each parameter of the thread pool
  • What to pay attention to in the parameter configuration of the thread pool
  • Thread pool workflow
  • What do the concurrency classes in the JDK know
  • The underlying principle of AQS
  • Introduce pessimistic lock and optimistic lock
  • Which locks have been used
  • The difference and usage scenarios of synchronized and Lock
  • synchronized principle
  • Synchronized acts on the difference between static methods, ordinary methods, this, Lock.class
  • Why introduce biased locks, lightweight locks, and introduce the upgrade process
  • The necessary conditions for deadlock, how to prevent deadlock
  • Introduce CountDownLatch and CyclicBarrier
  • Introduce CAS, what's the problem
  • Introduce ThreadLocal, what are the problems

The internet

  • How is HTTPS encrypted
  • The principle of ordinary hash and consistent hash
  • Disadvantages of consistent hash
  • TCP three-way handshake process, why do we need three-way handshake
  • Why does the TIME_WAIT state need to go through 2MSL to return to the CLOSE state
  • TCP congestion control
  • How does TCP solve the problem of flow control, disorder, and packet loss
  • Why does sticking and unpacking occur, and how to solve it

Spring、Mybatis

  • The difference between # and $ in Mybatis
  • How to prevent SQL injection
  • When using Mybatis, how to call SQL when calling DAO (Mapper) interface
  • Introduce the process of Spring IoC
  • The difference between BeanFactory and FactoryBean
  • How is Spring's AOP implemented
  • What are Spring's transaction propagation behaviors? Let's talk about nested transactions
  • Under what circumstances the object cannot be proxied
  • How does Spring solve the problem of circular dependencies
  • How to implement some logic after the Spring IoC container is built
  • The difference between @Resource and @Autowire
  • @Autowire how to use name to inject
  • Is there a problem if other bean instances are used in the method specified by the bean’s init-method attribute?
  • Is there a problem if other bean instances are used in the method modified by @PostConstruct?
  • In Spring, if there are two beans with the same id, will an error be reported? If an error will be reported, at which stage the error will be reported
  • In Spring, the bean's class attribute specifies a class that does not exist. Will an error be reported? If an error occurs, at which stage
  • What are the common extension points in Spring

MySQL

  • Data structure of MySQL index
  • Why use B+ tree and what are the advantages compared to other indexes
  • The difference between various indexes
  • How to deal with B+ tree during range search
  • What is stored in MySQL index leaf nodes
  • The underlying implementation of the joint index (composite index)
  • How MySQL locks a row of data
  • Can a mutex lock be added to a SELECT statement?
  • Multiple transactions SELECT FOR UPDATE on a row of data at the same time will block or be abnormal
  • MySQL version and execution engine
  • The difference between different MySQL execution engines
  • MySQL transaction isolation level
  • How MySQL's Repeatable Reading Is Realized
  • Will there be phantom reads in MySQL
  • MySQL gap lock
  • MySQL's master-slave synchronization principle
  • Implementation scheme of sub-database and sub-table
  • Distributed unique ID scheme
  • How to optimize slow queries
  • The meaning of each field in explain
  • What are the common values ​​of the type field in explain
  • Which fields do you usually pay attention to in explain and why

JVM

  • Runtime data area
  • What garbage collector is used by the server
  • The principle of CMS garbage collection
  • The characteristics of G1 garbage collection, why low latency
  • What are the garbage collection algorithms, advantages and disadvantages
  • Which objects can be used as GC Roots
  • What class loaders are there
  • Parental delegation model, which scenarios are to break the parental delegation model
  • How to troubleshoot the frequent occurrence of Full GC on the online server
  • What commands are commonly used to locate problems
  • Introduce the process of JVM tuning

Kafka

  • Why use Kafka
  • Introduce the various components of Kafka
  • How to ensure that the data written to Kafka is not lost
  • How to ensure that the data consumed from Kafka is not lost
  • Why is Kafka so high?
  • Which method is used to achieve zero-copy technology
  • There is a similar zero-copy technology in Java, which method is it?
  • How does Kafka guarantee the sequential consumption of messages
  • How to avoid repeated consumption in Kafka
  • What is HighWatermark and LEO
  • What is ISR and why do I need to introduce ISR

Redis

  • Redis version used in the project
  • Redis usage scenarios in the project
  • How does Redis ensure high availability
  • Redis election process
  • The difference between Redis and Memcache
  • Redis cluster mode
  • Redis cluster needs to increase shards, how to ensure lossless slot migration
  • Implementation of Redis distributed lock
  • Redis delete expired key strategy
  • Redis's memory elimination strategy
  • Redis's Hash object underlying structure
  • The expansion process of Hash objects in Redis
  • Will there be any problems with the expansion process of Redis's Hash object when the amount of data is large?
  • What are the persistence mechanisms of Redis
  • The realization principle, advantages and disadvantages of RDB and AOF
  • AOF rewriting process
  • Principles of Sentinel Mode
  • When using the cache, whether to operate the database first or operate the cache first
  • Why invalidate the cache instead of updating the cache
  • Cache penetration, cache breakdown, cache avalanche
  • Several design patterns for updating the cache

Zookeeper

  • Usage scenarios of Zookeeper
  • How does Zookeeper implement distributed locks
  • How does Zookeeper ensure data consistency
  • Principle of ZAB Agreement
  • Which of the CAPs does Zookeeper follow
  • The difference between Zookeeper and Eureka
  • Leader election for Zookeeper
  • The role of Observer
  • The leader sent a commit message, but none of the followers received this message, and the leader hung up. What will happen next?

distributed

  • CAP theory
  • BASE theory
  • Principles of Distributed Transaction 2PC and TCC
  • What to do if TCC fails in the cancel phase
  • Paxos algorithm, Raft algorithm

4. Hr surface

If you pass five levels and cut six generals all the way, and finally come to the Hr side, then congratulations, you are very, very close to the offer. You can start to imagine yourself getting promoted and raising your salary, becoming a general manager, becoming a CEO, marrying Bai Fumei, and embarking on the scene of the pinnacle of life.

The HR interview is mainly to understand some general qualities of the candidate, and the frequently asked questions are as follows:

  • Introduce the project that I invested the most in (I was shocked at the time, Hr also started to ask about the project)
  • Reason for leaving
  • Current salary, performance
  • The situation of other companies currently interviewing
  • Do you usually have the habit of studying, how did you study, what are you studying now
  • Future plan

There are no standard answers to these questions, but the very important principle is to maintain a positive attitude and not have negative emotions throughout the process.

Regarding the current salary issue, due to many reasons, some people may want to report a little bit more. I am neutral on this approach, but we must grasp the degree. After all, big factories basically have background checks. Big companies generally have zero tolerance for integrity issues, and may blacklist them. Being on the blacklist means you will never get involved with this company anymore.

Some experience

  1. First, choose a few small companies to find the interview feeling. I haven't met for a long time. I need to find the interview feeling. I didn't meet well at the beginning, and I was very flustered.
  2. It’s normal to be nervous during an interview, but don’t be too nervous. If your brain is blank after the interviewer asks, you can tell the interviewer that you want to think, and then you can speak slowly, but be organized and clear.
  3. Answering the interviewer’s questions during the interview is one aspect; on the other hand, you have to let the interviewer feel some of your outstanding qualities in the process of answering, such as potential, flexibility, love of learning, and strong learning ability. , Strong problem-solving ability, solid foundation, etc. These qualities will affect the interviewer's evaluation of you.
  4. You must actively solve the problems encountered in the project. The process of solving the problems can make people grow quickly, and the solved problems may become the highlights of your interview, especially for those projects that have no highlights.
  5. When preparing the project, pick a few of the most powerful functions that you have done or solved the most challenging problems, and you must have a thorough understanding of these content, and you should not "stagger" when introducing them to the interviewer.
  6. Regardless of the framework or middleware, there must be a few that have been specially studied in depth, which means that in addition to the "breadth", you must also have enough "depth" in some aspects. The question often encountered during interviews is: Which framework or middleware do you have the deepest understanding. Then the interviewer will keep asking in this direction. If you just read a lot of things in general, you will most likely be asked here.
  7. Every function point and knowledge point that you speak out must be prepared to be "challenged", so you must think more about each function point and knowledge point.
  8. If the question asked is an actual online scenario, sometimes the interviewer will give their current online solutions. If you can give some of your own thoughts and opinions at this time, you may leave a good job for the interviewer impression.
  9. A relatively simple and rude way to judge whether you have prepared: can you answer about 90% of the interview questions you see, such as the questions listed in the " professional skills " above in this article .
  10. If you really want to quit, or if you have already resigned naked, then don't stop the interview before receiving the electronic offer, even if the oral offer is not stable, especially in this cold winter.
  11. In daily work, think more about better solutions, whether it is writing code or program design. Especially after working years longer, thinking is more important to our career development.
  12. Preparation before the interview is very important, but what is more important is the accumulation of usual work. Many of the questions asked by 4 years of experience cannot pass temporary preparation. Many of them require you to continue to accumulate in order to have a good plan.
  13. Focus on your own growth and don't be easily influenced by others. As long as you keep accumulating, one day you can become the great god in your eyes.
  14. Learning is like rowing upstream. Don't stop learning, especially when you are still young, and when you are still a single dog, force yourself. In the future, you will be grateful for your hard work now.
  15. The programmer is a very simple job, no need to do any bells and whistles, as long as you put in the effort, you can usually reap the rewards.
  16. For those who don’t have a big factory background and are in a traditional industry (like me 2 years ago), it is more difficult to enter a big factory directly, unless you step on shit luck like me, but this kind of chance is not high, I think it is more realistic The way is to find an Internet unicorn to settle for a period of time.
  17. There are many departments in large companies, and the recruitment of each department is usually independent. If you want to enter a large company, you can invest more. Each department has a different degree of demand. If you encounter an urgent need to recruit, it may be a very good opportunity .
  18. Interviews at large companies are usually archived, and the interviewer may see your previous interview evaluations. If you often take a round trip, you will definitely give the interviewer a bad impression. So please be prepared before going to the interview and don't waste the opportunity easily.
  19. The market situation of the Internet industry in 2019 is not very good, and it may continue to be like this in the future, especially for students who do not have a background in major factories, so please remember a very important principle: Don't say nothing .

In response to the above frequently asked technical points in interviews with major companies, I have specially compiled a set of corresponding Java interface pdf document review materials, which cover a wide range of content, and are especially suitable for some Java developers who are about to interview or are about to change jobs. To fix the leaks, readers who need to obtain this set of documents

If you need to get it, it’s troublesome one-click triple-link + comment, and then add VX (tkzl6666) to get it for free

 

The interview summary of a 4-year Java-experienced man, still afraid of not receiving an offer?

 

The interview summary of a 4-year Java-experienced man, still afraid of not receiving an offer?

 

The interview summary of a 4-year Java-experienced man, still afraid of not receiving an offer?

 

The big guys who think this article is good can help forward and share it, hoping to help more coders who are preparing for the interview, thank you! ! !

Guess you like

Origin blog.csdn.net/JavaBUGa/article/details/115177588