Tag:queue

  • Summary of the interview questions of the latest PHP senior engineer in large factory in 2020 (3)

    Time:2021-3-1

    Summary of the interview questions of the latest PHP senior engineers in large factories in 2020 (1) Summary of the interview questions of the latest PHP senior engineers in large factories in 2020 (2) 81. A refers to B, and an error is reported. The class in C is repeatedly defined. What’s the problem with […]

  • Linear list (array, linked list, queue, stack) detailed summary

    Time:2021-2-27

    Linear table is a very basic and important data structure array Linked list queue Stack Next, I will make a detailed summary of these four data structures, in which the linked list is implementedMore than ten kindsCommon operations. Hope to help you. 1. Array Array is a linear table data structure. It uses a group […]

  • How to ensure double write consistency between cache and database?

    Time:2021-2-26

    Please raise your head, my princess, or the crown will fall. Distributed cache is an essential component in many distributed applications. However, if you use distributed cache, it may involve double storage and double write of cache and database. As long as you use double write, there will be data consistency problem. So how do […]

  • Implementation details of packaging and process management of rabbitmq based on yii2 (4)

    Time:2021-2-24

    A series of articles: Basic usage encapsulation and queue implementation of rabbitmq based on yii2 (1) Basic usage encapsulation and RPC queue of rabbitmq based on yii2 (2) Basic usage encapsulation and consumer process web management of rabbitmq based on yii2 (3) Implementation details of packaging and process management of rabbitmq based on yii2 (4) […]

  • Go real combat basic use of redis

    Time:2021-2-24

    We have described the creation of redis pool and cluster mode. First, let’s look at the basic code: //Create a connection redisPool := redisClient.ConnectRedisPool() defer redisPool.Close() _, err = redisPool.Ping().Result() if err != nil { logs.Info(“Login/login redis ping error: “, err) } //Set auto increment and expiration time redisPool.Incr(login.Name) redisPool.Expire(login.Name, time.Minute) //Get the value corresponding […]

  • Redis – Chapter 6 – transactions

    Time:2021-2-24

    catalog brief introduction Execution process characteristic case watch brief introduction Transaction, generally refers to what to do or what to do. In computer terminology, a program execution unit that accesses and possibly updates various data items in a database. Execution process Start transaction > command queue > execute transaction. characteristic ① Batch operation in sendingexecBefore […]

  • Pick up the source code of eventserviceprovider

    Time:2021-2-22

    With the previous “Introduction to the use of laravel model events”https://mp.weixin.qq.com/s/XrhDq1S5RC9UdeULVVksoAI have a general ideaEventThe use of. Today we’re going to have a grillEventSource code of. Before we start, we need to say the next twoEventServiceProviderThe differences between them are as follows: App\Providers\EventServiceProvider Illuminate\Events\EventServiceProvider firstApp\Providers\EventServiceProviderMainly the definitioneventandlistenerA second connection; a second connectionIlluminate\Events\EventServiceProvideryesLaravelThe three foundations of […]

  • About Ajax cache and queue small function, not perfect, please give me more advice

    Time:2021-2-22

    Post code first: function ajaxCache(){ //Request result cache var cache = {} //Request queue var queque = [] //Request status var status = false return function (url,data,cb){ var args = JSON.stringify(data) queque.push({ url:url, data:data, callback:cb }) var fn = function () { if(queque.length){ var request = queque.shift() var params = request.data var reqUrl = request.url […]

  • Java three years interview summary, gold nine silver ten, are you ready?

    Time:2021-2-19

    network Why shake hands three times? Three handshake TCP protocol connection process.The reason or purpose is to prove that both the client and the server have the ability to send and receive. principle:The first time: the client sends syn package to the serverThe second time: after receiving, the server sends the sequence number + 1 […]

  • Week 7 of Arts | lowest common ancestor of leetcode | prototype of golang worker pool | Zen of programming

    Time:2021-2-18

    ARTS Arts is an activity launched by Chen Hao in the geek time column. The purpose is to keep learning through sharing. Each person writes an arts every week: algorithm is an algorithm problem, review is to read an English article, technology / tips is to share a small technology, share is to share a […]

  • One line of code to realize the principle of display “transition animation”

    Time:2021-2-17

    The cause of writing this article In the last article, I mentioned how to make the transition animation appear in display, but I didn’t introduce the principle in detail. In order to better let people who want to learn in-depth understanding, so overtime to write this “essay”, I think in the future, or you look […]

  • Getting started with rabbitmq

    Time:2021-2-16

    Message queuing(Message Queue, hereinafter referred to as MQ) is often used in asynchronous system data transfer. If we don’t use MQ, we can only use polling or interface callback [in the application layer], which is not satisfactory in efficiency or coupling. Of course, we can also maintain a long connection between the systems and send […]