Business Department interview (Ali), Business Department interview ali

Source: Internet
Author: User

Business Department interview (Ali), Business Department interview ali

I. Java Basics

1. What are the differences between the instance method and the static method?

2. What types of exceptions are involved in Java? How to use them separately?

3. What are common collection classes? For example, how to sort a List?

4. What is the internal implementation of ArrayList and rule list? What are the differences between them and their adaptation scenarios?

5. What is memory overflow?

6. What is the use of ClassLoader?

7. = what is the difference between equals and equals?

8. What is the role of the hashCode method?

9. What are the methods in the Object class? List more than three instances.

10. What is NIO? What scenarios are applicable?

12. How to Prevent HashMap data structures, scaling policies, and Hash conflict attacks and implement thread-safe HashMap?

13. JVM memory structure, GC algorithm, CMS, G1 Principle

14. NIO model, differences between select and epoll, principles of multiplexing

16. How many bytes a character occupies in Java? How many bytes are occupied by int, long, and double?

17. How can I create a class instance?

18. What is the difference between final/finally/finalize?

19. What are the differences between LinkingBlockingQueue and ArrayBlockingQueue? What are their application scenarios?

20. What is the difference between Session and Cookie?

21. What are the differences between String/StringBuffer/StringBuilder? What are their implementations after extension?

22. Servlet lifecycle?

23. How can I use Java to allocate a continuous 1 GB of memory? What do you need to pay attention?

24. Java has its own memory reclaim mechanism, but why is there a memory leakage problem?

25. What should I pay attention to when using objects as keys in Java? How to Implement hashcode?


1. Basic Structure of the JVM heap.

2. What types of JVM junk algorithms are available? How does CMS collect algorithms?

3. What common startup parameters can be adjusted for JVM?

4. How can I view JVM memory usage?

5. Will Java programs experience memory overflow?

6. What are your common JVM configurations and tuning parameters? What are their respective roles?

7. Java memory generation model, GC algorithm, and common JVM startup parameters;

8. during the CMS algorithm process, does the JVM need to be paused during the CMS recycle process (this answer is good, you can also just read Bi Xuan's Java distributed development or online article learning, you can use common configurations of JVM startup parameters, jstat, and other commands to check your hands-on capabilities and willingness, and troubleshoot online issues)

9. Under what circumstances will OOM occur (heap memory, permanent zone, off-heap zone, method stack)

10. Java memory structure (Heap Structure, new generation [S0/S1/Elden], old generation, persistent generation)

11. Common GC policies: When will YGC be triggered and FGC be triggered?

Iii. Data Structure and algorithm Basics

1. Let's talk about several common sorting algorithms and their respective complexity.

2. What is a jump table?

3. How can I check whether a linked list has a ring? Further, confirm the location of the ring.

4. How to traverse a binary tree?

5. A sort list is arranged in the descending order.

6. Implementation of HashSet

4. multithreading/concurrency

1. Common locks in Java, mutex locks, read/write locks, semaphores

2. Atomic class, how to ensure atomicity, CAS hardware commands

3. volatile, cause of visibility issues, hardware architecture, L3 Cache, QPI, optimistic lock

4. How to implement a thread-Safe Data Structure

5. How to avoid deadlocks

6. How to Solve the ABA Problem

7. What is the role of the Synchronized keyword?

8. What is the role of the Volatile keyword?

9. What is the Java memory model?

10. What should I pay attention to when using HashMap in a multi-threaded environment? Why?

11. Do I use run () or start () to start a thread in a Java program ()?

12. What is a daemon thread? What is the purpose?

13. What is a deadlock? How to avoid

14. What is the difference between a thread and a process?

15. How is Threadlocal implemented in Java?

16. How does ConcurrentHashMap work?

17. Differences between sleep and wait

18. Differences between policy and policyall

19. Role of the volatile keyword

20. Functions and implementation of ThreadLocal

21. How to execute two threads in a serial mode

22. What does context switching mean?

23. Can I kill a thread at runtime?

24. What are conditional locks, read/write locks, spin locks, and reentrant locks?

25. What is coroutine (User-state thread, reduce data copying, reduce CPU overhead, and no callback function )?

26. How does ThreadPoolExecutor of the thread pool work?

27. Use of common classes under J. U. C. Deep investigation of lock, synchronized, and ThreadPool; use of BlockingQueue. (Take, poll, put, offer); Implementation of atomic classes.

28. Use of various common locks. If you have a good grasp of the above, you can also look at the more advanced False Sharing, Cache Line, visibility and atomicity;

V. Linux usage and troubleshooting

1. What is the difference between hard link and soft link?

2. What is inode?

3. What are common Linux commands?

4. How does one view the resource consumption of a Java thread?

5. What are the possibilities of excessive Load?

6. What is the/etc/hosts file used?

7. What is the function of the/etc/resolv. conf file?

8. How to quickly replace all "abc" in a text with "xyz "?

9. What tools are commonly used in Linux for network and disk I/O analysis?

10. What tools are commonly used in Linux for memory and CPU analysis?

11. I found that the disk space is not enough. How can I quickly find the most occupied files?

12. troubleshoot Java server issues (OOM, high CPU, high Load, and class conflict)

13. Common Java troubleshooting tools and usage (top, iostat, vmstat, sar, tcpdump, jvisualvm, jmap, jconsole)

14. How to analyze the Thread dump file (Runnable, lock, code stack, and operating system Thread ID Association)

15. grep, awk, sed; Have you ever written a shell script;

16. Common cpu load is too high, and us is too high. What is the problem. Determine whether top, jstat, and jstack are used.

17. What are common memory problems. Determine whether free, top, and jmap are used.

Vi. Framework usage

1. Bean lifecycle in Spring.

2. SpringMVC or Struts process the request.

3. What problems does Spring AOP solve? How to implement it? The relationship between aop and cglib and asm.

4. What is the propagation attribute of Spring transactions? What will it affect?

5. What is the difference between BeanFactory and FactoryBean in Spring?

6. What is the principle of IOC in the Spring framework?

7. spring dependency injection methods

8. struts Workflow

9. How to implement a plane using Spring?

10. How does Spring implement database transactions?

11. What are the differences between ORM frameworks such as Hibernate and Ibatis? What is ORM and what are the pain points?

12. spriong ioc lifecycle, (init-method, intilizingbean interface method afterPropertiesSet), and so on.

13. Hibernate's use of level 1 cache and Lazy-Load understanding;

14. How can I implement Spring IoC AOP with code?

15. How does RPC server Load balancer and service discovery work?

16. Differences between several push models: long polling and websocket

VII. Database Problems

1. What are the features of MySQL InnoDB?

2. What is the difference between optimistic locks and pessimistic locks?

3. What is the database isolation level? What is the function?

4. Basic principles of MySQL master-slave Synchronization.

5. How can I find all rows whose name field contains "XYZ" from a table?

6. index data structure (Dictionary + BitTree)

7. How to optimize database performance (index, database/table sharding, batch operation, paging algorithm, hard disk SSD upgrade, business optimization, Master/Slave deployment)

8. Under what circumstances does SQL use indexes (excluding, not equal to, and functions)

9. What fields are indexed in general (the most data-filtered fields)

10. How can I find out from a table that the name field does not contain all rows of "XYZ?

11. MySQL, B + index implementation, row lock implementation, and SQL Optimization

12. Redis, RDB and AOF, how to implement high availability and Cluster

13. How to Solve the high concurrency inventory reduction Problem

14. Index implementation mechanism in the mysql storage engine;

15. granularity of database transactions;

16. Row locks, table locks, optimistic locks, and pessimistic locks

8. network protocol and Network Programming

1. TCP connection establishment process.

2. TCP disconnection process.

3. What is the logic behind browser 302 redirection?

4. HTTP interaction process. What is the difference between HTTP and HTTPS? What is the interaction process of SSL?

5. What is the relationship between Rest and Http? Everyone said that Rest is very lightweight. How do you understand the Rest style?

6. What is the use of TCP Sliding Window Protocol? Let's talk about the principle.

7. What are the HTTP methods?

8. What is the difference between a vswitch and a vro?

9. What is a VLAN?

10. What is VXLAN?

11. http protocol (message structure, resumable data transfer, multi-thread download, what is persistent connection)

12. tcp protocol (connection creation process, slow start, sliding window, layer-7 Model)

13. webservice Protocol (the difference between the wsdl/soap format and the rest Protocol)

14. Is the spdy/http2.0 protocol well known?

15. NIO benefits: Netty thread model, what is zero copy

9. cache systems such as Redis/middleware/NoSQL/consistent Hash

1. List the concurrency models of a common Redis client.

2. How does HBase implement fuzzy search?

3. List a common message middleware. How can I implement message ordering?

4. How to implement a Hashtable? How do you consider Hash conflicts in your design? How to optimize it?

5. distributed cache and consistent hash

6. LRU algorithm, slab allocation, and how to reduce memory fragments

7. How to Solve cache single-host hotspot issues

8. What is Bloom filter? False positive refers?

9. Differences between memcache and redis

10. What are the functions of zookeeper and how the election algorithm works?

11. How to Use map/reduce to implement joint statistics of two data sources in the map/reduce Process

10. Design Pattern and Reconstruction

1. What principles will you follow when designing a factory package?

2. Can you list an open-source project/library using the Visitor/Decorator mode?

3. What are the most common design patterns for coding? In what scenarios?

4. How to implement a Singleton?

5. Proxy mode (Dynamic proxy)

6. Singleton mode (lazy mode, cool mode, how to solve concurrency initialization, volatile and lock usage)

7. What are some impressive design patterns in the JDK source code?

8. Reactor Mode

11. Learning and enterprising

1. What technologies do you usually pay attention?

2. What technical blogs and websites will be viewed?

3. Are there any technical idols?

4. What technical books have you read?

5. What books do you usually read? What are the most impressive basic and non-technical books in the books you read last year and this year?

6. (If you do not read a book) what technical forums do you usually attend? Which one do you like most? Why?

7. What new technologies or frameworks are used in projects or products?

8. Recently, I have studied any popular technologies or frameworks in the industry.

9. Are you aware of the current project or product defects and plans?

10. whether a project is included and how to manage the project

11. Are there any challenges for team management?

12. ability to withstand pressure and willingness to withstand pressure

1. The XXX implementation you just mentioned is very similar to that of the open-source YYY. Is it copied?

2. What about overtime work?

3. Whether the platform has worked overtime, whether it is active or passive, and whether it is highly resistant

4. Is there any responsibility for multiple tasks and how to process them in parallel?

5. What are the most proud of your recent project?

13. Stability Test

1. Understand the marital status of the family, the home location, home location, current salary, and stability evaluation.

2. What would you do if you had to take over a long-history module?

3. Check the job-hopping status of your resume and ask questions accordingly. If there are frequent job-hopping requests, ask why

14. Openness

1. If a large file contains 4 GB numbers with a row in it, the memory is only 256 MB?

2. What will happen if the hard disk of the machine where your deployed application is located is broken? How does your program handle this exception? (Faults in distributed systems are the norm. It is designed to avoid spof, fault tolerance, and ensure high system availability)

3. Implement a Message Queue System

4. How to design a high-availability architecture

5. Multiple Hash operations are used to solve the problem of duplicate URL access.

6. Globally Unique ID problem.

7. How to Design flash sales.

8. How to optimize the performance.

9. How can I troubleshoot CPU 100%?

10. Implement a distributed hitting system.

11. Mutual logon between and

12. How to sort a List of 0.2 billion data records quickly?

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.