Stardog 4.2.1 stop working geospatial

2 views
Skip to first unread message

s.ar...@geophy.com

unread,
Dec 14, 2016, 9:49:41 AM12/14/16
to Stardog
This query works on version 4.2 but not on 4.2.1



SELECT * WHERE {    ?g geo:asWKT ?gWKT .    FILTER (geof:within(?g, "POLYGON((0 0, 1 0, 1 1, 0 1, 0 0))"^^geo:wktLiteral)) }

 
Caused by: java.text.ParseException: Unknown Shape definition [POLYGON((0 0, 1 0, 1 1, 0 1, 0 0))]
at com.spatial4j.core.io.WktShapeParser.parse(WktShapeParser.java:90) ~[spatial4j-0.4.1.jar:?]
at com.spatial4j.core.context.SpatialContext.readShapeFromWkt(SpatialContext.java:294) ~[spatial4j-0.4.1.jar:?]
at com.complexible.stardog.spatial.db.query.WithinPropertyFunction$WithinOperator.compute(WithinPropertyFunction.java:296) ~[stardog-spatial-core-4.2.1.jar:?]
at com.complexible.stardog.spatial.db.query.SpatialOperator.computeNext(SpatialOperator.java:108) ~[stardog-spatial-core-4.2.1.jar:?]
at com.complexible.stardog.spatial.db.query.SpatialOperator.computeNext(SpatialOperator.java:38) ~[stardog-spatial-core-4.2.1.jar:?]
at com.complexible.common.collect.AbstractSkippingIterator.tryToComputeNext(AbstractSkippingIterator.java:143) ~[stardog-utils-common-4.2.1.jar:?]
at com.complexible.common.collect.AbstractSkippingIterator.hasNext(AbstractSkippingIterator.java:130) ~[stardog-utils-common-4.2.1.jar:?]
at com.complexible.stardog.plan.eval.operator.impl.SingleProjectionOp.computeNext(SingleProjectionOp.java:83) ~[stardog-4.2.1.jar:?]
at com.complexible.stardog.plan.eval.operator.impl.SingleProjectionOp.computeNext(SingleProjectionOp.java:33) ~[stardog-4.2.1.jar:?]
at com.complexible.common.collect.AbstractSkippingIterator.tryToComputeNext(AbstractSkippingIterator.java:143) ~[stardog-utils-common-4.2.1.jar:?]
at com.complexible.common.collect.AbstractSkippingIterator.hasNext(AbstractSkippingIterator.java:130) ~[stardog-utils-common-4.2.1.jar:?]
at com.complexible.stardog.plan.eval.operator.impl.SliceOp._hasNext(SliceOp.java:87) ~[stardog-4.2.1.jar:?]
at com.complexible.stardog.plan.eval.operator.impl.SliceOp.computeNext(SliceOp.java:95) ~[stardog-4.2.1.jar:?]
at com.complexible.stardog.plan.eval.operator.impl.SliceOp.computeNext(SliceOp.java:26) ~[stardog-4.2.1.jar:?]
at com.complexible.common.collect.AbstractSkippingIterator.tryToComputeNext(AbstractSkippingIterator.java:143) ~[stardog-utils-common-4.2.1.jar:?]
at com.complexible.common.collect.AbstractSkippingIterator.hasNext(AbstractSkippingIterator.java:130) ~[stardog-utils-common-4.2.1.jar:?]
at com.complexible.stardog.plan.eval.operator.util.AutoCloseOperator.computeNext(AutoCloseOperator.java:115) ~[stardog-4.2.1.jar:?]
at com.complexible.stardog.plan.eval.operator.util.AutoCloseOperator.computeNext(AutoCloseOperator.java:25) ~[stardog-4.2.1.jar:?]
at com.complexible.common.collect.AbstractSkippingIterator.tryToComputeNext(AbstractSkippingIterator.java:143) ~[stardog-utils-common-4.2.1.jar:?]
at com.complexible.common.collect.AbstractSkippingIterator.hasNext(AbstractSkippingIterator.java:130) ~[stardog-utils-common-4.2.1.jar:?]
at com.complexible.stardog.plan.eval.operator.util.OpBasedBindingSetIteration.computeNext(OpBasedBindingSetIteration.java:110) ~[stardog-4.2.1.jar:?]
at com.complexible.stardog.plan.eval.operator.util.OpBasedBindingSetIteration.computeNext(OpBasedBindingSetIteration.java:34) ~[stardog-4.2.1.jar:?]
at com.google.common.collect.AbstractIterator.tryToComputeNext(AbstractIterator.java:143) ~[guava-18.0.jar:?]
at com.google.common.collect.AbstractIterator.hasNext(AbstractIterator.java:138) ~[guava-18.0.jar:?]
at com.complexible.common.rdf.query.IteratorAsTupleQueryResult.hasNext(IteratorAsTupleQueryResult.java:77) ~[stardog-utils-rdf-4.2.1.jar:?]
... 15 more
INFO  2016-12-14 15:34:42,271 [Stardog.Executor-1210] com.complexible.stardog.StardogKernel:shutdown(2126): Stardog server 4.2.1 shutdown on 2016-12-14T15:34:42.271+0100.

Zachary Whitley

unread,
Dec 14, 2016, 9:52:48 AM12/14/16
to Stardog
Did you possibly forget to install JTS?

--
-- --
You received this message because you are subscribed to the C&P "Stardog" group.
To post to this group, send email to sta...@clarkparsia.com
To unsubscribe from this group, send email to
stardog+unsubscribe@clarkparsia.com
For more options, visit this group at
http://groups.google.com/a/clarkparsia.com/group/stardog?hl=en
---
You received this message because you are subscribed to the Google Groups "Stardog" group.
To unsubscribe from this group and stop receiving emails from it, send an email to stardog+unsubscribe@clarkparsia.com.

Stephen Nowell

unread,
Dec 14, 2016, 9:53:16 AM12/14/16
to sta...@clarkparsia.com
Samur,

In order to use Polygons, make sure that you have the JTS jars imported properly into your 4.2.1 server folder as per [1].

Cheers,
Stephen

[1] http://docs.stardog.com/#_enhanced_polygons
--
-- --
You received this message because you are subscribed to the C&P "Stardog" group.
To post to this group, send email to sta...@clarkparsia.com
To unsubscribe from this group, send email to

Samur Araujo

unread,
Dec 14, 2016, 10:23:49 AM12/14/16
to sta...@clarkparsia.com
The JTS JAR is correctly configured. 

How do I check if it was loaded properly?

--
-- --
You received this message because you are subscribed to the C&P "Stardog" group.
To post to this group, send email to sta...@clarkparsia.com
To unsubscribe from this group, send email to
---
You received this message because you are subscribed to a topic in the Google Groups "Stardog" group.
To unsubscribe from this topic, visit https://groups.google.com/a/clarkparsia.com/d/topic/stardog/MfXN58rgxUE/unsubscribe.
To unsubscribe from this group and all its topics, send an email to stardog+unsubscribe@clarkparsia.com.



--
Senior Data Scientist 
Geophy 

Nieuwe Plantage 54-55
2611XK  Delft
+31 (0)70 7640725 

1 Fore Street
EC2Y 9DT  London
+44 (0)20 37690760

Samur Araujo

unread,
Dec 14, 2016, 10:33:01 AM12/14/16
to sta...@clarkparsia.com
Problem was fixed. 

The stardog.properties needs to be in the STARDOG_HOME. 
Reply all
Reply to author
Forward
0 new messages