Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

What are the classic interview questions for JAVA?

2025-01-31 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >

Share

Shulou(Shulou.com)06/01 Report--

This article introduces the relevant knowledge of "what are the classic interview questions of JAVA". In the operation of actual cases, many people will encounter such a dilemma. Then let the editor lead you to learn how to deal with these situations. I hope you can read it carefully and be able to achieve something!

1. Talk about the design of interface security

A: the interface security design examines whether the interviewer has a design concept and considers the comprehensiveness of the problem. The interface is a set of specifications, which can be defined by Token+ salt + timestamp + login verification in the project.

two。 What happens when the user enters an address in the browser and clicks enter?

Answer: this question can be briefly answered with the combination of Http protocol and Springmvc running process. After the user clicks enter, the browser first looks up whether there is a mapped address in the local cache. If not, it is routed to the network transport layer and transferred from bottom to top by the network layer 7 protocol. Finally, the DNS policy of the application layer (DNS homology means that the domain name, protocol and port are the same) is searched, and the ModelandView object is returned by the program. The front end is rendered and displayed.

3. How do you deal with the concurrency of hundreds of billions of visitors?

Answer: personal understanding: in the face of high concurrent business, we need to consider from many aspects, such as framework, business design, system design, database and so on. From the perspective of framework, we need to do micro-service + distributed processing to distribute the total score of each business. From the business design, do cache + clustering + horizontal extraction + message middleware, from the database to do read-write separation + multi-services corresponding to their own database + database middleware The code level is based on pooling technology, which is understood by individuals.

The data type of 4.Redis? What is cache traversal? What is a cache avalanche? How to solve?

A: this kind of problem examines the basic + practical solutions, and it is a classic problem related to redis. First of all, data types and distributed consistency issues have been written separately.

Thoroughly solve the consistency problem of distributed system

Thoroughly solve the consistency problem of distributed system (part two)

String can be used for simple storage

List can be used to store messages, similar to message queues

Set can be used to remove weight, find difference sets, intersection, etc.

Hash storable mapping relationship

ZSet can do the ranking.

Cache breakdown: intentionally accessing a key that does not exist

Solution: determine whether there is a + mutex + update strategy

Cache avalanche: a large number of key expires at the same time, resulting in database access

Solution: setting the expiration time of random key + judging whether it is invalidated + double cache

5. Tell me about your understanding of SpringBoot?

A: built-in severlet container, simplified a large number of xml configuration, started by @ SpringApplication annotation, customized @ Bean@Configuration, concept agreement is greater than configuration, one-click startup, built-in components, and micro-service framework extension, etc.

This is the end of the content of "what are the classic interview questions for JAVA". Thank you for reading. If you want to know more about the industry, you can follow the website, the editor will output more high-quality practical articles for you!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Internet Technology

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report