- From: Roy T. Fielding <fielding@gbiv.com>
- Date: Sun, 17 Oct 2004 00:50:32 -0700
- To: Harry Halpin <hhalpin@ibiblio.org>
- Cc: www-tag@w3.org, Mark Baker <distobj@acm.org>
On Oct 16, 2004, at 2:27 PM, Harry Halpin wrote: > Please note that in my original document I was using "representation" > in the manner most people use it, not REST :) That's funny, because as far as I can tell REST uses it the way most people use it. Which of the 10 definitions provided at http://www.wordreference.com/definition/representation.htm did you intend? 8 of them are aspects of what a representation means in REST, with varying degrees of specificity. How that translates into a REST-based architecture (i.e., bits on the wire) is a different thing entirely. > The problem seems to all come from when the idea of resource is > de-anchored from the Web so that a "resource" can mean anything. I have > no problem per se with that, but just am pointing out that some of > the reasons people are looking into ideas such as "information > resource" are because problems of authority and representation > are a lot trickier off the Web than on the Web, or when the two > intermix > such as in the Semantic Web, where we have Web-statements about things > off the Web. No, the problem is that they are exactly the same issues and folks just assume they are different because they don't understand the actual issues faced by current Web implementations of resources and how those issues impact what Web clients can assume about resources. Make Web statements about things on the Web and you have the same problems (and the same solutions) as those things off the Web. REST isn't restricted to information resources. REST is a way of architecting systems that present an informational interface to resources, regardless of the nature of those resources. REST doesn't care how a resource is "implemented", but rather about how the information system responds to requests across an artificially constrained interface. I can create a REST interface to a piano and the architecture doesn't care whether the implementation is a synthesized simulation or a robot pressing ivory. A semantic web system that intends to describe the Web as it is today would be hopelessly broken if it assumes a resource is not a real piano-playing robot merely because one interface is limited to exchanging representations. The people in the same room as the piano are not limited by that interface, even if they are the ones using an information system to control the robot. > I'm going to note that you seem to agree with me that the medical > record > being modified is not just a representation of the same resource, > but a resource in its own right. > >> A representation is not some second-class object that doesn't >> exist outside of its original relation to the resource. If the >> representation is modified then it is simply a modified >> representation, >> which is a *different* resource in its own right. The modification >> has no impact on the original resource unless an action is taken >> (directly or indirectly) on the original resource, after which its >> later representations will reflect the new state. > > So, does it make sense to talk about the modified XML document qua > resource as a representation of a resource, other than itself? No. It *was* a representation of one resource at the time it was generated. It is also a representation of itself (that circular relationship always exists, as should be clear from the name), but "itself" is a different resource from the one that caused it to be generated. > And if the > XML document is just a representation of itself, then > > Representation = XML document > Resource = XML document > > Why bother using the word Representation? Or using two levels of > description? The representation gives you direct causal access to the > resource. The representation *is* the resource. The word "representation" does not describe a class -- it describes a relationship. An analogy would be the set of people "trusted by Harry". Does that set include yourself? Does the set have a significant meaning, even when used in the rare case of a paranoid person who only trusts himself? The representation is *a* resource. Some thing is a representation of some thing -- the word "representation" describes a relationship that existed at one moment in time between a requested resource and the XML document. The fact that, once generated, the representation becomes a separate resource is what proves them not to be the same thing. > Actually, it seems the problem is converse: a resource often seems like > a second-class object that doesn't exist outside of its original > relation > to representations. On the Web, we know a URI identifies a resource. We do? That's news to me. > Off the Web, what identifies a "resource"? How do we know the original > resource except through its representations, or in particular the > representations that are authoritatively given? You mean, like how do I tell that I am actually writing to some person named Harry Halpin? Or, how do I know that my wife is still my wife even though most of her molecules have changed since we married? Or, how do I know that I wasn't transported to a different universe while sleeping last night, and I am now in the Twilight Zone waiting for Mark to get upset and turn me into a bowl of fruit? Some things just aren't worth worrying about. What we can do is observe the world, create expectations about the future based on our past experience, and just operate as if those expectations are true. Basically, the same thing we do on the Web, which is no surprise given that *we* are the same actors whether we are operating a Web browser or talking in a cafe. > On the Web we know we have a resource when we have > a URI, and whoever controls that URI is obviously "authoritative". Umm, actually, neither is true. URIs can be constructed that do not have any utility as an identifier, and some resources have no representations. Frequently, the organization that assigns a URI (theoretically controlling it) isn't the source of its authoritative representations. > Off the > web it's unclear. When the two mix it's just tricky. For example, I > have > two medical records, one in Britain and one in the U.S. Whose more > authoritative? Sounds like two different records to me -- why do you need to ask that question? > And since I don't go to the doctor often, and the medical > record is supposed to be about my health, am I not the ultimate > authority? > But then I don't have medical training....so, where's the clear > resource > and representation distinction in that mess? It seems more a matter of > perspective than objective fact. Again, those are not the same resource -- they aren't even representations of the same resource. Where is the confusion? > Which is why it would probably be better > if the TAG stuck to "Web architecture" and remained as unclear as > possible > about how this works off the Web. When the two intermix, as in the > Semantic Web, ahhh...not really sure, that's why I think this idea of > "information resource" has come up off and on, along with things like > the tdb proposal and Henry Thompson and my ideas on WPNs. > > I think REST is a fine description of the Web, and have a lot of > respect > for it - it clearly works. As a philosophical theory of how the wide > world > outside the Web works it's probably not going to be perfect :) Crikey, it isn't even a perfect description of the Web. It is just a model for the purposes of communication. What I dislike are models that claim to describe the World, and yet aren't even accurate for a little information system like a Web browser. Web browsers are part of this World. ....Roy
Received on Sunday, 17 October 2004 07:51:18 UTC