Neptune Geospatial functionality for SPARQL

0

Rather than bump this question - https://repost.aws/questions/QUdxJeI3dUS7Su2qJ6cmfwRw/geospatial-queries - I thought I'd ask a new one because a few years have elapsed since and I'm interested in SPARQL specifically.

As far as I can see, there's currently no support in Neptune for SPARQL extensions which permit geospatial functionality such as calculating distance between points based on latitude and longitude, finding points within a polygon and so on. I'm sure this would be an extremely valuable feature, whether it took the form of a proprietary SPARQL extension or support for the widely-used GeoSPARQL functions. Are there any plans to make these sort of extensions available?

BT_KBS
已提问 2 个月前108 查看次数
1 回答
0

Hi BT_KBS,

Please go through the below steps, I hope it will help to solve your issue.

Current State of Geospatial Support in Neptune

Neptune provides strong support for graph models and queries using both SPARQL and Gremlin, but geospatial functionality is limited. While Gremlin in Neptune supports basic geospatial queries (such as finding points within a circle or bounding box), these capabilities are not mirrored in SPARQL.

Workarounds and Alternatives

Given this limitation, there are several approaches you might consider:

External Geospatial Processing:

  • Preprocess Data: You can perform geospatial calculations externally using tools like PostGIS or a custom service, and then store the processed results (e.g., distances or spatial relationships) within Neptune as part of the graph data.
  • Hybrid Architectures: Utilize AWS services like Lambda or Amazon Aurora (with PostGIS) to handle geospatial queries and integrate the results back into your Neptune database.

Using Gremlin for Geospatial Queries:

  • If your use case permits, you might consider using Gremlin instead of SPARQL for queries requiring geospatial functionality. Neptune supports Gremlin geospatial predicates such as within, contains, and intersects for basic geospatial operations.

  • Documentation: For more information on Gremlin's geospatial support in Neptune, you can refer to the Amazon Neptune Gremlin Reference.

Future Prospects:

  • Feature Requests: AWS regularly updates its services based on customer feedback. While there are no official announcements about SPARQL geospatial support in Neptune, you can express your interest through AWS support channels, which could influence the development roadmap.

Documentation links:

https://docs.aws.amazon.com/neptune/latest/userguide/intro.html

https://opengeospatial.github.io/ogc-geosparql/

专家
已回答 2 个月前
profile picture
专家
Sandeep
已审核 2 个月前

您未登录。 登录 发布回答。

一个好的回答可以清楚地解答问题和提供建设性反馈,并能促进提问者的职业发展。

回答问题的准则