Introduction to the use of Redis--Jedis
1. Create project
1.1 creation steps
1.2 add pom dependency
<dependencies>
<dependency>
<groupId>redis.clients</groupId>
<artifactId>jedis</artifactId>
<version>2.9.0</version>
</dependency>
<!--test-->
<dep ...
Posted by premracer on Mon, 27 Apr 2020 07:14:31 -0700
How Spring solves bean circular dependency from source code
1 what is bean circular dependency
circular reference is the original text of circular dependency, which refers to the mutual reference of multiple objects to form a closed loop.
Take the circular dependency of two objects as an example:
There are three cases of circular dependency in Spring:
The cyclic dependence of the constructor;
Circular ...
Posted by scotthoff on Sun, 26 Apr 2020 19:48:31 -0700
Spring boot series elegant handling of unified exception handling and unified result return
Spring boot series (x) unified exception handling and unified result return
Previous recommendation
Spring boot series (I) idea new spring boot project
Introduction to SpringBoot series (2)
Spring boot series (3) configuration file details
Spring boot series (IV) detailed explanation of web static resource configuration
Spring boot series (V) M ...
Posted by countcet on Sun, 26 Apr 2020 06:25:32 -0700
Spring cloud gateway routing, assertion, filtering
Gateway introduction
What is it?
There is a very important component in the Spring Cloud family bucket: gateway. In the 1.x version, Zuul gateway is used, but in the 2.x version, Spring Cloud has developed a set of gateway components: Spring Cloud Gateway because Zuul's upgrade keeps skipping tickets.
Based on Spring Boot 2.x, Spring WebFlu ...
Posted by mk_silence on Sat, 25 Apr 2020 21:19:31 -0700
Add json processor to springboot
spring supports the json parser of Jackson 2 by default. Now most people are used to the parser of fastJson. Now it's easy to say how to configure the json parser
jackson2
The configuration is as follows:
@Configuration
public class WebConfig extends WebMvcConfigurerAdapter {
//JackSon configuration
@Override
public void configureMess ...
Posted by jesse_james on Fri, 24 Apr 2020 09:24:04 -0700
11. Chapter 11 of spring cloud, upgrading, service GateWay gateway, service configuration Config and service Bus bus
Chapter 10 of spring cloud, upgrading, service GateWay gateway, service configuration Config and service Bus bus
1, Service GateWay
1. Gateway overview
Why does it exist:
Different microservices usually have different network addresses, and external clients may need to call multiple microservices interfaces to fulfill the requirements of ...
Posted by AutomatikStudio on Thu, 23 Apr 2020 20:51:35 -0700
Spring mybatis mapperscannerconfigurer cannot get the value in PropertyPlaceholderConfigurer
Because we don't want to repeat the tedious configuration bean s in xml, we use MapperScannerConfigurer to scan the package and automatically generate instances for spring management. However, it was found that the initialization of datasource failed because the value in PropertyPlaceholderConfigurer could not be obtained.
Through online searc ...
Posted by matbennett on Thu, 23 Apr 2020 09:04:21 -0700
Take over the project left by my old brother, there is a big hole! Processing global date formatting with springboot
Recently, several colleagues of the Department have been wronged and left one after another. They are reluctant to leave when they have been working together for three years. After all the formalities have been properly handled, they are sent out of the company after greetings. Several elder brothers laugh at me when they leave. I immediately f ...
Posted by johnmess on Thu, 23 Apr 2020 02:59:06 -0700
Spring MVC processing flow
In spring webmvc, all requests start with a class called dispatcher servlet. It is the hub of request dispatch, often referred to as the front-end controller, also known as the request dispatcher.
From the derived relationship, we can see that the dispatcher Servlet is also a Servlet. When we map the / path to the dsiaaptcherservlet, all reque ...
Posted by pozer69 on Thu, 23 Apr 2020 02:51:59 -0700
Spring Cloud Gateway series processing request process
This article mainly reveals the loading of Spring Cloud Gateway and how to handle the request process from the source point of view.
1. Overview of spring gateway
Spring Cloud Gateway is an official gateway developed by spring based on Spring 5.0, Spring Boot 2.0, Project Reactor and other technologies. Spring Cloud Gateway aims to provide a ...
Posted by Michael Lasky on Thu, 23 Apr 2020 00:29:58 -0700