rdfshape-api
rdfshape-api copied to clipboard
Timeout when validating resources with large number of arcs
The following attempt of validation (a Shanghai hospital) agains the entity schema of hospitals:
curl -i -X POST -H "Content-type:multipart/form-data" 'http://localhost:8080/api/wikidata/validate' \
--form-string 'item=<http://www.wikidata.org/entity/Q33121756>' \
--form-string 'entitySchema=E187'
gives a timeout because the entity schema E187
refers to country and the country is Chile (Q148
) which seems to take more time than expected to be retrieved and the whole result is a timeout.
Check how we can improve this situation by increasing the time the server waits or using some kind of streaming retrieval.
Looking at logs, there is a warning:
requestTimeout (5 minutes) is >= idleTimeout (1 minute). It is recommended to configure responseHeaderTimeout < requestTimeout < idleTimeout or disable some of them explicitly by setting them to Duration.Inf.