hystrix source code analysis

Recently, I encountered some production problems involving hystrix. I want to understand the underlying principle. Hystrix makes a lot of use of Rxjava's responsive programming. It's a little hard to understand because you don't understand Rxjava. Basic preparation <?xml version="1.0" encoding="UTF-8"?> <project xmlns="http://maven.a ...

Posted by hmgroen on Mon, 27 Dec 2021 19:46:13 +0100

sentinel learning document

sentinel documents summarized in the internship Official documents: https://sentinelguard.io/zh-cn/docs/dashboard.html 1. Characteristics Sentinel vs. Hystrix SentinelHystrixIsolation strategyBased on ConcurrencyThread pool isolation / semaphore isolationFuse degradation strategyBased on response time or failure rateBased on failure ratioRe ...

Posted by Byron on Mon, 27 Dec 2021 17:07:06 +0100

Java random Prim algorithm and A * algorithm produce random mazes

Procedure requirements: 1. Randomly generate maze map The maze map needs to be randomly generated in the game and Java util. Random class uses the random number generation method provided by random class to randomly generate obstacles, paths or rewards. Maze map is represented and stored by two-dimensional array. 2. Judge whether the player ...

Posted by bhawap on Mon, 27 Dec 2021 14:04:11 +0100

50 lines of code related to @ EnableAspectJAutoProxy and Spring AOP

Test case 1 Tangent point @Component public class UserServiceImpl implements UserService { @Override public void save(UserInfo userInfo) { System.out.println("Execute save:"+userInfo.getName()); } } Test case 2 section @Aspect @Component public class TestAspect { @Pointcut("execution(* com.helloworld.service.i ...

Posted by ramma03 on Mon, 27 Dec 2021 10:42:36 +0100

[spring cloud] spring cloud integrates the environment of Seata distributed transactions

1, Foreword In the last article Research on distributed transaction principle of Seata AT mode In this paper, we will use spring cloud and spring cloud Alibaba to integrate Seata to realize distributed transaction control, and use Nacos as the registration center to register Seata into Nacos. 2, Environmental preparation This article mainly ...

Posted by burtybob on Mon, 27 Dec 2021 10:26:35 +0100

Make good use of Spring AOP and take it easy

Recently, the project has entered the joint commissioning stage. The interface of the service layer needs to interact with the protocol layer. The protocol layer needs to assemble the input parameter [json string] into the json string required by the service layer. It is easy to make mistakes in the assembly process. The interface debugging ...

Posted by erikjan on Mon, 27 Dec 2021 05:47:01 +0100

Spring MVC framework understanding

1. Integration of spring and Web Environment 1.1 ApplicationContext application context acquisition method The application context object is obtained through the new ClasspathXmlApplicationContext(spring configuration file), but each time a Bean is obtained from the container, the new ClasspathXmlApplicationContext(spring configuration file) ...

Posted by nodster on Mon, 27 Dec 2021 05:42:33 +0100

Spring Boot custom parameter validator

Customize parameter validators in Spring Boot After we introduce the starter dependency of spring boot starter validation in the project, we can directly use annotations such as @ NotNull and @ Length on the request method of the Controller for parameter verification. The bottom layer of the starter uses the verifier provided by hibernate vali ...

Posted by JamieThompson on Sun, 26 Dec 2021 23:33:57 +0100

Rules engine Drools learning details

1. Overview of rule engine 1.1 what is a rule engine The full name of rule engine is business rule management system, and its English name is BRMS (Business Rule Management System). The main idea of rule engine is to separate the business decision-making part of the application, and write business decisions (business rules) using predefined s ...

Posted by JPnyc on Sun, 26 Dec 2021 21:35:18 +0100

Spring family related notes

1, @ Component, @ repository, @ Service, @ Controller (1) @ Component put the ordinary java class creation object into the Spring container Equivalent to < bean id = "" class = "" > in xml configuration file</ bean> For example: public class Cat { private String name; private Integer age; public ...

Posted by angelena on Sun, 26 Dec 2021 19:04:57 +0100