>>> Can't you do that using HTTP redirects? >>> >>> Client requests /permalink/FOO, and a servlet mounted at /permalink >>> does an HTTP redirects to the actual resource, using whatever >>> mechanism is appropriate based on the semantics of FOO. >> >> Do redirects also work when doing a POST? We would like to post to >> such a URL as well... > > If the use case is: > > -Browser POSTs to the permalink > -Sling redirects > -Browser should now POST the same thing to new location
I am not so much concerned about the browser. The UI is in our control so a simple redirect to the proper URL when the resource is first accessed is certainly possible. I am more concerned about external systems that just have stored one id in their database and now want to look up/augment the information in our system using that id. > I think redirects in POST are no problem with non-browser clients, as > per http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.3 Mhm, I understand that the opposite way: "The action required MAY be carried out by the user agent without interaction with the user if and only if the method used in the second request is GET or HEAD" > Note that I'm not against expanding the resource resolver - but there > might be a simpler and more RESTful way. The problem we face currently is simple: We have information that will be moved frequently in a tree but have the requirement that other systems need to access that information directly (without doing a search). Is a URL like http://x.y.z/UUID/1234.html less REST? For a human it is not as descriptive but for a system that doesn't matter.
