uuid

command
v0.0.0-...-2a093ab Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 25, 2020 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

* 1 42 52 64 * +-----------------------------------------------+------------+---------------+ * | timestamp(ms) | workerid | sequence | * +-----------------------------------------------+------------+---------------+ * | 0000000000 0000000000 0000000000 0000000000 0 | 0000000000 | 0000000000 00 | * +-----------------------------------------------+------------+---------------+ * * 1. 41位时间截(毫秒级),注意这是时间截的差值(当前时间截 - 开始时间截)。可以使用约70年: (1L << 41) / (1000L * 60 * 60 * 24 * 365) = 69 * 2. 10位数据机器位,可以部署在1024个节点 * 3. 12位序列,毫秒内的计数,同一机器,同一时间截并发4096个序号

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL