Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't use HTTP POST where GET is appropriate #10

Open
GoogleCodeExporter opened this issue Aug 3, 2015 · 0 comments
Open

Don't use HTTP POST where GET is appropriate #10

GoogleCodeExporter opened this issue Aug 3, 2015 · 0 comments

Comments

@GoogleCodeExporter
Copy link

Looking at http://reference.data.gov.uk/doc/department/dft, when the Run Query 
button is clicked a POST is used to submit the query. However the operation is 
just a lookup. 

To quote his Royness:
"It isn’t RESTful to use POST for information retrieval when that information 
corresponds to a potential resource, because that usage prevents safe 
reusability and the network-effect of having a URI."
http://roy.gbiv.com/untangled/2009/it-is-okay-to-use-post

The SPROT doc does allow for a POST, but :
"The queryHttpGet binding should be used except in cases where the URL-encoded 
query exceeds practical limits, in which case the queryHttpPost binding should 
be used."
http://www.w3.org/TR/rdf-sparql-protocol/

I've not personally encountered a situation where any SPARQL 1.0 query exceeds 
practical limits, and even if it did, surely the solution is for the server to 
be fixed, not for the client to use architecturally broken workarounds.

Copy & paste of the query for the DfT page into the endpoint at 
http://services.data.gov.uk/reference/sparql (note the link provided on the DfT 
page is broken) seems to work fine with a GET.



Original issue reported on code.google.com by [email protected] on 3 Feb 2011 at 8:06

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant