SpringBoot - realize image upload | alicloud OSS

Preparation Prepare a virtual machine. The virtual machine doesn't have to use Alibaba cloud, but during the recent outbreak, Alibaba cloud has activities, and students can use it for six months free. I set an alarm clock at 7:50 this morning and then I got up to rob the free virtual machine Openi ...

Posted on Sat, 22 Feb 2020 10:48:49 -0500 by robpoe

I/O stream of Java -- file input / output stream

FileInputStream and FileOutputStream classes The FileInputStream and FileOutputStream classes are used to manipulate disk files. FileInputStream, FileOutputStream. FileInputStream and FileOutputStream classes can read and write files. First create the file object public class Study2 { public static ...

Posted on Sat, 22 Feb 2020 10:28:53 -0500 by chrisranjana

Redis5.x two persistence methods and master-slave replication configuration

Pay attention to the official account number: CoderBuff, reply to "redis" and get the complete version of Redis5.x tutorial PDF. Redis5.x tutorial directory Chapter I preparation Chapter II data types Chapter III orders Chapter IV configuration Chapter 5 Java client (I) Chapter VI affairs Chapter 7 distributed lock Chapter 8 Java cli ...

Posted on Sat, 22 Feb 2020 10:21:27 -0500 by illushinz

java calls JNI to exit abnormally and locate through core

Scene description There are jni calls in java, and all irregular java processes disappear without any exception logs. By analyzing the core file of linux, we can locate the problem in the program. JNI example First, we construct a JNI with an exception. There is an exception in the C function. The following files and comm ...

Posted on Sat, 22 Feb 2020 10:00:56 -0500 by chet139

Code implementation phase

1, Encapsulate database operations: store all database operations in the dao package. (1) using single column pattern to design a tool class for database Connection and provide a Connection object. package dao; import com.mysql.jdbc.jdbc2.optional.MysqlDataSource; import javax.sql.DataSource; impo ...

Posted on Sat, 22 Feb 2020 09:07:01 -0500 by Beyond Reality

MyBatis framework: many to one query, one to many query, ResultMap, dynamic SQL

To write the code in the mybatis framework: Create entity classCreate corresponding interfaceWrite the xml file corresponding to each interfaceWrite test class Prepare the database before one to many and many to one queries Take teachers and students for example Teacher's database CREATE TABLE `teache ...

Posted on Sat, 22 Feb 2020 06:56:30 -0500 by arag0rn

New feature 8 of JDK8 -- parallel flow and Fork/join framework

The streams mentioned above are all serial streams, which are executed on a thread. Next, we introduce two ways to obtain parallel flow 1. Get parallel stream directly Parallel stream is actually a parallel execution stream. It can improve the execution speed of multithreaded tasks through the defa ...

Posted on Sat, 22 Feb 2020 05:42:02 -0500 by jaydeesmalls

IO flow - special operation flow

Special operation flow in IO flow Summary: The special operation flow in IO flow, as the name implies, has its special function; Standard I / O stream Summary: Standard I / O streams are used for keyboard input and printout; that is, the Scanner class and System.out.println(), which we usually u ...

Posted on Sat, 22 Feb 2020 04:52:10 -0500 by drorgo

Common sorting algorithms and their code implementation and related problems

Algorithm learning notes - sorting This is a part of the notes that have been sorted out recently in the learning process. There is no picture demonstration. For more vivid display, please see this Daniel's sorting blog. Animation demonstration of sorting algorithm Some common array sorting metho ...

Posted on Sat, 22 Feb 2020 04:41:10 -0500 by kurdishvoice

spring boot -- an example of file upload and download

As for file upload and download, there are many better components that encapsulate in place for us now, and there are few things we need to do in practice. But here we will introduce the file upload based on the Commons file upload component and the file download based on the file stream. File upload ...

Posted on Sat, 22 Feb 2020 04:35:15 -0500 by dscuber9000