Classic design pattern abstract factory pattern

The abstract factory pattern is used to create a series of related or interdependent objects without specifying specific classes. Like factory mode, it includes the following roles: Factory: abstract factory, declaring factory method, which returns an object of type Product ConcreteFactory: implementation of factory, overriding factory meth ...

Posted by BLeez on Wed, 22 Apr 2020 07:17:33 -0700

Building elastic search 7.4.1 pseudo cluster with Docker

Cluster construction helps us to understand how the cluster works, so that we can better understand the high availability, replica fault tolerance mechanism and high performance of es. Role assignment in es Master node Parameter: node.master: true Because the real master node is elected by multiple nodes with master node qualification. Therefo ...

Posted by pea_1 on Wed, 22 Apr 2020 02:28:21 -0700

Voice communication solution summary

Voice communication scheme System level solutions and self built protocols windows platform, linux platform, embedded linux platform, mcu platform 1. Voice solution of wired communication developed on Embedded Linux This scheme is developed on Embedded Linux. The audio scheme is based on ALSA. The voice communication is related to user ...

Posted by vtb on Tue, 21 Apr 2020 18:12:51 -0700

Java Foundation - Serializable Serialization Interface

Serializable serialization is a means of converting objects into a format that is easy to persist and transfer. It declares that the class is serializable by inheriting an object from the Serializable interface, and then stores and reads objects through ObjectOutputStream and ObjectInputStream stream s, which are briefly described in the commen ...

Posted by Vizor on Tue, 21 Apr 2020 10:16:42 -0700

Spring Security OAuth format token output

Personalized token background Last article Spring Security OAuth personalized token (I) It is mentioned that the default message format returned by oauth2.0 interface is as follows: {     "access_token": "e6669cdf-b6cd-43fe-af5c-f91a65041382",     "token_type": "bearer",     "refresh_token": "da91294d-446c-4a89-bdcf-88aee15a75e8",     " ...

Posted by Mohammad on Tue, 21 Apr 2020 09:24:02 -0700

Elasticsearch simple learning 12: full text retrieval (List or array) of multivalued fields

1, Description In practical application, our code may be a list < string >, which needs to be mapped to the index of elastic search. Many times, different students deal with different methods, some are comma separated, some are using arrays. Which method is more reasonable?! Let's compare. 2, Example 1. Index ##Add an index PUT ...

Posted by drdapoo on Tue, 21 Apr 2020 09:20:07 -0700

MySQL installation tutorial of Docker series

MySQL installation tutorial of Docker series With the previous basic tutorial Common command operation manual of Docker series After that, this blog records a mysql installation tutorial mysql image query command docker search mysql Several key parameters are explained as follows: INDEX docker.io is the official website of docker NAME the NA ...

Posted by Chetan on Tue, 21 Apr 2020 08:48:24 -0700

Realize a simple linked list by yourself

In the near future, I want to learn algorithms, so I started from the list, wrote the following code in association with the basic structure of the list, found some problems in the process of writing, and then gradually improved it. For example, when I first inserted it, I found a null node through circulation and then inserted it. Later, I ...

Posted by abigail on Tue, 21 Apr 2020 07:49:33 -0700

The Java ftp compressed file is packaged into zip and downloaded to the local user through the browser download function

1. Import jar dependency package: ant-1.9.7.jar commons-net-3.3.jar Baidu online: https://pan.baidu.com/s/1u7m5NYans-UK_h8VSEPfbA Extraction code: qy12 2. Create a tool class DownloadFileUtil.java and write the following code: package com.zghky.utils; import java.io.File; import java.io.FileInputStream; import java.io.FileOutputStrea ...

Posted by bdee1 on Tue, 21 Apr 2020 07:08:52 -0700

Spring Boot email and attachments, super practical!

Author: yizhiwazi www.jianshu.com/p/5eb000544dd7 Spring Boot integrated e-mail service is so simple that it can quickly grasp the core logic of e-mail business class and the daily service of enterprise e-mail. What is SMTP? The full name of SMTP is Simple Mail Transfer Protocol, which is a set of specifications used to transfer mail from the ...

Posted by ThinkGeekness on Tue, 21 Apr 2020 02:58:08 -0700