How to adjust the thread pool size using Littler's rule

Littler's rule Ritter's Law derives from queuing theory and is expressed in the following mathematical formulas: L = λW Average number of requests present in the L system. The effective arrival rate for lambda requests.For example: 5/s means that five requests arrive at the system per second. Average wait time for a W request to execute in the ...

Posted on Tue, 26 May 2020 14:28:50 -0400 by MrBillybob

mysql sets default encoding format utf-8

Preface mysql 5.7.20 Demo under mac os Recently, I was a little idle and wanted to go back to the background, so I installed MySQL database. At first, I logged in to mysql, created users, authorized, created databases, created tables and so on. When I insert tables, I found errors in Chinese insertion of mysql. So I ...

Posted on Tue, 26 May 2020 13:23:13 -0400 by jaygattis

Ring Buffer

When we process network packets again, we may put the received network packets into the buffer for further processing. Here I have written a ring buffer in C++ according to my own needs, which is actually an array for simulation. The first header file,'RingBuffer.h', is as follows: #pragma once //The size of the buf ...

Posted on Tue, 26 May 2020 13:20:38 -0400 by SUNNY ARSLAN

One Day Pattern - Observer Mode

1. The concept of observer mode The observer mode, also known as the Publish/Subscribe mode, is one of the behavioral modes that defines a one-to-many dependency that allows multiple observer objects to listen on a topic at the same time.When the state of the subject object changes, all observer objects are notified so that they can update ...

Posted on Tue, 26 May 2020 13:10:46 -0400 by Tristan Wells

[LeetCode] 4 sort the linked list

Title: In the O(n log n) time, we use constant level space complexity to sort the linked list. Ideas: Because the complexity of the topic is O(nlogn), the idea of merging and sorting can be considered. The general steps of merging and sorting are as follows: 1) Take the middle point of the array (linked list) to be sorted and divide it into two ...

Posted on Tue, 26 May 2020 13:05:58 -0400 by lupes

[LeetCode] 21 word Jielong I

subject Given two words (beginWord and endWord) and a dictionary, find the length of the shortest conversion sequence from beginWord to endWord. The conversion should follow the following rules: 1. Only one letter can be changed at a time. 2. The middle word in the conversion process must be the word in the dictionary. explain: If such a conve ...

Posted on Tue, 26 May 2020 11:59:32 -0400 by flit

Java fresh e-commerce platform - purchase order and inventory solution in fresh e-commerce (Applet / APP)

Java fresh e-commerce platform - purchase order and inventory solution in fresh e-commerce (Applet / APP)   Note: this system is aimed at the purchase order in the fresh small program to explain, we know that many fresh e-commerce, such as: Daily excellent fresh, Ding Dong buy vegetables, etc., are committed to 29 minutes must answer an efficie ...

Posted on Tue, 26 May 2020 12:00:48 -0400 by rajah

Network data reading framework - use of OkHttp

Introduction and usage of OkHttp framework effect OkHttp is mainly used for network reading and file upload of data such as String, but it is not good enough in image cache processing, so you need to manually set the cache area Use [take Android Studio for example] 1, Add OkHttp framework In Android Studio, File &r ...

Posted on Tue, 26 May 2020 11:37:25 -0400 by PHP Man

Network data reading framework - use of OkHttp

Introduction and usage of OkHttp framework effect OkHttp is mainly used for network reading and file upload of data such as String, but it is not good enough in image cache processing, so you need to manually set the cache area Use [take Android Studio for example] 1, Add OkHttp framework In Android Studio, File &r ...

Posted on Tue, 26 May 2020 11:29:46 -0400 by ayok

HeartBeat (NFS file mount for Web service hot standby)

The two hosts are backup to each other, and the Web service displays the resources on the NFS file system. Add a Linux 6.8 system as an NFS file server catalog: 1. Complete the basic configuration of HeartBeat 2. Configure server for NFS 3. Configure HeartBeat resource management server to use NFS resources 4. Result test 1. Complete the b ...

Posted on Tue, 26 May 2020 11:20:35 -0400 by steadyguy