preface

It has been nearly three years since I graduated in 2015. Recently, I interviewed with Ali Group (Cainiao network, Ant Financial), netease, Didi and Dianwuda. Finally, I received offers from Dianwuda and netease.

Finally, I had the honor to go to netease.

However, I would like to thank the leadership and HR of Dianweda for their great care and guidance.

Interview overview

  • Your resume should be prepared, your contact information should be correct, clear and eye-catching, your project experience should be explained in reverse chronological order, your responsibilities in the project should be noted, and your resume template should be concise as far as possible, after all, most programmers prefer simple and clear.
  • Recommend boss direct hire, I feel very easy to use (not advertising).
  • The general overall interview process is phone -> live ->HR -> wait.
  • They also need to discuss it with your previous interviewers and report it to your boss. If you are not in a hurry, you may have to compare yourself with other candidates. So the fact that they ask you to go back and wait for news is definitely not a sign that you are finished.
  • Prepare to introduce yourself before the interview, about 1 minute can, can write on paper, the phone can read, and when you arrive at the scene of the basic also quickly recite your introduction.
  • Prepare a solid foundation, this is the root of everything, no strength how are useless.
  • During the interview, you can steer your interviewer toward what you know (I’ve met people who don’t ask what you know).
  • Don’t worry when it comes to design questions. The interviewer is not asking you to design a perfect architecture with a high concurrency and high availability design pattern in a few minutes. The interviewer is just trying to see how you think, see how adaptable you are, and give you some hints to see if you can adapt quickly.
  • Don’t rush into the interview as a communication process.

Knowledge that needs to be prepared

Here are more impression in the interview in the near future, also won’t be the branch, because there is little meaning, roughly classified records, only think of so many, but must know that these problems are just the tip of the iceberg, even if will also not how, the most important, or a solid foundation, a clear head.

By the way, I recommend a wechat official account: Java Architecture Technology Stack, which will share some videos from the primary to the advanced Java architecture: Spring, MyBatis, Netty source code analysis, high concurrency, high performance, distributed, microservice architecture principles, JVM performance optimization has become an architect’s essential knowledge system. Also can receive free learning resources and predecessors of the interview experience and questions, I believe that for those who have worked and encountered technical bottlenecks, there will be content you need in this group.

Java based

  1. HashMap source code, implementation principle, JDK8 to do HashMap optimization.
  2. How to expand HaspMap? Why are the sizes of 2 to the NTH power?
  3. HashMap, HashTable, ConcurrentHashMap.
  4. Does HashTable or ConcurrentHashMap perform better in extremely high concurrency, why and how?
  5. What are the security implications of HashMap without handling thread safety in high concurrency?
  6. The limits of the four modifiers in Java.
  7. A method in the Object class.
  8. The difference between an interface and an abstract class. Note that interfaces in JDK8 can have implementations.
  9. Two ways of dynamic proxy, and the differences.
  10. The way Java serializes.
  11. The difference between passing a value and passing a reference, what Java looks like, with or without passing a value reference.
  12. If an ArrayList is deleted during the loop, is there a problem? Why?
  13. When does the @Transactional annotation fail and why?

Data structures and algorithms

  1. B + tree
  2. Quicksort, heap sort, insert sort (in fact, eight sorting algorithms should understand
  3. Consistent Hash algorithm and application of the consistent Hash algorithm

JVM

  1. Memory structure of the JVM.
  2. How the JVM method stack works, and how the method stack differs from the native method stack.
  3. How JVM stack references relate to objects in the heap.
  4. Look at escape analysis techniques.
  5. The common algorithm of GC, the garbage collection process of CMS and G1, which two Stop the world in each stage of CMS, whether CMS will generate fragments, and the advantages of G1.
  6. Understanding and advantages and disadvantages of tag clearing and tag collation algorithms.
  7. Eden Survivor area ratio, why this ratio, Eden survivor work process.
  8. How the JVM determines whether an object should be GC, and what types of objects can be considered root.
  9. The difference between strong and weak virtual references and what the GC does to them.
  10. Whether Java can GC direct memory.
  11. The process of loading Java classes.
  12. The process and advantages of parental delegation models.
  13. Common JVM tuning parameters.
  14. Analysis of dump files.
  15. Does Java have an active way to trigger GC (none)?

multithreading

  1. There are several ways to implement multithreading in Java.
  2. Understanding Callable and Future.
  3. What are the parameters of the thread pool, the process of creating a thread in the thread pool.
  4. Volitile keyword function, principle.
  5. Use of the synchronized keyword, advantages and disadvantages.
  6. What are the implementation classes of the Lock interface and what are the usage scenarios?
  7. Use of reentrant locking and its implementation principle, the process of copying while writing, read/write locking, and segment locking (ConcurrentHashMap segment).
  8. Pessimistic lock, optimistic lock, advantages and disadvantages, CAS defects, how to solve.
  9. ABC how three threads ensure sequential execution.
  10. What are the states of threads?
  11. The difference between “sleep” and “wait”.
  12. The difference between notify and notifyAll.
  13. Understanding ThreadLocal, implementation principles.

Database correlation

  1. Common database optimization methods
  2. The pros and cons of indexes. What fields should be indexed on
  3. Database connection pool.
  4. Common configurations for durID.

Computer network

  1. TCP and UDP are different.
  2. Three handshakes, four waves? Why four waves.
  3. Long connection and short connection.
  4. Is the connection pool suitable for long or short connections?

Design patterns

  1. Observer model
  2. The proxy pattern
  3. Singleton pattern, there are five ways to write, you can refer to the article singleton pattern five ways to implement
  4. You can see which design patterns are used in Spring

Distributed correlation

  1. Control of distributed transactions.
  2. How to design distributed locks.
  3. How to design distributed sessions.
  4. What are the components of Dubbo and what are their functions?
  5. What are the load balancing algorithms used by ZooKeeper?
  6. How Dubbo can communicate using interfaces.

Cache related

  1. The difference between Redis and memcached
  2. What data structures redis supports.
  3. Is Redis single threaded? Is all work single threaded?
  4. How redis stores a String.
  5. Redis deployment mode, master/slave, cluster.
  6. Redis sentinel mode, how a key value is found in a Redis cluster where it is stored.
  7. Redis persistence strategy.

The framework related

  1. How SpringMVC’s Controller matches parameters to data coming from the front end.
  2. Mybatis how to find the specified Mapper, how to complete the query.
  3. How Quartz completes timed tasks.
  4. Implementation of custom annotations.
  5. What design patterns Spring uses.
  6. What are the advantages of Spring’s IOC?
  7. How Spring maintains the beans it owns.
  8. Something newer
  9. New features of JDK8, flow concepts and advantages, and why.
  10. Understanding blockchain
  11. How to design double 11 transaction total panel, to achieve high concurrency and high availability.

Some tips

  1. You can go to Leetcode and brush up on it for a change.
  2. Eight sorting algorithms must be hand knocked over (fast row, heap row is especially important).
  3. Learn about emerging technologies.
  4. After the interview, the interviewer will ask you if you have any questions. Don’t be ok and don’t be silly to ask sensitive questions.
  5. Learn about the company’s products and competitive products.

conclusion

No matter which company it is, they are very focused on high-concurrency, high-availability technologies, they are focused on infrastructure, they are focused on JVMS. The interview is a two-way selection process, do not hold the mentality of fear to interview, is not conducive to their own play. It’s not just the salary you’re looking for, it’s whether you really like the company and whether you’re getting a real workout. In fact, I have written so much, just my own summary, not necessarily applicable to everyone, I believe that after some interviews, you will have these feelings.

If these words can help you, that is the best, can not help as a record of my own.