Tagged articles

segment allocation

5 articles · Page 1 of 1
Yumin Fish Harvest
Yumin Fish Harvest
Aug 17, 2026 · Backend Development

How to Implement Distributed ID Generation with Segment Mode? A Double‑Buffer Issuer in Practice

The article analyses lock contention caused by per‑request ID generation, derives a segment‑based solution that batches IDs using a configurable step, defines a left‑closed/right‑open interval schema in MySQL, and builds a double‑buffer Java issuer with asynchronous pre‑loading, thorough concurrency handling, testing, and configuration guidelines.

MySQLconcurrencydistributed ID
0 likes · 21 min read
How to Implement Distributed ID Generation with Segment Mode? A Double‑Buffer Issuer in Practice
Java Tech Workshop
Java Tech Workshop
Jul 15, 2026 · Backend Development

Generating Trillions of Unique Order IDs Without Collisions

The article analyzes why simple auto‑increment or timestamp‑based IDs fail at massive scales, compares common distributed ID schemes, and presents an improved Snowflake‑plus‑segment hybrid solution with clock‑rollback protection, automatic machine/room allocation, and production‑grade safeguards for trillion‑level order processing.

MicroservicesMySQLdistributed ID
0 likes · 19 min read
Generating Trillions of Unique Order IDs Without Collisions
Code Farming
Code Farming
Jul 7, 2026 · Backend Development

Four Ways to Ensure Unique IDs After Database Sharding

When a system is split into multiple databases and tables, the article explains the root cause of ID collisions and compares four mainstream ID generation strategies—UUID, database auto‑increment, Snowflake, and segment allocation—detailing their trade‑offs, pitfalls, and selection guidelines for different concurrency levels.

Shardingdistributed IDhigh concurrency
0 likes · 9 min read
Four Ways to Ensure Unique IDs After Database Sharding
Su San Talks Tech
Su San Talks Tech
Aug 30, 2023 · Backend Development

How Tinyid Generates Globally Unique IDs with Segment Allocation

Tinyid is a Didi‑developed distributed ID system that uses a segment‑allocation algorithm to provide globally unique, trend‑increasing long IDs via HTTP or a Java client, supporting multi‑master databases and batch retrieval while offering configurable token‑based access control.

Tinyiddistributed IDjava
0 likes · 12 min read
How Tinyid Generates Globally Unique IDs with Segment Allocation
macrozheng
macrozheng
Sep 19, 2019 · Backend Development

Mastering Distributed ID Generation: From MySQL Auto‑Increment to Snowflake

This article reviews various distributed ID generation strategies—including MySQL auto‑increment tables, multi‑master configurations, segment allocation, Snowflake algorithm, and open‑source solutions like Baidu uid‑generator and Meituan Leaf—highlighting their designs, trade‑offs, and implementation details for high‑performance backend systems.

MySQLdistributed IDsegment allocation
0 likes · 13 min read
Mastering Distributed ID Generation: From MySQL Auto‑Increment to Snowflake