Spring-boot Mybatis-plus practical application

Article directory Preface 1. springBoot integrates mybatis-plus 1.1 maven introduces dependencies: 1.2 Configure data source:: 2. Use: 2.1 mysql prints the executed sql settings: 2.2 Paging query: 2.3 Conditional constructor: 2.3.1 QueryWrapper query: 2.3.2 UpdateWrapper update: 2.3.3 LambdaQueryWrapper query: 2.3. LambdaUpdateWrapper update: 3. Use of plug-ins: 3.1 Custom ID generation: 3.2 Logical deletion: 3.3 Autofill: […]

Stop writing tool classes by yourself, Spring Boot has all the built-in tool classes you need! !

Assertion An assertion is a logical judgment that checks for something that shouldn’t happen The Assert keyword was introduced in JDK1.4 and can be turned on through the JVM parameter -enableassertions SpringBoot provides the Assert assertion tool class, which is usually used for data validity checking. //Requires parameter object to be non-null (Not Null), otherwise […]

Spring Boot implements various parameter verifications. It is so well written. It is recommended to collect it!

Hello everyone, I am a passerby~~~ Click on the card below to follow me, java dry goods will be delivered in time I have written an article about the use of Spring Validation before, but I still feel that I am superficial. This time I plan to thoroughly understand Spring Validation. This article will introduce […]

Comment module of springboot personal blog system

Personal blog system development is briefly divided into five modules Homepage Login function Comment management Article management Email management A complete blog system, the front-end page can display and publish comments, comment users can reply to each other, and the back-end can manage the comment content. Due to limited space, the article comments of this […]

Springboot2.x integrated lettuce connection redis cluster reports timeout exception Command timed out after 6 second(s)

Original/Zhu Jiqian Background: Recently, I was doing a stress test on a newly developed Springboot system. I found that when I first started the stress test, I could access data from the redis cluster normally. However, after a few minutes of pause, and then when I continued to use jmeter to perform the stress test, […]

spring boot validation use

spring-boot-starter-validation is a module used in Spring Boot to support data validation. It is built on the Java Validation API (JSR-380) and provides a convenient way to validate data in applications. Here is the basic way to use spring-boot-starter-validation: Quick Start 1. Add dependencies: In your Spring Boot project’s pom.xml file, add the following dependencies: […]

SpringBoot application starts org.apache.catalina.LifecycleException

Table of Contents SpringBoot application starts org.apache.catalina.LifecycleException Problem Description Cause Analysis Solution 1. Check the resources that the application depends on 2. Check application configuration 3. Check port occupancy 4. Check dependent component version compatibility 5. Check the log files Application scenario example: org.apache.catalina.LifecycleExceptionexception caused by database connection exception SpringBoot application starts org.apache.catalina.LifecycleException When developing […]

Spring Boot(2)

1. Operation and maintenance 1.1. Packaging program The SpringBoot program is created based on Maven, and Maven provides packaging instructions called packages. This operation can be performed in the Idea environment. mvn package After packaging, a jar file with a similar project name will be generated, and its name is composed of module name + […]