current position:Home>[springcloud collection] 02, answers to MySQL database practical tutorial

[springcloud collection] 02, answers to MySQL database practical tutorial

2022-01-26 21:34:02 m0_ fifty-four million eight hundred and sixty-one thousand fou

Automate build deployment

Service scheduled task scheduling operation

What is? springcloud?

official :

One stop solution for distributed service architecture , It is a collection of landing technologies of various microservice architectures , Commonly known as micro service family bucket .

Personal understanding :

Previous servers were like , A teacher who knows how to speak and count , Providing services for students , The teacher is ill , Then the whole school will be closed . Now after the popularity of micro service , The school has a mathematics teaching and research group , Chinese teaching and research group , Foreign language teaching and research group , Each teaching and research group has a group of teachers who are specifically responsible for the teaching of a certain subject , Who is missing , The schools are still working .

And in this change , The programmers who have changed history are those who put many services in one server , Or many services on several servers , Sort it out , Decouple , Give their similar functions to the same cluster , Separate the functions that are coupled together , By business , Put them on the server as micro services by function , And this server only provides one service , Or less Services . Let a super large service logic , Decouple into small services , Evenly distributed in their respective servers . Micro service is here .

Each teaching and research group is a micro service cluster . They provide the same service , And the registry Eureka This is where the list of teachers of the teaching and research group is kept , Students want to visit the registry first to get a list of teachers , Then according to the corresponding load method to visit their teachers . Not to let a teacher in the cluster tired to death, not to let a teacher idle to death .

Zuul Gateway , Is the school guard , Who do some students come to school for , It is responsible for guiding ( route ), And through some very simple configurations , To block some people from entering ( Authentication ), Or people who want to learn mathematics can only go to the mathematics teaching and research group , You can't go to the nuclear energy teaching and research group to learn how to build an atomic bomb ( Authority verification ).

Hystrix Where's the fuse , You can think of it as a school volunteer , When a teaching and research group stops class , The students can't find a teacher , These volunteers tell the visiting students in time , Corresponding results , Abnormal information, etc , Lest a large number of students wait at school , These volunteers quickly sorted out the waiting students , Students have been waiting at school , That other schools that need students , Will also wait for students , Finally, a large area of schools were paralyzed . Here we see the students as one request . A fuse is to spread an accident, even if it blows .

Of course, these components are also micro services and need to be registered with Eureka Registry Center

Spring Cloud  It can be regarded as this school . Many of the components mentioned above are equivalent to the functional departments of the school .

springboot and springcloud Select the corresponding version

spring boot

Source code address :

Chinese development documents :

The official recommendation : Use 2.0+ edition ——Java 8-Java9

spring cloud

Chinese development documents :

The official recommendation :G edition H edition ( Premature versions are no longer maintained )

The component versions used in this series of articles :


《 A big factory Java Analysis of interview questions + Back end development learning notes + The latest architecture explanation video + Practical project source code handout 》

【】 Full content open source sharing,type_ZmFuZ3poZW5naGVpdGk,shadow_10,text_aHR0cHM6Ly9ibG9nLmNzZG4ubmV0L3NreWxpYmlhbw==,size_16,color_FFFFFF,t_70)

springcloud Upgrade the functional components

1,Eureka Discontinue use , have access to zk As a service registry

2, The service call ,Ribbon Ready to stop , Replace with LoadBalance

3,Feign Change it to OpenFeign

4,Hystrix Stop more , Change it to resilence4j

Or Alibaba's sentienl
5.Zuul Change it to gateway
6, Service configuration Config Change it to Nacos

copyright notice
author[m0_ fifty-four million eight hundred and sixty-one thousand fou],Please bring the original link to reprint, thank you.

Random recommended