HTTPS process Brief

The most important thing in HTTPS is SSL handshake. SSL handshake is used to negotiate the secret key and encryption suite. The overall process is as follows: The client tells the server to use HTTPS protocol; The server returns its certificate and public key to the client; Client verifies the validity of public key and certificate; After pass ...

Added by jmurch on Sun, 03 Nov 2019 06:46:45 +0200

Using Nginx echo module to test location matching priority

The nginx echo module allows users to directly output strings in nginx, which is convenient for users to debug when configuring nginx. Document address: https://www.nginx.com/resources/wiki/modules/echo/ , github address: https://github.com/openresty/echo-nginx-module 1, installation Here, take nginx version: nginx/1.10.3 (Ubuntu) of ubuntu ...

Added by sufian on Sun, 03 Nov 2019 06:01:12 +0200

Java serialization 47 polymorphism basic syntax, function

1. Polymorphic grammar 1. If there is no inheritance relationship between two classes, polymorphism cannot be used for compilation. 2. No matter upward or upward transformation, inheritance is needed. 3. When is the downward transformation needed? When the called method or property is specific to a subtype and does not exist in the parent t ...

Added by mrmachoman on Sun, 03 Nov 2019 01:23:02 +0200

Java thread's six states and examples

Java threads have six states since jdk1.5. NEW: a thread that has not been started is in this state. RUNNABLE: the thread executing in the Java virtual machine is in this state. BLOCKED: the thread waiting for the monitor lock to be BLOCKED is in this state. WAITING: a thread that waits indefinitely for another thr ...

Added by Anti-Moronic on Sun, 03 Nov 2019 00:13:12 +0200

[system log note 1] - rich Log4j2 configuration

Log4j should be more familiar to you. Log4j2 is a relatively large upgrade of log4j. The bottom layer uses disruptor rewriting to optimize the asynchronous output log, which greatly improves the performance. The author has made performance comparison among log4j, logback and log4j2, and log4j2 does show absolute advantages. Not much to say, the ...

Added by npereira on Sat, 02 Nov 2019 22:03:08 +0200

java code to obtain the code of administrative division of National Bureau of Statistics

import java.io.BufferedReader; import java.io.InputStreamReader; import java.net.CookieHandler; import java.net.CookieManager; import java.net.CookiePolicy; import java.net.HttpURLConnection; import java.net.URL; import java.nio.charset.Charset; import java.util.List; /** Obtain administrative divisions from the National Bureau of Statistics N ...

Added by milesap on Sat, 02 Nov 2019 18:31:17 +0200

Talk about SizeBlockingQueue of Elasticsearch

order This paper focuses on the SizeBlockingQueue of elastic search SizeBlockingQueue elasticsearch-7.0.1/server/src/main/java/org/elasticsearch/common/util/concurrent/SizeBlockingQueue.java public class SizeBlockingQueue<E> extends AbstractQueue<E> implements BlockingQueue<E> { private final BlockingQueue<E> queue; ...

Added by shortysbest on Fri, 01 Nov 2019 19:01:44 +0200

php records which fields have been modified in the database change log

Sometimes it is very useful for background management, especially personnel management to record the user's behavior log. The log can be used to trace something operated by someone. However, it's not easy to modify a field for a table, so I come up with a way. Here's how to do it. I. need to create a data first CREATE TABLE `hanchao_change_lo ...

Added by beaudoin on Thu, 31 Oct 2019 15:40:46 +0200

Introduction to ORM framework SQLAlchemy

Related information/Official website address 1. Install sqlalchemy and check the version Execute the following statement under the command line to install: pip install SQLAlchemy View version after installation: import sqlalchemy print(sqlalchemy.__version__) In addition, PyMySQL needs to be installed, otherwise an error of modulenotfounderr ...

Added by prasad_deba on Thu, 31 Oct 2019 11:00:31 +0200

SQL statement precompile (query)

SQL statement precompile Pre compilation of SQL statements can prevent SQL injection and improve security because SQL statements have been precompiled before the program runs. Before the first operation of the database, SQL statements have been analyzed, compiled and optimized by the database. The corre ...

Added by Scummy12 on Thu, 31 Oct 2019 10:05:39 +0200