Re: [OT] Not everything goes well in Ruby land :-)
Andrus Adamchik <[email protected]> Tue, 8 Jan 2008 01:26:48 +0200
| Newsgroups | gmane.comp.web.webobjects.general |
|---|---|
| Message-ID | <[email protected]> |
In the enterprise world where the backend apps and databases are mutant creatures born from generations of uncoordinated and discontinuous programming efforts, I can see that exposing anything can become a liability rather quickly... So that's where that kind of thinking is coming from... For the rest of the world using PK's in URLs is a nice and helpful shortcut :-) Andrus On Jan 8, 2008, at 1:13 AM, Mike Schrag wrote: >> If you expose any "developer private" information, users are going >> to start to rely on it. Consider it UI. Preventing you from making >> changes. I.e. Users could start bookmarking URLs with primary keys >> in them. > But that's perfectly valid, right? RESTful folks would say that > your URL's ARE API ... Especially if you start exposing > ActiveResource-style RESTful XML services, those are going to have > to have SOME sort of ID's in them. Like Chuck said, you could use > some other candidate key, but if you have a sufficient non-OID > candidate key that is going to be basically invariant and act in > this capacity in your API, why not just make that your PK in WO in > the first place? > > ms