How to reduce scan time of Hyperf frame

Reason The Hyperf framework is designed to prevent the proxy cache from not updating after the user updates the component, resulting in a startup error. The following hooks have been added. { "scripts": { "post-autoload-dump": [ "init-proxy.sh" ] } }    The init-proxy.sh script executes the PHP bin / h ...

Posted by aisalen on Tue, 07 Apr 2020 01:16:34 -0700

PHP magic method

Constructors and Destructors __construct constructor Class calls this method every time a new object is created, so it's a good place to do some initialization before using the object. __deconstruct Destructors execute when all references to an object are deleted or when the object is explicitly destroyed. <?php class MyDestructa ...

Posted by Caesar on Mon, 06 Apr 2020 01:57:18 -0700

007. Use of J.U.C locks

1. Lock API 1. Locks package class hierarchy 2. Lock interface Method Signature describe void lock(); Acquire locks (endless) boolean tryLock(); Acquire locks (just try it) boolean tryLock(long time, TimeUnit unit) throws InterruptedException; Acquire locks (out of date) void lockInterruptibly() throws InterruptedException; Acquire ...

Posted by Smasher on Sun, 05 Apr 2020 17:27:36 -0700

linux Installation of nginx, jdk, redis

Because the project needs to apply for a new server, it is necessary to reconfigure the environment. nginx installation: One click installation of four dependencies: yum -y install gcc zlib zlib-devel pcre-devel openssl openssl-devel   Enter / usr/local/src directory and create nginx folder cd /usr/local/src mkdir nginx   Enter the nginx ...

Posted by jasonman1 on Sun, 05 Apr 2020 14:12:46 -0700

Dry | Comic algorithm: LRU from implementation to application-level analysis (first lecture)

Today we share with you the well-known LRU algorithm. The first lecture consists of four sections. Overview of LRU LRU usage LRU implementation Overview of Redis Near LRU Part I: Overview of LRU LRU is an abbreviation for Least Recently Used, translated as least recently used.Its rationale is that "recently used data will remain in use f ...

Posted by verdrm on Sun, 05 Apr 2020 11:46:20 -0700

[Java Series 004] don't underestimate Redis distributed lock

Hello, I'm miniluo. For positions requiring distributed experience, interviewers always like to ask questions about distributed locks. Recently, I have the honor to participate in the company's interview, and I often ask about the knowledge of distributed locks. Most of the candidates' answers are more limited to using, and they have not though ...

Posted by Sekka on Sun, 05 Apr 2020 01:39:05 -0700

Spring cloud gateway dynamic routing

Summary Online project publishing generally has the following schemes: Downtime release Blue green deployment Rolling deployment Grayscale release This kind of release is usually released at night or during major version upgrade. Because it needs to be stopped, now everyone is studying Devops scheme. Blue green deployment requires t ...

Posted by Maq on Sat, 04 Apr 2020 23:15:39 -0700

Analysis of Redis source code -- implementation of adlist

adlist Adlist is one of the basic data structures of Redis. It is a two-way linked list and records the length of the linked list. The iterator of adlist records the iteration node and direction. I think the implementation of list is better than STL Several important structures The implementation of adlist is relatively simp ...

Posted by regexpert on Sat, 04 Apr 2020 09:06:09 -0700

WeChat Third Party Platform Web-wide Publishing Detection

First thanks easyWechat Author, provides a very useful SDK! Next thanks Feishan Snow Leopard Although I took a lot of detours after reading this post (I was too foolish), without this post, I just looked at the WeChat documents and had no idea at all. Finally, greet the author of the WeChat document!!! WeChat posted the detected documen ...

Posted by renesis on Fri, 03 Apr 2020 18:22:05 -0700

User information caching policy

Because the front-end needs user information userInfo, and the back-end modules, such as reports, also need user information, the frequency of query is very high, involving more linked tables. However, the actual system users are small and the data is basically unchanged. For the convenience of each module, it is decided to adopt caching. Choos ...

Posted by Grim... on Fri, 03 Apr 2020 13:30:28 -0700