官术网_书友最值得收藏!

UUIDs and timestamps

While there are several algorithms that can be used to generate UUIDs, the Version 1 UUID has an additional useful property: part of the UUID encodes the timestamp at which the UUID is generated. This timestamp can be extracted from the full UUID, meaning that it's possible to know exactly when any Version 1 UUID was generated.

Cassandra's timeuuid type lets us capitalize on that property. Cassandra is aware of the structure of a timeuuid and is able to both convert timestamps into UUIDs and extract the creation timestamp from a UUID. As we'll soon see, Cassandra can also sort our rows by their creation time using the timestamps encoded in the UUIDs.

主站蜘蛛池模板: 托里县| 肇东市| 西城区| 临武县| 汝阳县| 大连市| 大姚县| 高邑县| 新竹县| 凯里市| 屏南县| 昭觉县| 台安县| 平原县| 宜章县| 长沙县| 闸北区| 博爱县| 西丰县| 酒泉市| 陆川县| 五峰| 准格尔旗| 东兴市| 乳源| 壶关县| 保定市| 固原市| 称多县| 河池市| 明溪县| 怀仁县| 康乐县| 广州市| 铜陵市| 南宫市| 常宁市| 玉门市| 景洪市| 阳朔县| 安乡县|