Map thread safe interview questions
Personal blog
Welcome to personal blog: https://www.crystalblog.xyz/
Alternate address: https://wang-qz.gitee.io/crystal-blog/
1. Differences between hashtable and HashMap
(1), HashMap implementation is out of sync and thread is unsafe Key values in HashMap are stored in Entry
Hashtable thread safety Use synchronized
jdk7 underlying data ...
Posted by Rex__ on Sun, 20 Feb 2022 12:00:30 +0100
Third, the mechanism of Window creation and Android Window Manager. (source code version SDK31)
Android window mechanism SDK31 source code analysis directory
First acquaintanceCreation and loading of DecorView and subdicorCreation and loading of Window and Window ManagerThe creation of ViewRootImpl and the real loading of the viewEvent distribution for ViewRootImplMust be in the main thread to update the UI? Why?Relationship between Toke ...
Posted by norpel on Sun, 20 Feb 2022 11:27:59 +0100
AOP application and code implementation (detailed analysis)
catalogue
1. Introduction
1.1 main processes / functions of IOC
1.2 concept diagram of AOP
1.3 AOP flow chart
2. Basic preparations
------------------------------The configuration file implements AOP----------------------------
3. Introduction to AOP configuration file mode
4. Expression of pointcut (the * sign is not recommended)
-- ...
Posted by persia on Sun, 20 Feb 2022 11:15:14 +0100
Classes commonly used in java (note 16)
1, String related classes
1. Create string
Properties of String
public final class String
implements java.io.Serializable, Comparable<String>, CharSequence {
/** The value is used for character storage. */
private final char value[];
/** Cache the hash code for the string */
private int hash; // Default to 0
Specific JDK API St ...
Posted by nedpwolf on Sun, 20 Feb 2022 11:10:40 +0100
Rule engine design
summary
The so-called rule engine refers to the mechanism of if some condition match then trigger some thing. Condition is a series of expression s, such as when the equipment status is changed to offline (attribute), and someone passes through the gate (event); Trigger a series of actions, such as storing in the database and sending alarm inf ...
Posted by Nunners on Sun, 20 Feb 2022 10:19:12 +0100
Rosalind Java| Calculating Protein Mass
Calculation of protein molecular weight for Rosalind programming problem.
Calculating Protein Mass
Problem In a weighted alphabet, every symbol is assigned a positive real number called a weight. A string formed from a weighted alphabet is called a weighted string, and its weight is equal to the sum of the weights of its symbols.
The standar ...
Posted by vtolbert on Sun, 20 Feb 2022 09:14:12 +0100
SQL: mybatis+foreach+like/in robustness to achieve multi conditional input - multiple matching methods fuzzy search / search
Project scenario:
The background of the project is the monitoring and management platform and the alarm configuration section. It is necessary to query and return multiple data information. Among them, it is necessary to optimize the query and return function of subscribers. The original one can only enter one subscriber name for query and opt ...
Posted by Codein on Sun, 20 Feb 2022 09:05:08 +0100
JWT asymmetric encryption public-private key encryption and decryption can set the expiration time [JwtHelper of Spring security framework] [Jwts of jsonwebtoken.JJWT]
introduce
Recently, I want to develop a coder management platform. For the technical selection of login module, I chose JWT Jwt can ensure that the login information placed on the client is not tampered with. In order to be more secure, I use RSA asymmetric encryption. That is, the private key is used to generate Jwt, and the public key is use ...
Posted by climbjm on Sun, 20 Feb 2022 07:55:20 +0100
Beginners use JavaWeb to write one of the most common registration and login pages
It is just a most common registration and login page written by Java Web for beginners. You only need to enter your user name and password
Only part of the java code is listed and explained. The database, configuration process, configuration file and html front-end interface follow their own capabilities
I First use the JDBC utils tool class ...
Posted by Cragsterboy on Sun, 20 Feb 2022 06:46:21 +0100
great! Alibaba's open source artifact directly synchronizes MySQL data to ES in real time. It's so sweet!
abstract
The commodity search function in the mall project has never done real-time data synchronization. Recently, it was found that Alibaba's open source canal can synchronize the data in MySQL to Elasticsearch in real time, which can well solve the problem of data synchronization. Today, let's talk about the use of canal, hoping to help ...
Posted by sunil.23413 on Sun, 20 Feb 2022 05:54:30 +0100