
URLs are the uniform way to locate resources - sublemonic
http://adam.heroku.com/past/2010/3/30/urls_are_the_uniform_way_to_locate_resources/
======
Legion
>> "Why don’t we use this format for locating Git resources?"

Because everyone is already doing what your article is telling them to?

I'm sure there's a point to the article, but I found it strange that this
call-to-action style post showed numerous examples of how this is already
being followed, but only one - completely fictional - example of not following
it.

~~~
jacquesm
With the number of upvotes it is getting I am wondering if I'm missing
something.

There must be some amazing revelation in there somewhere.

~~~
andrewtj
You and I both, especially since it's a repost
<http://news.ycombinator.com/item?id=1230768>

~~~
shawndrost
It's a great discussion. Although URLs work quite well, they are not
uniform[1], do not necessarily represent resources[2], and are used for other
purposes than location[3]. Thus, there is room for both sides to be right:
usually, you should treat a URL as everyone else does, but sometimes, it's
smarter not to.

[1] What is uniform about them? They mean different things, depending on the
context in which they are accessed. <http://experts-exchange.com/whatever>
returns different content, depending on your user-agent, your /etc/hosts, your
firewalls and network filters, and so on. Granted, they satisfy a strict
technical sense of the word "uniform", but that meaning shouldn't be conflated
with its english meaning, as it is in this article.

[2] "Unlike many URLs, the mailto scheme does not represent a data object to
be accessed directly." Section 3.5, <http://www.ietf.org/rfc/rfc1738.txt>

[3] The ":password" part of many protocols is authentication, not location.

~~~
jacquesm
[1] experts-exchange is abusing the urls, the fact that they are not 'rest-
ful' does not detract from the URL scheme but from experts-exchange.

[2] Mailto is a URI, not a URL. 1738 has long been superseded.
[http://shadow2531.com/opera/testcases/mailto/modern_mailto_u...](http://shadow2531.com/opera/testcases/mailto/modern_mailto_uri_scheme.html)

So, that leaves '3', which is not exactly secure and most applications that
can use it will also happily ask for a password from the user in interactive
mode when it isn't supplied.

------
gjm11
Previous HN discussion (a couple of months ago):
<http://news.ycombinator.com/item?id=1230768>

------
jacquesm
Isn't this kind of obvious ?

~~~
bradgessler
Yes, but sadly this often gets overlooked. database.yml in Rails is a great
example of that.

~~~
catch23
Though sometimes it is nice to separate things out. Back in the java jdbc
days, I'd always have to look up the exact url format for database connections
because oracle's url connection string would be completely different from
mysql, and still different from postgres.

~~~
rbanffy
> because oracle's url connection string would be completely different from
> mysql, and still different from postgres

And that makes sense. At least a little. Because the way you use to locate a
resource may vary wildly between databases.

And mind you we are only talking about relational ones (the kind JDBC cares
about).

~~~
vsync
> And mind you we are only talking about relational ones (the kind JDBC cares
> about).

It gets even more fun with Java EE where you can have arbitrary resource
adapters. So then you have even non-SQL naming conventions to map within your
application server.

------
hackermom
To be picky, it should be "URIs are the uniform way to locate resources", not
"URLs" - software, web and general computer usage today extends beyond the
typical scheme format of "protocol://address", f.e. handing out a Spotify URI
to someone, clickable in their IRC client, or even directly pastable in their
browser's address field: spotify:track:5IsPWc2uTiVINs3Lfn8s9o

~~~
rbanffy
To be even more picky, "URIs are the uniform way to identify resources" or
"URLs are the uniform way to locate resources"

