Tagged articles
27 articles
Page 1 of 1
Architect
Architect
Jun 14, 2024 · Backend Development

Analysis and Implementation of Various WeChat Red Packet Distribution Algorithms in PHP

This article examines three main algorithms—ordinary random, double‑mean, and line‑segment—for distributing WeChat red packets, provides PHP implementations, validates the randomness of array_rand, and compares their performance to guide developers in choosing a fair and efficient solution.

PHPbackend-developmentrandom algorithm
0 likes · 11 min read
Analysis and Implementation of Various WeChat Red Packet Distribution Algorithms in PHP
DevOps
DevOps
Jun 12, 2024 · Backend Development

Analysis and Implementation of Various WeChat Red Packet Distribution Algorithms in PHP

This article examines four common WeChat red packet distribution algorithms—simple random, double‑mean, line‑segment division, and array_rand optimization—explaining their principles, PHP implementations, performance characteristics, and how to verify randomness, providing code samples and comparative analysis for developers.

BackendPHPalgorithm
0 likes · 13 min read
Analysis and Implementation of Various WeChat Red Packet Distribution Algorithms in PHP
Tencent Cloud Developer
Tencent Cloud Developer
May 23, 2024 · Backend Development

How WeChat Red‑Packet Random Algorithms Work: Simple Random, Double‑Mean & Segment Split

This article examines the main algorithms behind WeChat's red‑packet distribution—plain random, double‑mean, and segment‑split (including an optimized version), explains their PHP implementations, validates array_rand's randomness, and compares their performance and fairness through code examples and timing tests.

PHParray_randperformance
0 likes · 12 min read
How WeChat Red‑Packet Random Algorithms Work: Simple Random, Double‑Mean & Segment Split
Su San Talks Tech
Su San Talks Tech
Nov 2, 2023 · Backend Development

How WeChat Powers Group Chats and Red Packets: Inside the Backend Architecture

This article dissects the design of WeChat's group chat system, covering functional and non‑functional requirements, high‑level component architecture, database schemas, face‑to‑face group creation, real‑time messaging, red‑packet algorithms, and Go code implementation, revealing how massive concurrency, performance, and storage challenges are solved.

Backend ArchitectureGoSystem Design
0 likes · 22 min read
How WeChat Powers Group Chats and Red Packets: Inside the Backend Architecture
Java High-Performance Architecture
Java High-Performance Architecture
Jun 14, 2022 · Backend Development

How WeChat Handled 100 Billion Red Packet Requests During the Spring Festival Gala

This article explains how WeChat engineered a high‑concurrency backend to support billions of shake‑to‑receive red‑packet requests during the Spring Festival Gala, detailing the prototype system, challenges, iterative solutions, and the final production version that processed over 110 billion shakes with peak loads of 14 million requests per second.

Backend ArchitectureLoad TestingWeChat
0 likes · 18 min read
How WeChat Handled 100 Billion Red Packet Requests During the Spring Festival Gala
Wukong Talks Architecture
Wukong Talks Architecture
Apr 23, 2022 · Backend Development

Design and Scaling of a High‑Concurrency Spring Festival Shake‑and‑Red‑Packet System

This article details the architecture, challenges, and solutions behind a high‑traffic Spring Festival shake‑and‑red‑packet system, covering prototype design, bandwidth and request‑rate handling, access clusters, overload protection, and iterative versions that achieved up to 110 billion shakes with peak loads of 14 million requests per second.

BackendScalabilitySystem Design
0 likes · 17 min read
Design and Scaling of a High‑Concurrency Spring Festival Shake‑and‑Red‑Packet System
Tencent Cloud Developer
Tencent Cloud Developer
Jan 29, 2022 · Cloud Computing

How WeChat’s Serverless Cloud Functions Powered Billion-User Red Packet Covers

During the 2022 Chinese New Year, WeChat leveraged Serverless cloud functions and cloud development to handle the explosive demand of red‑packet cover creation, achieving sub‑ten‑thousand‑yuan costs, supporting over 100 million daily calls, and delivering rapid, scalable, and cost‑effective deployment for developers.

Cloud FunctionsCost OptimizationServerless
0 likes · 7 min read
How WeChat’s Serverless Cloud Functions Powered Billion-User Red Packet Covers
Java Backend Technology
Java Backend Technology
Jan 26, 2022 · Backend Development

How to Simulate 100 Million WeChat Red‑Packet Requests on a Single Server

This article details a practical backend engineering experiment that reproduces the massive load of 100 billion WeChat red‑packet requests by simulating one million concurrent users on a single machine, covering target metrics, hardware/software choices, architecture, implementation steps, performance testing, and analysis of the results.

Backend ArchitectureGoLoad Simulation
0 likes · 18 min read
How to Simulate 100 Million WeChat Red‑Packet Requests on a Single Server
Java Interview Crash Guide
Java Interview Crash Guide
Jan 25, 2022 · Backend Development

How to Simulate 10 Billion WeChat Red‑Packet Requests on a Single Server

This article explains how the author designed and implemented a Go‑based backend that can simulate up to 100 million concurrent users and process billions of red‑packet requests, detailing the hardware setup, performance goals, load‑balancing techniques, monitoring, and the results of multi‑stage stress tests.

Golanghigh-concurrencyred packet
0 likes · 17 min read
How to Simulate 10 Billion WeChat Red‑Packet Requests on a Single Server
Kuaishou Tech
Kuaishou Tech
Apr 9, 2021 · Backend Development

Design and Implementation of Red Packet Calculation and Distribution System for Spring Festival Activity

This article details the design of a red packet calculation and distribution system for a Spring Festival promotion, addressing mixed-type packet computation, seamless transition to awarding, distributed task processing, stability guarantees, and successful implementation results.

Batch ProcessingSpring Festivaldistributed computing
0 likes · 12 min read
Design and Implementation of Red Packet Calculation and Distribution System for Spring Festival Activity
Laravel Tech Community
Laravel Tech Community
May 3, 2020 · Backend Development

PHP Implementation of WeChat Red Packet Splitting Algorithm

This article demonstrates a PHP class that implements the WeChat red packet splitting algorithm, explaining the constraints, providing a complete source code example, and showing how to instantiate the class to distribute a total amount into a specified number of packets with a minimum value.

BackendMoney SplittingPHP
0 likes · 6 min read
PHP Implementation of WeChat Red Packet Splitting Algorithm
dbaplus Community
dbaplus Community
Jan 22, 2020 · Backend Development

How to Simulate 100 Billion WeChat Red‑Packet Requests on a Single Server

This article details a practical experiment that reproduces the load of 100 billion WeChat red‑packet (shake‑and‑grab) requests by simulating 1 million concurrent users on a single machine, achieving peak QPS of 60 k and demonstrating the architectural choices, hardware setup, and monitoring techniques required for such high‑throughput backend systems.

GoLoad TestingQPS
0 likes · 18 min read
How to Simulate 100 Billion WeChat Red‑Packet Requests on a Single Server
21CTO
21CTO
Apr 12, 2017 · Cloud Computing

Unlocking 90 W/s Red Packet Peaks: Alibaba’s High‑Performance Local Storage Blueprint

This article explains how Alibaba Cloud designed a high‑performance local storage solution—leveraging Virtio‑blk, SPDK, and NVMe SSDs—to meet the massive peak pressure, ultra‑low latency, and high IOPS demands of the Alipay red‑packet business, and how the technology is now available in the public cloud.

Alibaba CloudNVMeSPDK
0 likes · 12 min read
Unlocking 90 W/s Red Packet Peaks: Alibaba’s High‑Performance Local Storage Blueprint
Architects' Tech Alliance
Architects' Tech Alliance
Feb 7, 2017 · Backend Development

Technical Overview of WeChat Red Packet Distribution System

The article analyzes the massive scale of Chinese New Year red‑packet activity on WeChat, presents usage statistics, and explains the backend architecture—including distributed KV storage, cache‑layer atomic operations, and database transaction handling—that enables high‑throughput red‑packet distribution.

Backend ArchitectureCacheWeChat
0 likes · 5 min read
Technical Overview of WeChat Red Packet Distribution System
Architecture Digest
Architecture Digest
Jan 25, 2017 · Databases

Design and High‑Availability Architecture of the WeChat Red Packet Storage Layer

The article explains how WeChat’s Red Packet service scales to billions of transactions by employing front‑end traffic control, stateless CGI, caching, asynchronous processing, and a highly available MySQL‑based storage layer featuring read/write separation, sharding, hot‑cold data segregation, and multi‑active cross‑region deployment.

WeChatmysqlred packet
0 likes · 10 min read
Design and High‑Availability Architecture of the WeChat Red Packet Storage Layer
21CTO
21CTO
Apr 23, 2016 · Backend Development

How WeChat Processed 1.4 B Red Packets per Second: Architecture & Key Lessons

This article examines the massive 2015 WeChat Red Packet traffic, detailing its core functions, system challenges, cross‑region networking, lossy service design, set‑model construction, concurrency handling, and data‑consistency strategies that kept the platform stable under extreme load.

Data ConsistencyScalabilityWeChat
0 likes · 9 min read
How WeChat Processed 1.4 B Red Packets per Second: Architecture & Key Lessons
21CTO
21CTO
Apr 16, 2016 · Backend Development

How WeChat Scaled Red Packets for 80 Billion Transactions: Architecture Secrets

This article explains how WeChat redesigned its red‑packet system for the 2016 Chinese New Year, detailing north‑south data separation, multi‑layer caching, asynchronous settlement, high‑concurrency controls, sharding strategies and graceful degradation to handle billions of red‑packet requests.

CacheWeChatbackend scaling
0 likes · 13 min read
How WeChat Scaled Red Packets for 80 Billion Transactions: Architecture Secrets
21CTO
21CTO
Feb 14, 2016 · Backend Development

Implementing WeChat Red Packet Random Distribution in PHP

This article explores the logic behind WeChat's red‑packet random algorithm, outlines the required constraints, and provides step‑by‑step PHP code that generates fair, varied payouts for a fixed total amount among multiple recipients.

BackendPHPWeChat
0 likes · 6 min read
Implementing WeChat Red Packet Random Distribution in PHP
21CTO
21CTO
Dec 17, 2015 · Mobile Development

How to Build an Android Plugin that Auto‑Clicks WeChat Red Packets

This tutorial explains how to create an Android AccessibilityService plugin that automatically detects and clicks all WeChat red packets, detailing its stage‑based logic, screen‑content detection, node handling, queue management, and provides complete source code for educational use.

AccessibilityServiceAndroidWeChat
0 likes · 14 min read
How to Build an Android Plugin that Auto‑Clicks WeChat Red Packets
21CTO
21CTO
Nov 14, 2015 · Backend Development

How WeChat’s Red Packet System Handles Millions of Claims in Real Time

This article explains the backend architecture behind WeChat’s red‑packet feature, detailing how the system stores packet data, uses cache‑level atomic operations for grabbing, separates claim and settlement steps, and ensures high‑throughput, fault‑tolerant processing during peak usage.

BackendCacheDistributed Systems
0 likes · 6 min read
How WeChat’s Red Packet System Handles Millions of Claims in Real Time
21CTO
21CTO
Oct 1, 2015 · Backend Development

Inside WeChat Red Packets: User Motives, UI Flow, and Backend Architecture

This article dissects the entire WeChat red‑packet ecosystem, exploring why users send and grab packets, the entry points, detailed UI screens, database schema, random‑distribution algorithms, caching strategies, and the full front‑end/back‑end interaction sequence.

Backend ArchitectureDatabase designUI flow
0 likes · 25 min read
Inside WeChat Red Packets: User Motives, UI Flow, and Backend Architecture
Art of Distributed System Architecture Design
Art of Distributed System Architecture Design
Feb 27, 2015 · Backend Development

How WeChat Processed Over 1 Billion Red Packets: Backend Architecture and High‑Concurrency Strategies

The article explains how WeChat’s backend handled the massive surge of red‑packet traffic during the 2015 New Year by employing loss‑tolerant services, flexible availability, modular design, asynchronous processing, and overload protection to ensure fast, accurate, and stable user experiences.

Backend ArchitectureLossy ServiceScalability
0 likes · 9 min read
How WeChat Processed Over 1 Billion Red Packets: Backend Architecture and High‑Concurrency Strategies