Shiro integrates some configurations and problems of springboot
First, post the official website address https://shiro.apache.org/spring-framework.html
1, shiro configuration class
To use shiro, you must configure a shiroConfig configuration class, which requires three bean s:
Realm, custom realmDefaultwebsecuritymanager needs to pass the Realm parameterShiroFilterFactoryBean, you need to pass the defaul ...
Posted by andy666 on Tue, 07 Dec 2021 01:12:31 -0800
JavaBean introspection and BeanInfo
Java's BeanInfo is rarely used at work. When I was studying the spring source code, I found that a genus called "spring.beaninfo.ignore" will be set when SpringBoot starts. This configuration can only be found on the Internet, which means whether to skip the search of java BeanInfo and find no other information, but what is BeanInfo?
...
Posted by cyclefiend2000 on Tue, 07 Dec 2021 00:00:32 -0800
Why do you have to override hashCode to override equals
equals common interview questions
Before we start talking, let's look at some common interview questions to see if you can answer them all.
1. What's the difference between equals and = =?
2. Must two objects with equal hashcode be equal? Are equals equal?
3. Two objects are equal by equals. Are their hashcode s equal?
If we do not override ...
Posted by newbie9999 on Mon, 06 Dec 2021 23:56:15 -0800
The volatile keyword that must be asked in the interview is easy to understand. You hit me after reading it
introduction
It is said that StringBuilder is more efficient than String in handling String splicing, but sometimes there may be some deviation in our understanding. Recently, when I tested the efficiency of data import, I found that my previous understanding of StringBuilder was wrong.
Later, I found out the logic of this piece by mea ...
Posted by lm_a_dope on Mon, 06 Dec 2021 23:36:15 -0800
The past and present life and application practice of Dubbo, a distributed service governance framework
Dubbo's backgroundDubbo has been open source for nearly 10 years and has been widely used in major domestic enterprises. What magic is it worth pursuing? This article gives you a detailed description.Requirements of large-scale service for service governanceWhen enterprises begin large-scale service, the disadvantages brought by remote communic ...
Posted by ChrisML123 on Mon, 06 Dec 2021 23:07:49 -0800
Enumeration, annotation, reflection
enumeration
Format of enumeration
Permission modifier enum enumeration name{
Example 1, example 2, example 3, example 4;
}
package com.meiju;
public enum Level2 {
LOW(1),MEDIUM(50),HIGH(100);
private int levelValue;
private Level2(int levelValue){
this.levelValue=le ...
Posted by zulfiboy on Mon, 06 Dec 2021 22:42:21 -0800
Dubbo admin officially supports 3.0 service governance
Introduction: Dubbo is no stranger to you. It is a microservice development framework, which provides two key capabilities: RPC communication and microservice governance. In daily development, we use more RPC communication capabilities provided by Dubbo, but less service governance capabilities. This paper will focus on service governance. Dubb ...
Posted by lepad on Mon, 06 Dec 2021 22:17:24 -0800
Four ways for IOC container to create bean objects
preface:
The Spring container creates a bean object. Generally, it finds the class to be instantiated by looking up the class attribute value of the bean element through the reflection mechanism, so as to instantiate the bean object. This is to call the constructor to instantiate the bean object In some cases, a simple xml configuration file ...
Posted by VinnyWolf on Mon, 06 Dec 2021 22:12:24 -0800
Kuberneters CRD resource details
1. K8S CRD is concise and easy to use:
Introduction to CustomResourceDefinition: Everything in Kubernetes can be regarded as resources. After Kubernetes 1.7, the secondary development capability of CRD custom resources is added to extend Kubernetes API. Through CRD, we can add new resource types to Kubernetes API without modifying Kubernetes s ...
Posted by marcs910 on Mon, 06 Dec 2021 21:43:29 -0800
The Spring framework uses JDBC template to connect to the database
JDBCTemplate
JDBC template (concept and preparation)
What is a JdbcTemplate
The Spring framework encapsulates JDBC and uses JdbcTemplate to facilitate database operation preparation
Introduce related jar packages [the external chain image transfer fails. The source station may have an anti-theft chain mechanism. It is recommended to ...
Posted by samsunnyuk on Mon, 06 Dec 2021 20:53:20 -0800