this post was submitted on 06 Jul 2023
2 points (100.0% liked)

Web Development

0 readers
1 users here now

Icon base by Delapouite under CC BY 3.0 with modifications to add a gradient

founded 1 year ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
[–] canpolat@programming.dev 0 points 1 year ago (3 children)

Here is the programming.dev link: https://programming.dev/post/424984

BTW: Is there a way to use instance links automatically when referring to another instance?

[–] NatoBoram@lemmy.world 0 points 1 year ago (2 children)

And the post on lemmy.world: https://lemmy.world/post/1086238

I think we need UUIDs so we can reference posts across instances

[–] alr@programming.dev 0 points 1 year ago (1 children)

That's a harder proposition than you might think. On the one hand, UUIDs are mathematically guaranteed to be universally unique, which is great. On the other hand, there has to be some way to go from a UUID to a particular post, which suggests a lookup table, but the federated nature of Lemmy basically makes that impossible, since there's no assurance that any instance is aware of any other instance.

[–] NatoBoram@lemmy.world 2 points 1 year ago* (last edited 1 year ago)

which suggests a lookup table

No, it only suggests an additional field in the Post table

since there’s no assurance that any instance is aware of any other instance

It already works like that, but slightly worse because post IDs aren't the same across instances. If you search a newly-created community from another instance here, you just won't find it until it's synced, despite its URI being unique.

Thinking about it, it would be possible to have an URI for posts like post:${id}@instance.com, similar to how user URIs and community URIs are made. This way, you could open /post/1772651 on lemmy.world or post:1772651@lemmy.world on, idk, lemmy.blahaj.zone or something.