Neptune has a feature of snapshot but instead of taking backup for a single named graph, it takes backup of the complete cluster. Is there anyway it can specifically get the backup of give graph name only?(sparql)
Asked
Active
Viewed 157 times
0

Stanislav Kralin
- 11,070
- 4
- 35
- 58

sundaram Shandilya
- 13
- 3
-
wouldn't it be sufficient to simply select all triples for the graph and save those to disk as Turtle or N-Triples? Or even Trig if you want to have the graph URI serialized as well – UninformedUser Apr 06 '21 at 12:11
-
A query to do it: `CONSTRUCT { ?s ?p ?o } WHERE { GRAPH
{ ?s ?p ?o } }` but there are better ways. e.g. `GET .../endpoint?graph=encoded-thegraph` (this is the SPARQL Graph Store Protocol). – AndyS Apr 06 '21 at 16:53 -
@UninformedUser select statements gives results in form of bindings so it would lead to much more modification and complexity but thanks anyways. – sundaram Shandilya Apr 20 '21 at 03:58
-
1ehm, yes I think I know this - but, I never suggested to use a `SELECT` query, especially not when saying to save it as N-Triples or Turtle. Anyways, if it works please post the solution as answer and accept it to mark as resolved – UninformedUser Apr 20 '21 at 06:39
-
Do any of these solutions work for you? Or are you looking for something that can export a much larger named graph? As in, are you thinking of exporting something in GBs/TBs? Curious, because that would mean that we'd need to brainstorm alternate approaches rather than a front end query. – The-Big-K May 13 '21 at 07:18
-
@The-Big-K Yes the "construct" solution works but issue is with the similar thing you mentioned i.e for size in GBs the variable storing reaches out of memory. Is there anyway to stream the data? – sundaram Shandilya May 17 '21 at 05:52
1 Answers
1
Amazon Neptune now supports the Graph Store Protocol and you can use that as another option.
curl --request GET \
'https://your-neptune-endpoint:port/sparql/gsp/?graph=http%3A//www.example.com/named/graph'

Brad Bebee
- 121
- 1