SpringBoot integrates Netty

Introduction Netty is a Java-based open source network application framework that provides high-performance, asynchronous event-driven network programming capabilities. Netty is designed to help developers build high-performance, high-reliability network applications. Netty provides a simple API and rich functions, which can easily handle various network communication protocols, such as TCP, UDP, WebSocket, etc. Its design concept is […]

springboot integrates ShardingSphere5.2.1 (latest version)

The content includes two methods: table configuration file type and custom type. Unable to direct the last code, crazy pictures config MyBaseMapper package cn.com.lyb.config; import com.baomidou.mybatisplus.core.mapper.BaseMapper; import java.util.List; public interface MyBaseMapper<T> extends BaseMapper<T> {<!– –> /** * Batch insertion, equivalent to insertList */ int insertBatchSomeColumn(List<T> entityList); } MybatisPlusConfig package cn.com.lyb.config; import com.baomidou.mybatisplus.annotation.DbType; import com.baomidou.mybatisplus.core.injector.AbstractMethod; import […]

springboot integrates mqtt+maven+yml and is available for personal testing

Visualization tools: mqtt assistant mqtt explor Free version is local only. Available via port forwarding. Official website address: http://www.redisant.cn/mqtt Spring integration interaction logic For publishers: Messages are sent through the message gateway, and DirectChannel, an instance of MessageChannel, handles the details of the sending. After DirectChannel receives the message, it internally sends it to the […]

SpringBoot integrates Zookeeper for distributed locks

Environment preparation zookeeper preparation First you need a zookeeper server, or a zookeeper cluster. I have prepared a zookeeper cluster, as shown in the figure: Of course, a single-node zookeeper can also build distributed locks. If you don’t have zookeeper yet, then you can refer to the article I wrote about building a zookeeper cluster: […]

5.k8s jenkins integrated k8s one-click release case

Article directory Preface 1. jenkins configuration 1.1 jenkins configure git 1.2 jenkins configure maven 1.3 jenkins configuration java 2. Jenkins pipeline configuration 2.1. New items 2.2 Springboot project configuration git warehouse 2.3 springboot project configuration maven packaging 2.4 System configuration SSH to hadoop1 configuration, which is the master node of k8s 2.6 Springboot project configuration […]

SpringBoot integrates SSM-junit testing

Prerequisite: Create a new springboot module Create an employee case (build) Create employee entity class Create employee control layer Create employee service layer (interface – implementation class) Create employee data layer (interface – implementation class) The above 4 types of files are necessary for using SSM Create employee entity class Attributes get|set method Theoretically speaking, […]

SpringBoot integrates MybatisPlus

1. Configuration file server: port: 8080 #Configure connection database spring: datasource: username: root password: root driver-class-name: com.mysql.cj.jdbc.Driver url: jdbc:mysql://localhost:3306/database name?serverTimezone=Asia/Shanghai &characterEncoding=utf8 type: com.alibaba.druid.pool.DruidDataSource #Configure mybatis-plus mybatis-plus: configuration: #log log-impl: org.apache.ibatis.logging.stdout.StdOutImpl #Display in camel case map-underscore-to-camel-case: true #Scan mapper.xml file mapper-locations: classpath:mapper/*.xml 3.pom file <?xml version=”1.0″ encoding=”UTF-8″?> <project xmlns=”http://maven.apache.org/POM/4.0.0″ xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance” xsi:schemaLocation=”http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd”> <modelVersion>4.0.0</modelVersion> <parent> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-parent</artifactId> […]

Springboot integrates shiro

1. Introduction 1.Apache Shiro is a Java security (permission) framework 2.Shiro makes it very easy to develop good enough applications, and it can not only be used in the JavaSe environment. 3.Shiro can complete: authentication, authorization, encryption, session management, Web integration, caching, etc. 2. SpringBoot integrates Shiro environment construction 1. Import dependencies in pom <dependency> […]

Integrated Activiti-Modeler process designer

Integrated Activiti-Modeler process designer Activiti Modeler is a front-end plug-in for online process design officially provided by Activiti. It can facilitate process designers and developers to draw flow charts, save process models, deploy to process definitions, etc. 1. Material preparation First we need to obtain activiti-explorer.zip, which is only available in activiti-5.22.0. Link: https://pan.baidu.com/s/1zZ8vcjR63_hgzcLl6soiDw Extraction […]