Another way to write Spring MVC interface

1. Preface In general, the paradigm for writing Spring MVC interface is as follows: @RestController @RequestMapping("/v1/userinfo") public class UserInfoController { @GetMapping("/foo") public String foo() { return "felord.cn"; } } Today, I'm going to use the new Functional Endpoints introduced by Spring 5 to play. Sp ...

Added by mynameisbob on Fri, 15 May 2020 07:48:02 +0300

ThreadPoolExecutor Source Analysis-execute() Method

Preface The previous two articles paved the way for analyzing thread pool sources Bit Operations in the Java ThreadPoolExecutor ThreadPool ThreadPoolExecutor Source Analysis Foundation - How ThreadPool works Look back at what you've said before (you need to know it beforehand): Several states of thread pool RUNNING, SHUTDOWN, etc. Switching ...

Added by Zack on Thu, 14 May 2020 19:13:18 +0300

Illustrate IO models and related technologies for Linux

Blocking IO Model (Blocking I/O) The Linux kernel initially provides read and write blocking operations. When a client connects, a corresponding file descriptor (0 standard input, 1 standard output, 2 standard error output) is generated in the file descriptor directory of the corresponding process (/proc/process number/fd), such as FD 8, FD 9 ...

Added by eulalyn09 on Sun, 10 May 2020 11:54:46 +0300

18 examples take you to master Java 8 date time processing!

Author: Pang xiansen https://juejin.im/post/5a795bad6fb9a0634f407ae5 Java 8 introduces a new date time API. In the tutorial, we will learn how to use the new API through some simple examples. The way Java deals with date, calendar and time has always been criticized by the community. Setting java.util.Date as a variable type and the non thre ...

Added by matthewc on Wed, 06 May 2020 08:54:37 +0300

Method encapsulation of summing, filtering and multi sorting of js array objects

In the process of data report and background management system development, we often encounter the operation of summing and filtering the data we get. In fact, it is not difficult to realize them, but if multiple pages need to do these operations, it is troublesome to write a little bit more. When some code repetitio ...

Added by Dollar on Mon, 04 May 2020 19:39:58 +0300

Registration form of computer room charging system

Preface The charge system of the computer room has entered the registration window. I feel that the computer room is the same as many places of the students, but because the computer room is completed by myself, and the help from the outside is less, I have to sort out the logic by myself and design the code by myself (most of them are to fin ...

Added by Stevis2002 on Sun, 03 May 2020 03:38:23 +0300

Java learning note 28 (set framework II: Iterator iterator)

Iterator interface, translated into Chinese is iterator The concept of iterator is generally explained as follows: There are many collections in java. There are various internal storage methods and different ways to get them. Can there be a general way to get them? This is similar to for loop traversal, General method of obtaining: before takin ...

Added by alasdair12 on Sat, 02 May 2020 10:32:50 +0300

Linux learning notes - supplemental

1.find command Command format: find directory condition value 1.find -name find /etc/ -name passwd ##Find the file named passwd under / etc 2.find -user -group -a -o -not find /mnt -group root find /mnt -user westos find /mnt -group root -user student ##and find /mnt -group root -a -user student ##Both c ...

Added by GaryC on Fri, 01 May 2020 11:04:56 +0300

ACdream 1099, the largest number in the sequence

To find the K-th largest number, we often think of the chairman tree, but the chairman tree code is complex and the operation is complex. If we simply find the K-th-largest number in the sequence, then it seems to have advantages and disadvantages, like ACdream 1099 This problem is to find the number with the largest K in the sequence, and if ...

Added by karnetics on Thu, 30 Apr 2020 13:42:03 +0300

Partition Mysql by day

1, Table structure CREATE TABLE `visitor_log` ( `id` bigint(20) NOT NULL AUTO_INCREMENT, `uicode` varchar(32) NOT NULL, `actcode` varchar(10) DEFAULT '', `F` varchar(30) DEFAULT '', `uid` bigint(20) NOT NULL, `element` varchar(32) DEFAULT '', `create_time` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00 ...

Added by GremlinP1R on Thu, 30 Apr 2020 10:47:10 +0300