Extensible Use of COLA and Source Code Research

A Preliminary Study on the Use and Design of cola Extension Points Packaging changes provide flexibility to respond to changes in program requirements. Extension point use Steps: Defines an extension point interface, which can be a validator, converter, entity; must end with ExtPt to represent an extension point. For example, I define an exten ...

Posted by web_noob on Mon, 25 May 2020 10:01:16 -0700

Spring Boot email

How to use Spring Boot to send mail? Spring Boot provides a starter: Spring Boot starter mail for sending mail. Next, let's see how to send mail using Spring Boot.   1, Configure mailbox Here we use 163 Netease email 1. Open SMTP service 2. Set / reset client authorization password   2, Coding implementation 1. Add dependency 1 <!--mail-- ...

Posted by ComputerChip on Sun, 17 May 2020 08:10:16 -0700

Spring verification annotation exception unified processing class

@ControllerAdvice This annotation is the core of unified exception handling Is an Advice that acts on the control layer. This annotation can collect common @ ExceptionHandler, @ InitBinder and @ ModelAttributes methods into one type and apply to all controllers Design ideas in this category: Use the @ ExceptionHandler annotation to c ...

Posted by niekos on Tue, 05 May 2020 12:04:34 -0700

Database design and implementation of comment system

requirement analysis Generally, when we browse the website, we can often see the effect as shown in the figure below (the picture comes from CSDN) This kind of comment is nested layer by layer, and there are several replies to the comment under each comment. This kind of structure is similar to the tree structure. Users can see it at a gla ...

Posted by andco on Mon, 04 May 2020 23:32:08 -0700

Java Implementation of AES ECP PKCS5Padding Encryption and Decryption Tool Class

Java implements an AES/ECB/PKCS5Padding encryption and decryption algorithm tool class Encryption algorithm: AES Mode: ECB Complement method: PKCS5Padding <!-- more --> 1. Tool Classes import lombok.Getter; import lombok.Setter; import lombok.extern.slf4j.Slf4j; import org.springframework.util.Base64Utils; import javax.crypto.Cipher; i ...

Posted by sundawg on Sat, 02 May 2020 22:16:45 -0700

Dragon slaying in Java: how to modify syntax tree

stay Lombok is often used, but do you know how it works? , and Lombok is often used, but do you know how it works? (two) In the two articles, the underlying principle of Lombok is introduced. In fact, it is summed up as a sentence that is realized by changing the abstract syntax tree during compilation. The above two articles have talked about ...

Posted by lemming_ie on Thu, 26 Mar 2020 01:00:48 -0700

Wechat service number silent authorization calling procedure record

Wechat silent authorization process related problem process record Related tools Intranet penetration tool Peanut hull There is free 1G traffic per month, but I need to hold my ID card to take photos and upload. It's too troublesome to use. natapp Easy to use, you need to scan the real name with Alipay. other... Other friends also ...

Posted by farkewie on Wed, 25 Mar 2020 21:04:12 -0700

Exception handling thrown by Spring security oauth2 ExceptionTranslationFilter

The core of Spring security is a set of filter chains. Project launch on autoconfig. The core is the Basic Authentication Filter used to authenticate the user's identity; One filter handles one authentication mode; For the username password authentication filter, Will check if it is a login requ ...

Posted by sharpmac on Mon, 16 Mar 2020 04:37:29 -0700

Chapter 29: Swagger2 unit test Token authentication for spring security integration

Related knowledge Through the previous article, we implemented the use of JWT for interface authentication. When requesting an interface, we need to pass Token in the Header header, so that the backend can identify the requester and judge whether the interface can be requested. JWT interface authenti ...

Posted by Kieran Huggins on Tue, 10 Mar 2020 03:38:13 -0700

Basic steps for JPA to access database

Basic steps for JPA to access database: 1. Define the Table in the Entity class mapping database. The key is @ Entity, @ Table annotation Entity class, @ Entity annotation marks the Entity class of JPA, @ Table annotation indicates which Table in the database corresponds to the Entity class. @The Id a ...

Posted by maxrisc on Mon, 09 Mar 2020 02:59:29 -0700