Analysis of SpringBoot source code -- Analysis of SpringBoot project startup class SpringApplication

Source version description The source code of this article is spring boot 2.1.0 build, corresponding to spring framework 5.1.0.rc1. Note: This article only combs the process as a whole, without detailed and in-depth analysis. SpringBoot entry class @SpringBootApplication public class DemoApplication { public static void main(String[] a ...

Posted on Tue, 15 Oct 2019 10:46:44 -0700 by dan7474

Parameter Check - validator

Catalog background Importance Best Practice - springboot pom file Entity class (domain model) Controller layer Type comparison Reference articles background Background parameter validation is essential during development, so you often see code like the following There's nothing wrong with this ...

Posted on Sun, 13 Oct 2019 14:31:16 -0700 by neutra

Springboot+MyBatis+JPA Integration

1. Preface Springboot has been very popular recently, and I have also tasted the sweetness of the project. I have been using Springboot+JPA for a long time, and found that JPA is not too flexible, or maybe I am not proficient in JPA. In sum, in order to learn more about Springboot, I decided to try the integration of Springboot+MyBatis+JPA. ...

Posted on Sat, 12 Oct 2019 12:29:49 -0700 by ScubaDvr2

springbooot integrates quartz and dynamically updates timed tasks

My last blog wrote about how to perform regular tasks according to a fixed cron, but now there is a demand: users add a memo (equivalent to an alarm clock), 30 minutes before the memo time, to actively push messages to users, then my last blog post is slightly inadequate, after a wave of Baidu, come up ...

Posted on Sat, 12 Oct 2019 11:12:38 -0700 by ProTec

Principle of SpringBoot Health Examination

I believe that all the students who read the previous article know the routine of SpringBoot automatic assembly. Look directly at the spring.factories file. When we use it, we only need to introduce the following dependencies. <dependency> <groupId>org.springframework.boot</groupId> <artifact ...

Posted on Wed, 09 Oct 2019 19:30:08 -0700 by fantomel

springboot's Excessive if else Solutions

In practical development projects, we often encounter multiple ifelse judgment statements. For simple projects, we can also meet the requirements table. However, for projects with frequent changes in requirements, this will lead to code redundancy and difficult to maintain, so it is not recommended t ...

Posted on Wed, 09 Oct 2019 09:10:22 -0700 by V

Files is used to upload and download files and pictures with front-end and back-end separation

Recently found a very useful way to upload and download files, so today I will bring you, hoping to help you. First of all, the project is based on SpringBoot development, and if you use Spring, it won't affect either. Functional demonstration: Bullshit goes straight to the code 1. Create a StoreServic ...

Posted on Mon, 07 Oct 2019 22:29:57 -0700 by adavis

Task scheduling: Quartz

1. Quartz example public class JobTest implements Job { /** * Specific tasks * * @param jobExecutionContext Save some information about the job runtime */ @Override public void execute(JobExecutionContext jobExecutionContext) { //Reference to scheduler to exe ...

Posted on Mon, 07 Oct 2019 05:50:14 -0700 by Natty_Dreadlock

Spring Cloud Learning: Creation of config client project

I. Introduction We learned how to create a configuration center service project and use url to request the return result. Now we learn how to build a config client project and get the content information of the specified file on github. Create config-client project 1. Dependency Introduction < ...

Posted on Sun, 06 Oct 2019 09:24:59 -0700 by awared

SpringBoot~File Upload

1. File upload SpringBoot simplifies file upload, which makes file upload very convenient. Here is how to write single file upload and multi-file upload when the front and back ends are separated. Dependency Addition (pom.xml) (Basic Dependency) <dependency> <groupId>org.springframework.boot</groupId> <artifactId& ...

Posted on Fri, 04 Oct 2019 09:55:06 -0700 by inkfish