Last month, because I was a little dissatisfied with the current job, I just resigned and quit. I voted for an interview with Ali P7-level architect. I thought I was well prepared and I wanted to take the four years of work experience. There shouldn't be much problem with Ali's P7. I didn't expect that I was stuck on the third side when I was interviewed. It was because of Mysql, which I usually excel at. Finally missed it.
Alibaba 4 core interview questions
01 Zookeeper section
- CAP theorem
- ZAB agreement
- Leader election algorithm and process
02 Redis section
- Application scenarios of Redis
- Data types supported by Redis (required)
- The data structure of zset jump table (required)
- Redis data expiration strategy (required)
- The specific implementation of Redis's LRU expiration strategy
- How to solve the Redis cache avalanche and cache penetration problems
- Redis persistence mechanism (required)
- Redis pipeline
03 JVM part
- Runtime data area (memory model)
- Garbage collection mechanism
- Garbage collection algorithm
- Minor GC and Full GC trigger conditions
- GC中Stop the world
- The characteristics and differences of each garbage collector
- Parental Delegation Model
- Relationship between JDBC and Parental Delegation Model
04 Java basic part
- The difference between HashMap and ConcurrentHashMap
- Data structure of ConcurrentHashMap
- How does the high-concurrency HashMap ring come into being?
- Volatile role
- How does the Atomic class ensure atomicity (CAS operation)
- The difference between synchronized and Lock
- Why use thread pool?
- Parameters of the core thread pool ThreadPoolExecutor
- ThreadPoolExecutor workflow
- How to control the priority of thread pool threads
- How to communicate between threads
- Boolean takes up a few bytes
- What new features are added in jdk1.8/jdk1.7?
- Exception和Error
05 Spring section
- Implementation of Spring's IOC/AOP
- Realization of dynamic proxy
- How does Spring solve circular dependencies (three-level cache)
- Spring's post processor
- How is Spring @Transactional implemented?
- Spring's transaction propagation level
- The connection and difference between BeanFactory and ApplicationContext
06 Other parts
- How to realize the current limit of high concurrent system?
- The design of high concurrency spike system
- How to design load balancing?
I believe some of my friends can answer these questions, so let's take a look at the MySQL-related questions that stuck me!
07 Mysql section
- Basic elements of business
- Transaction isolation level
- How to solve the problem of transaction concurrency (dirty read, phantom read)?
- MVCC multi-version concurrency control?
- What are binlog, redolog, and undolog, and what are their functions?
- InnoDB row lock/table lock?
- The difference between myisam and innodb, when to choose myisam?
- Why choose B+ tree as the index structure?
- What can be stored in the leaf nodes of the index B+ tree?
- When does the query not go to the (expected) index?
- How to optimize sql?
- How does explain parse sql?
- Principle of order by
Do you know these questions? I want to go far on the road of programmers and do well. Mastering these is far from enough, because MySQL contains too many problems and knowledge, and it is an open source relational database management system that programmers must master. If you want to learn database well, you can learn MySQL well first, because you will learn most of other databases well.
So how can we learn MySQL thoroughly? After the interview failed, the editor was fortunate to get a tuning note compiled by him recommended by a friend of the senior architect of JD T8. It is with it and the previous efforts that he successfully won the offer and successfully cut it. Next P7.
The following editor will share this perfect MySQL tuning note with everyone, hoping to help friends in need.
The notes are divided into 2 subsections, namely:
- Performance tuning
- Architecture design
Performance tuning
Factors affecting MySQLServer performance
- The impact of business requirements on performance
- The impact of system architecture and implementation on performance
- The impact of Query statement on system performance
- Schema design affects system performance
- The impact of hardware environment on system performance
MySQL database locking mechanism
- Introduction to MySQL Locking Mechanism
- Analysis of various locking mechanisms
- Reasonable use of lock mechanism to optimize MySQL
Optimization of MySQL database query
- Parse MySQL's QueryOptimizer
- Basic ideas and principles of Query statement optimization
- Make the most of Explain and Profiling
- Design and use indexes appropriately
- The realization principle and optimization ideas of Join
- ORDERBY , GROUPBY and DISTINCT optimization
Schema design performance optimization ideas
- Build efficient model design
- Use the right data type
- Canonical object naming
MySQLServer performance optimization
MySQL installation optimization
Log setting optimization
QueryCache optimization
Server other common optimizations
Common storage engine optimization
MyISAM storage engine optimization
Innodb storage engine optimization
Architecture design
Basic principles of scalable design
- Scalability
- Principle of Minimizing Transaction Relevance
- Data consistency principle
- High availability and data security principles
MySQLReplication scalability design
- The significance of Replication for scalability design
- The realization principle of Replication mechanism
- Replication thread
- Copy implementation level
Data segmentation
- Vertical segmentation of data
- Horizontal segmentation of data
- Vertical and horizontal joint segmentation using
- Data segmentation and integration solution
- Possible problems in data segmentation and integration
Analyze the use of Cache and Search
- Extend beyond the database of scalable design
- Reasonable use of third-party Cache solutions
- Implement Cache service by yourself
- Use Search to achieve efficient full-text search
- Using distributed parallel computing to achieve high-performance computing with large amounts of data
Deep understanding of MySQLCluster
- MySQL Cluster environment setup
- Basic management and maintenance of MySQL Cluster
- Basic optimization ideas
Ideas and solutions for high-availability design
- Use Replication to achieve high availability architecture
- Master-Slave solves the basic master-slave design
- Master single point problem solving
- Use DRBD to ensure high data security and reliability
- Other high-availability design solutions
- Comparison of the pros and cons of various high-availability solutions
MySQL monitoring design
- Monitoring system design
- Performance status monitoring
Concluding remarks
Data storage is a topic that every IT programmer can't get around, and MySQL, as a leading product, is also the only way for our technology to advance. Have you played with it? Regardless of whether you are in a proficient or ignorant state, I hope you can adjust your mentality and embark on the road of learning. For programmers, if you want to grow into a big cow in the industry, the only thing is The way is to continuously improve their skills and broaden their knowledge through learning to reach a certain height and depth. Finally, I wish everyone can win their favorite offers and do their favorite jobs! Don't forget to "add me VX assistant" after one-click three consecutive times to take away your study notes for free.