Author: last night, huanghua Wolf today www.cnblogs.com/xueSpring/p…

Although Tmall, Ant Financial and Cainiao are all affiliated to Alibaba, each interviewer asks different questions, and the similarities are mainly in terms of process.

At the beginning of the interview, I will introduce myself, including the main business structure and technical structure. Business architecture is usually not very in-depth, but it should be understood by the interviewer, and the interviewer will usually follow up by asking how the technical architecture is designed around these businesses.

The following is from the network organized rookie, Tmall, ant Financial service interview questions, only for your reference, no answer!

Java

1. Multiple threads are reading and writing at the same time, and the number of reading threads is much larger than that of writing threads. How do you think to solve the concurrency problem? What kind of lock would you choose?

2. Have you understood the AQS of JAVA and what it does?

3. Besides synchronized, what do you do to ensure thread safety?

4. When should volatile be used? Is it thread-safe?

5. What happens if all threads in the thread pool are busy and submit a new task? What happens when the queue is full and still busy?

6. How do you normally adjust the parameters of Tomcat?

7. What does synchronized lock? How is it represented in bytecode? What is represented on an in-memory object?

8. Do wait/notify/notifyAll methods need to be included in a synchronized block? Why is that?

How do you usually use the ExecutorService? One per service or one per project? What are the benefits?

Spring

1. Have you used Spring AOP? What is it for? How might it be used?

2. If an interface has two different implementations, how do you Autowire a given implementation?

3. Where do Spring’s declarative Transaction @Transaction annotations go? Does it roll back automatically if an exception is thrown? Is there a way to control not to trigger a rollback?

4. If you want to execute your own logic after a Bean is generated and assembled, how can you do that?

5. Why can SpringBoot run HTTP services when it is not in the Web container?

6. What if you want to use custom configuration files in SpringBoot instead of just application.properties?

7. Can SpringMVC RequestMapping specify GET and POST methods? How do you specify it? If SpringMVC wants to render the output Object(for example

8.XXResult or XXResponse) wrapped as JSON output, what should be done?

9. How to intercept SpringMVC exceptions and do custom processing, such as logging or wrapping them as JSON

Spring has the most Spring Interview Questions and Answers with 69 answers.

MySQL

1. If a lot of data is inserted into MYSQL, which method will you choose?

2. If the query is slow, what is the first way you think of? What does an index do?

3. If a single-column index is created and two columns are found in the query, will the single-column index be used?

4. If you create an index that contains multiple columns and use only the first column in the query, can you use this index? What about three columns?

5. Will this index be used if the where condition is followed by I + 5 < 100?

6. How to see if an index is used?

7. Like %aaa% can use index? Like aaa %? What is the difference between DROP, TRUNCate, and DELETE?

8. How do you monitor the database at ordinary times? Slow SQL is how to check?

9. Does your database support emoji? If not, how to operate?

10. What is the amount of data per table in your database? What is the typical time when query performance deteriorates dramatically?

11 Query dead, want to find out the execution of the query process with what command? What do you do when you find out?

12. How does read-write separation work? What do you think the middleware will do? What does this have to do with the transaction?

13. Have you done the database and table? What is the migration process like online? How do you make sure the data is correct?

JVM

1. What GC strategies do you know or use online? What are its advantages and what scenarios are it suitable for?

2. How many JAVA class loaders are included? What is the father-son relationship between them? What does parental delegation mean? What are the benefits?

3. How to customize a class loader? What have you used or in what scenarios do you need a custom classloader? What are the parameters for heap memory Settings?

4. What data is stored in Perm Space? Does it cause OutOfMemory?

5. What is the order in which objects are moved in memory Spaces during GC?

6. Have you ever encountered OutOfMemory problems? How did you deal with the problem? What are the gains from the process?

7.1.8 What changes have been made to Perm Space since then? Is MetaSpace size unlimited by default? Or are you going to specify the size in some way?

What does Jstack do? Jstat? If an online application periodically freezes and you suspect gc is the cause, how do you troubleshoot this problem? What part of a thread log do you usually look at?

9. Have you ever encountered a StackOverFlow exception? Under what circumstances would you guess it would be triggered? How do I specify the stack size of a thread? How much do you usually write?

Divide an element into two parts and apply recursive merge sort to each part.

Compare the sorted elements.

Merges sorted elements.

Sorted.

Linux command

1. The log is too big and I just want to see the last 100 lines. What command do I use if I want to see the continuous output of the log?

2. What should I do if I want to see whether there is a keyword in the log output?

3. Grep what should be done if case is ignored? What about regular expressions?

4. What is the key next to vim? How about 30 rows down? What is the line that jumps to the end of the file? Jump back what? What is backward search?

5. If you have a text file with columns separated by Spaces, how do you count the number of occurrences of each word in the third column?

6. What should I do if I put the number of occurrences above in order? What if you want to sort numbers in their own order instead of strings?

7. What are the delimiters for Linux environment variables? What command is used to set environment variables?

8. What command is used to set a limit on file rights, such as 64? What does this six mean?

9. In Linux, if you want to check the resource usage of a certain process, how to check? What does system load mean? How much load is your online system? If a 4 core machine, how much load do you think is normal? What happens when you press 1 in the top command?

10. How is it that sometimes the CPU usage of all processes in the top command exceeds 100%?

11. What other commands can you use to check system performance or find problems? Which parameter do you usually look at?

12. What command is required to see which network connections are open for a process? Which ones do you care about? Have you optimized the parameters of the Linux system?

13. What can be done with the backlog of system parameters?

14. What may be the cause of many timewaits? What is the impact on your application? What would you choose to reduce these timewaits

15. Could you introduce the process of TCP three-way handshake? If there is a network program and you use the third party library to send data, you suspect that there is something wrong with the data sent by this library, then how to verify it? How do you analyze exported files in tcpdump?

16. What is KeepAlive for? What are the benefits of this?

Development of Redis –

1. Can you introduce cache penetration? How do you think the problem should be solved?

2. How do you trigger cache updates? (such as setting timeout (passive), such as active update when updating)? How to control multiple entries to trigger a cache update in a passive manner?

3. What do you do with Redis? Why not use other KV storage examples like Memcached,Cassandra, etc?

4. What Redis client do you use? Why is Redis high performance?

5. Which Redis data structures are you familiar with? What does zset do? What’s the difference with set?

6. What is the name of the Redis hash command that stores and retrieves hash?

7. What is the difference between LPOP and BLPOP?

8. Why does Redis have some commands that contain SCAN keyword? Is the amount of data returned by SCAN fixed?

9. Have you ever used Lua in Redis? What can it be used for? Why does it work that way?

10.Redis Pipeline is used for what? — How many ways to run Redis persistence? What’s the difference between AOF and RDB? What are the advantages and disadvantages of AOF?

11. What is the general process of Redis Replication? How does bgsave execute this command? – a trick question

12. If there is a lot of KV data to be stored in Redis, but the memory is not enough, what can be done to reduce the memory? Why does this shrink memory?

13. ZipList is used for List and HashTable in Redis. Why do you choose ZipList?

Redis has a 50-answer version of the 50 Best Redis Interview Questions ever.

Monitoring, stability

1. How are service logs collected?

2. How to monitor online machines? What open source products or self-developed products are adopted? Is it in minutes or seconds?

3. If you were trying to collect performance data for a JAVA back-end application, what would you care about? What tools and ideas will you choose to collect?

4. Do you monitor calls to third parties?

Read more on my blog:

1.Java JVM, Collections, Multithreading, new features series tutorials

2.Spring MVC, Spring Boot, Spring Cloud series tutorials

3.Maven, Git, Eclipse, Intellij IDEA series tools tutorial

4.Java, backend, architecture, Alibaba and other big factory latest interview questions

Life is good. See you tomorrow