Re: query language

hello lászló.

On 2014-09-10, 8:41 , László Lajos Jánszky wrote:
> Why should a REST service not support adhoc queries? Do this feature
> violate any of the REST constraints?

yes it does, if it is not sufficient to GET the representation of some 
resource to understand how to construct such a query. that's why URI 
template was invented, as a way to declaratively represent how a URI can 
be constructed. what URI template does not cover is to also represent 
what the variables in a template mean for a resource (and maybe even 
what kind of data types and value ranges they support), and this is what 
the link description draft is trying to do.

https://tools.ietf.org/html/draft-wilde-link-desc-01

there are of course other ways in which this could be done. but in order 
for constructed URIs to be truly RESTful, there must be something along 
those lines. otherwise there's too much implicit magic when it comes to 
interacting with resources that do accept constructed URIs.

cheers,

dret.

-- 
erik wilde | mailto:dret@berkeley.edu  -  tel:+1-510-2061079 |
            | UC Berkeley  -  School of Information (ISchool) |
            | http://dret.net/netdret http://twitter.com/dret |

Received on Wednesday, 10 September 2014 16:00:26 UTC