VIVO Documentation
Page History
...
Code Block | ||||
---|---|---|---|---|
| ||||
update=LOAD <http://myserver.address.xxx/data.rdf> into graph <http://vitro.mannlib.cornell.edu/default/vitro-kb-2> |
Note |
---|
Could you also handle large files by increasing the size limit on POST requests? The Tomcat configuration page says that |
A Python example
...
Increase the default Tomcat maxPostSize
By default, Tomcat sets the default maximum of a POST request to 2 megabytes. If you want to increase this to be able to POST larger sets of triples to VIVO, you can use the maxPostSize
attribute in server.xml
. The example below would increase the maximum to 10 MB. See the Tomcat documentation for more details.
Code Block | ||||
---|---|---|---|---|
| ||||
<Connector port="8080" protocol="HTTP/1.1"
connectionTimeout="20000"
URIEncoding="UTF-8"
redirectPort="8443"
maxPostSize="10485760"/> |
Enabling the API
Note |
---|
Before enabling the SPARQL update handler, you should secure the URL |
...
- uncomment the line references "UseSparqUpdateAPI" in [vitro]/rdf/auth/everytime/permission_config.n3 or
- create an RDF file in the
[vitro]/rdf/auth/everytime
directory that will authorize your site administrators to use the API. Below is an example of such a file, using N3 syntax.
Code Block | ||
---|---|---|
| ||
@prefix auth: <http://vitro.mannlib.cornell.edu/ns/vitro/authorization#> . @prefix simplePermission: <java:edu.cornell.mannlib.vitro.webapp.auth.permissions.SimplePermission#> . # Authorize the ADMIN role to use the SPARQL Update API auth:ADMIN auth:hasPermission simplePermission:UseSparqlUpdateApi . |
...