These interview questions were shared by my fellow readers, which was very impressive. I had 2 years of experience in the interview and got N offers in a few months, including the first and second tier companies such as Didi, Youzan and Ali.
The content is completely from the readers themselves, the quoted part is the readers’ own answer description, thanks for sharing. Ali’s is at the end.
Cool music,
- Redis cluster use, how to handle the outage
- How to split data in mysql database
- Mysql index knowledge and optimization experience
- Zk data synchronization, crash recovery
- Docker K8s usually uses the package command
- The difference between Docker and virtual machine
- The volatile and synchronize keywords
- A hashMap features
- Node synchronization between Zk locks
Let the science and technology
One side
-
Use of Redis clusters in business
-
Mysql index, results of explain commands
-
Scenario Problem: The number of production logs is 10 GB every day. How do I prevent the number of production logs from reaching all disks?
-
Scenario problem: Design menus and function permissions for different user roles.
-
Knowledge of local memory. Scenario: How to update the local memory in all the machines in the cluster.
I answered rocketMQ’s broadcast mode
Second interview
-
Scenario QUESTION: How can a large number of HTTP requests identify customers
Create user labels based on IP addresses and user behaviors.
Cooperate with operators such as Telecom and Mobile to directly obtain user information based on mobile phone numbers
-
Logs distinguish between production and online
Flag recognition (timestamp or IP)
-
The Reactor model, and the essential differences between it and structure-oriented programming
-
The JVM tuning experience and garbage collection
-
An understanding of common utility classes under synchronized locks and Concurrent packages.
-
Scenario problem: How to design a highly concurrent application, from monomer to distributed system process.
flush
One side
- Experience in project
- Redis data sharding mechanism
- Look at the books and introduce the impressive ones
- Write a thread-safe queue using a list.
Second interview
-
Introduce the project highlights, pain points and the process of solving them.
-
How to resolve distributed transactions? Is there any loss of messages using RocketMQ? How to compensate
-
Business data model, how to abstract table structure when designing.
-
Is it reasonable to use optimistic locks to shift the pressure to mysql
-
How to deal with link tracing between microservices, traceId, and big data log collection
-
Redis cache penetration, breakdown, avalanche how to handle, Bloom filter
-
The reason for redis single thread efficiency
Redis multiplexing
-
Netty’s REACTOR model
-
Traffic limiting strategy, Sentinel understanding
-
Inadequacy in the job, how to make up for?
Suitable abundant science and technology
One side
-
The embodiment of the complexity of the project and the design pattern used, downstream service recognition, order system open order logic.
-
Distributed locking, inventory checking and inventory reduction atomicity
-
Distributed transactions, transaction consistency of orders and inventory
-
Data synchronization between multiple systems, publish subscriptions, initialize data, and increment binglog synchronization.
-
How to synchronize incremental data except binglog?
You can query data whose version is larger than your own each time by pulling the update data based on the version number.
-
Spring IOC, AOP
-
When is AOP loaded, and how does the container load beans
-
How does Spring level 3 cache solve loop dependencies
-
Mybatis interceptor dynamic proxy base how to find XML, how to execute SQL
-
How to query the express order of a certain user (the user may be either the recipient or the sender)
Where addressee =xx or sender =xx
Use union or union all query to create composite index
-
Knowledge of Agile development
-
What books have you read recently and why you quit
Second interview
-
Description of project architecture, design of database table structure
-
How to limit traffic at the gateway layer
Funnel, token bucket, sliding Window (Sentinel)
-
RMQ ensures transaction consistency
-
Redis cluster
-
Algorithm: A tree, each node may have multiple child nodes, describes this data structure and traverses it
The first approach is to describe child node attributes as collections: List childen; The recursive traversal
The second idea: as a deformed binary tree, the left subtree is a part of a single node, and the right subtree is a big tree, so the traversal is also recursive and the complexity is very high.
Have a great
One side
- Experience in project
- Garbage collection algorithm, understanding of CMS
- The difference between initial and concurrent tags
- Spring related
- redis MySQL RMQ
- The use of sub-database sub-table
- The JVM lock
- Hashmap1.7 and 1.8 special effects, 1.8 is thread safe
- chm
- Epoll Poll Select The distinguishing file descriptor
Second interview
- The business scenario
- Redis distributed lock
- Distributed transaction
- rocketmq
Blackbird technology
One side
- Sentinel combined with Dubbo for current limiting
- How to implement singletons, how to break singletons
Second interview
- The thread pool
- Class loading mechanism, which objects are loaded separately
- Which class loader is loaded by Tomcat
- JVM memory model
- Garbage collection algorithm, CMS, three-color labeling
- The JVM tuning
- Distributed ID generation algorithm
- Second kill scene design, solve the oversold design
- MySQL index design,
select * from table where a=1,b= 1 and c>2 and d=3 order by e
How to create index - How to implement redis distributed lock
Ali group
One side
- Multiple designs for distributed locks
- Mysql database table
- Second kill design
- DDD domain design
- A common solution for distributed transactions
- Redis cluster
- A hashMap, CHM
- Characteristics of transactions
Second interview
- Business scenario 50 minutes, deep dig business design, database model design, design defects and alternative design scheme.
- Mysql index optimization, isolation level, MVCC, redo, and binglog write timing, synchronization mechanism.
- JVM Optimization Experience
- The depth of the rocketmq
- The volatile and the synchronize
- Dubbo process, symmetric and asymmetric encryption, SPI, load balancing algorithm
- Algorithm leetcode randomly selected a problem, do not need to pass the operation, almost no card
On three sides
Pure business understanding and industry domain knowledge 50 minutes
All around
-
The value of the project, what you did in the job, what you did
-
How to implement a chat client
-
Design a RPC framework, dubbo how to use threads to achieve synchronous call, specific need several threads
Could not answer
-
Read books, harvest, personal career planning and so on
conclusion
After two years, I feel it is not very difficult to ask questions. It is a knowledge overview to have a look at the things I want to enter the big factory. Then dachang will ask more in-depth about each knowledge. If you want to read more books at ordinary times, you can also look at the various articles of geek time.
Project experience is very important. It is generally required for large factories to have done these things and be able to summarize the content and difficulties of the project in the core business of each middle stage, such as trading commodity marketing and payment.
In fact, I have written almost 90% of these questions. Follow my reply [PDF] to get the interview guide.
The second version of PDF has not been updated yet. If you want to see all the articles, you can check the article under the tag of interview daqo, or follow me on Github. I will update the MD file of the article at the address:Github.com/irwinai/Jav…