Hacker News new | ask | show | jobs
by bo1024 3172 days ago
Something was bugging me about this, but I had to think hard to figure it out.

The article is largely based on a misguided premise: the idea that URLs should be conceptualized as either names or identifiers. URLs are neither: they are addresses of web pages. The things located at the URL may have names or identifiers, but by design of the web the stuff located at an address is mutable while the address is immutable.

This is an important point because it breaks the analogies to books or bank accounts. A physical copy of Moby Dick is a thing that may be located at a given address, or not. The work of fiction "Moby Dick" has an ISBN number, but the ISBN number is metadata, not an address. A bank account number is also metadata, not an address.

So I get the feeling that URLs should be conceptualized as addresses first and foremost. This isn't a magic bullet for the problem the blog post addresses (how to design URLs) but I think it gives some perspective:

* If the "thing" at the URL will always be conceptually the same "thing", but its name or other metadata may change, it makes sense to assign that thing a unique identifier and use this as part of the URL. (Because the thing with this ID will always be found at this address.)

* If the name of the stuff located at the URL is never going to change, it makes sense to use the name as part of the URL. (Because the stuff with this name will always be found there.)

* "Search results" as discussed in the blog post are a special case of the previous point: if a URL will always contain search results for a certain query, it makes sense to use the name of the query as part of the URL.

* There are also URLs that fall outside the name or identifier paradigms. http://www.ycombinator.com/about/ is the address of a bunch of stuff, which is not necessarily a single coherent thing with either an ID number or a name, but is a very reasonable address at which some content may be located.

Maybe this is all obvious, but to me it really helps think about the issue whereas the blog post confused some things for me, so I thought I'd share.

1 comments

> The things located at the URL may have names or identifiers, but by design of the web the stuff located at an address is mutable while the address is immutable.

But an address is a designator/identifier.

I'm not sure about that. An address makes no promises (technically speaking) about what you will find at that address.

You can give an object some metadata like "current address", but that's different from saying the address alone identifies the object.

> I'm not sure about that. An address makes no promises (technically speaking) about what you will find at that address.

I don't see how that's relevant. An address, in principle, merely designates a particular location, perhaps physical like a street address, or logical like a memory address. In the context of a search or lookup, you can obtain what's contained at that address.

Similarly, a URL designates a particular resource location, as exemplified by its full name, Uniform Resource Locator. In the context of a client/server request, you can similarly obtain a representation of what's at a URL.