docs: add link to second article, add alt text

This commit is contained in:
Corbin Crutchley
2023-01-15 12:56:19 -08:00
parent c4b769c545
commit 4c5c6a37db
2 changed files with 8 additions and 8 deletions

View File

@@ -76,7 +76,7 @@ At the time of writing, [there are 5 different types of UUIDs](https://ietf-wg-u
- [UUIDv1](#UUIDv1) - [UUIDv1](#UUIDv1)
- A machine's network card information + a timestamp - A machine's network card information + a timestamp
- [UUIDv2](#UUIDv2) - [UUIDv2](#UUIDv2)
- It's a long story. - [It's a long story.](/posts/what-happened-to-uuid-v2)
- [UUIDv3](#UUIDv3and5) - [UUIDv3](#UUIDv3and5)
- Encode a string using MD5 - Encode a string using MD5
- [UUIDv4](#UUIDv4) - [UUIDv4](#UUIDv4)
@@ -118,7 +118,7 @@ This data is then converted to raw numerical values and encoded into UUID with t
> I know you mentioned it's a long story with UUIDv2 when outlining the different versions of UUID... Surely it can't be that bad, can it? > I know you mentioned it's a long story with UUIDv2 when outlining the different versions of UUID... Surely it can't be that bad, can it?
No, really, it's a ***long*** story. It's complex enough that I'm writing a second blog post explaining what UUIDv2s are, why they're not widely used, and how they came to be. No, really, it's a ***long*** story. It's complex enough that [I've written a second blog post explaining what UUIDv2s are, why they're not widely used, and how they came to be](/posts/what-happened-to-uuid-v2).
In the meantime, the short version of UUIDv2 is: In the meantime, the short version of UUIDv2 is:
@@ -131,7 +131,7 @@ They're rarely implemented into most UUID libraries and are used even less. This
1) They're not documented as part of the newest UUID specification 1) They're not documented as part of the newest UUID specification
2) Significant pitfalls in UUIDv2's generation schema that **regularly** leads to collision with other generated UUIDv2s 2) Significant pitfalls in UUIDv2's generation schema that **regularly** leads to collision with other generated UUIDv2s
As a result, we won't talk about UUIDv2s anymore today. Stay tuned for an upcoming article outlining them more. As a result, we won't talk about UUIDv2s anymore today. Instead, [I'd encourage you to read the follow-up article to this one if you're interested](/posts/what-happened-to-uuid-v2).
## Namespace Your IDs with UUIDv3 and UUIDv5 {#UUIDv3and5} ## Namespace Your IDs with UUIDv3 and UUIDv5 {#UUIDv3and5}
@@ -272,6 +272,6 @@ While the previous versions of UUID have had some kind of input data, UUIDv4 bre
And that's it; That's all of the UUID versions that are part of the original 2005 specification! Hopefully, this has been helpful in learning about the different UUID versions and when each is useful. And that's it; That's all of the UUID versions that are part of the original 2005 specification! Hopefully, this has been helpful in learning about the different UUID versions and when each is useful.
In the next article, we'll talk about how UUIDs came to be, what happened to UUIDv2, and why you shouldn't use it. [In the next article, we'll talk about how UUIDs came to be, what happened to UUIDv2, and why you shouldn't use it.](/posts/what-happened-to-uuid-v2)
Until then, happy ~~hacking~~ ID generating! Until then, happy ~~hacking~~ ID generating!

View File

@@ -71,7 +71,7 @@ However, there are a few small differences. Namely:
- The "Low Time" is replaced with a "Local Domain Number." - The "Low Time" is replaced with a "Local Domain Number."
![// TODO: Write](./UUIDv2.svg) ![A UUID broken down into "Local Domain Number", a dash, "Mid Time", a dash, "Version", "High Time", a dash, "Variant", "Clock", "Local Domain", a dash, and finally a "MAC Address". An example UUIDv1 might be "000004d2-92e8-21ed-8100-3fdb0085247e"](./UUIDv2.svg)
@@ -122,7 +122,7 @@ Let's explain why this occurs in UUIDv2 but not in UUIDv1. To explain this, let'
Let's look back at the previous article to see how UUIDv1 is structured: Let's look back at the previous article to see how UUIDv1 is structured:
![// TODO: Write](../what-are-uuids/UUIDv1.svg) ![A UUID broken down into "Low Time", a dash, "Mid Time", a dash, "Version", "High Time", a dash, "Variant", "Clock", a dash, and finally a "MAC Address". An example UUIDv1 might be "4e2b4d4c-92e8-11ed-86a8-3fdb0085247e"](../what-are-uuids/UUIDv1.svg)
Here, we use a timestamp of 15 byes. Let's take the example UUIDv1 from that image: Here, we use a timestamp of 15 byes. Let's take the example UUIDv1 from that image:
@@ -174,7 +174,7 @@ This is the same date as the input value! Because of the precision of 12 charact
Now that we've seen how UUIDv1 handles date values let's look one more time at UUIDv2: Now that we've seen how UUIDv1 handles date values let's look one more time at UUIDv2:
![// TODO: Write](./UUIDv2.svg) ![The example UUIDv2 is "000004d2-92e8-21ed-8100-3fdb0085247e"](./UUIDv2.svg)
Here, once again, we can take the original UUID: Here, once again, we can take the original UUID:
@@ -255,7 +255,7 @@ So what does this time encoding have to do with UUID collision?
Well, let's take one last look between UUIDv1 and UUIDv2: Well, let's take one last look between UUIDv1 and UUIDv2:
![// TODO: Write](./UUIDv1vsUUIDv2.svg) ![UUIDv1 and UUIDv2 are very similar, except that UUIDv1 has "Low Time" instead of UUIDv2's "Local Domain Number". In addition, "Clock" has been reduced from 1 character to 3 in UUIDv2 in order for a 2 character long "Local Domain"](./UUIDv1vsUUIDv2.svg)
While the change between `Low Time` and `Local Domain Number` is the most obvious difference between these two - there's one more significant difference: While the change between `Low Time` and `Local Domain Number` is the most obvious difference between these two - there's one more significant difference: