I am attempting to configure stardog to handle geospatial functions. I have been following the instructions and I have placed the properties file as directed in the home folder. I now want to enable geospatial functions. I set spatial.use.jts=true as instructed. I then placed the jts jar in the server classpath. I am not sure exactly which folder this is, so I placed it in the server folder (I also placed it in the server subfolders and also STARDOG_HOME, just to be sure!).
I then tried to run a geospatial function: ?feature geof:nearby(53.3442497253418 -6.240039825439453 2 http://qudt.org/vocab/unit#Kilometer).
and I get an internal server error, which produces the following error in the log (only the first few lines printed here): ERROR 2017-05-30 16:22:47,298 [XNIO-1 task-2] com.complexible.stardog.protocols.http.server.StardogHttpServiceLoader:accept(228): An unexpected exception was handled by the server org.openrdf.query.QueryEvaluationException: com.complexible.stardog.plan.eval.ExecutionException: The database has geospatial functionality disabled, cannot perform spatial queries.
What am I doing wrong, why are geospatial functions still disabled?
If you are using a Community license, geospatial functions are disabled. Using a Developer/Enterprise trial would fix that.
Additionally, you need to set
spatial.enabled=true
in your database's properties, either during db create (stardog-admin db create -n myDb -o spatial.enabled=true --
) or by offlining the db and editing the metadata (stardog-admin metadata set -o spatial.enabled=true -- myDb
)If you are still having issues, feel free to report them in the Stardog Community forum.