I am trying to POST a SPARQL query using the "query via POST directly"
method described in SPARQL 1.1 Protocol ( paragraph 2.1.3)
(
https://www.w3.org/TR/2013/REC-sparql11-protocol-20130321/#query-via-post-direct
)

However I am confused if Virtuoso actually does support this method
I have managed to work both with GET and URL-encoded POST (at the same
/sparql path)
but when trying the direct POST method I get a 409 Invalid Path


curl -i -X POST -H "Content-Type: application/sparql-query" -d 'SELECT *
WHERE { ?s ?p ?o . }' "http://localhost:8890/sparql";

HTTP/1.1 409 Invalid path
Server: Virtuoso/07.20.3215 (Win64) x86_64-generic-win-64
Connection: Keep-Alive
Content-Type: text/html; charset=UTF-8
Date: Wed, 21 Dec 2016 12:09:51 GMT
Accept-Ranges: bytes
Content-Length: 0

Just to make sure it's not a problem on the request side, I launched a Jena
Fuseki instance just for testing, and it appears to work correctly:
 curl -i -X POST -H "Content-Type: application/sparql-query" -d 'SELECT *
WHERE { ?s ?p ?o . }' "http://localhost:3333/mytest/sparql";
HTTP/1.1 200 OK
Date: Wed, 21 Dec 2016 12:14:47 GMT
Fuseki-Request-ID: 2
Cache-Control: must-revalidate,no-cache,no-store
Pragma: no-cache
Content-Type: application/sparql-results+json; charset=utf-8
Transfer-Encoding: chunked

{
  "head": {
    "vars": [ "s" , "p" , "o" ]
  } ,
  "results": {
    "bindings": [

    ]
  }
}




I have tried using Virtuoso VOS 7.20.3215 & 7.20.3217

Now, there have been a couple of threads in the past referencing the same
issue, but unfortunately it was never resolved.

So is it me doing something wrong, is it a bug, or does Virtuoso not
support this method?
Because the " 409 Invalid Path" doesn't make any sense to me.
Note that if I ommit the Content-Type: application/sparql-query header I
simply get back the SPARQL HTML page, so clearly there is something going
wrong but the error message is either wrong or cryptic
------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/intel
_______________________________________________
Virtuoso-users mailing list
Virtuoso-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/virtuoso-users

Reply via email to