You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@jena.apache.org by Andy Doddington <an...@gmail.com> on 2015/08/17 21:08:42 UTC

Re: Can I save an in-memory Jena Model to a remote Fuseki-managed database?

On 17 Aug 2015, at 19:50, Andy Doddington <an...@googlemail.com> wrote:

Hoping the subject makes my query clear - since I am a total newbie in this area.

I have created a tiny model, using ModelFactory.createDefaultModel() to  create my initially empty model,
which I then populate manually.

So, having done this, is there any way that I can persist this to a Fuseki database running on a remote server?

Thanks for any help,

	Andy D


Re: Can I save an in-memory Jena Model to a remote Fuseki-managed database?

Posted by Andy Seaborne <an...@apache.org>.
On 17/08/15 22:40, Martynas Jusevičius wrote:
> So what are the semantics of POSTing quads and PUTing quads?

Append and replace as per HTTP.

RFC 7231: 4.3.3. POST
...
       - Extending a database through an append operation.
...

(any ordering implied by "extend" is irrelevant for a set of quads)


RFC 7231: 4.3.4.  PUT

    The PUT method requests that the state of the target resource be
    created or replaced with the state defined by the representation
    enclosed in the request message payload.

>
> On Mon, Aug 17, 2015 at 11:32 PM, Andy Seaborne <an...@apache.org> wrote:
>> On 17/08/15 22:21, Martynas Jusevičius wrote:
>>>
>>> Is that an oversight in the GSP spec?
>>
>>
>> Not really - the GET/POST/PUT on the dataset itself is just normal use of
>> HTTP.
>>
>> The "Graph Store Protocol" for managing a graph store.  What it really adds
>> is the naming convention, ?default and ?graph.
>>
>>          Andy
>>
>>
>>>
>>> I had done something similar (which I use as a low-level API):
>>>
>>> https://github.com/Graphity/graphity-core/blob/master/src/main/java/org/graphity/core/util/DataManager.java
>>>
>>>
>>> On Mon, Aug 17, 2015 at 10:16 PM, Andy Seaborne <an...@apache.org> wrote:
>>>>
>>>> On 17/08/15 20:26, Martynas Jusevičius wrote:
>>>>>
>>>>>
>>>>> Andy,
>>>>>
>>>>> I have a related question. What if I have a Dataset at hand, not a
>>>>> Model - how do I send it to a remote Graph Store?
>>>>
>>>>
>>>>
>>>> The SPARQL Graph Store Protocol does not mention this.  Fuseki supports
>>>> REST-ish PUT/POST/GET on the dataset URL.
>>>>
>>>> Currently, you need to send it yourself -- HttpOp.execHttpPost has lots
>>>> for
>>>> support for that e.g. see DatasetGraphAccessorHTTP for sending a model -
>>>> generalise to datasets.
>>>>
>>>> We have been talking about this on dev@
>>>>
>>>>
>>>> http://mail-archives.apache.org/mod_mbox/jena-dev/201508.mbox/%3C55BE6A0B.5020404%40apache.org%3E
>>>>
>>>> where we're talking about bring the remote (and local) interaction
>>>> together
>>>> and whetre I'm suggesting adding the plain-old HTTP ops on teh dataset
>>>> URL.
>>>>
>>>>           Andy
>>>>
>>>>
>>>>>
>>>>> Martynas
>>>>>
>>>>> On Mon, Aug 17, 2015 at 9:19 PM, Andy Seaborne <an...@apache.org> wrote:
>>>>>>
>>>>>>
>>>>>> DatasetAccessor
>>>>>>
>>>>>> This is the API to the SPARQL Graph Store Protocol.
>>>>>>
>>>>>> Model model = ...
>>>>>> DatasetAccessor acc = DatasetAccessorFactory.createHTTP
>>>>>>            ("http://.../datasets/data") ;
>>>>>> acc.add(model) ; // adds to existign data, if any.
>>>>>>
>>>>>> or
>>>>>>
>>>>>> acc.putModel(model) -- which overwrites existing data
>>>>>>
>>>>>>
>>>>>> On 17/08/15 20:11, ajs6f@virginia.edu wrote:
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> There may be a better answer for this, but at the very least, you can
>>>>>>> serialize your triples/quads and use SPARQL Update to send them to
>>>>>>> your
>>>>>>> Fuseki instance.
>>>>>>>
>>>>>>>
>>>>>>> ---
>>>>>>> A. Soroka
>>>>>>> The University of Virginia Library
>>>>>>>
>>>>>>> On Aug 17, 2015, at 3:08 PM, Andy Doddington
>>>>>>> <an...@gmail.com>
>>>>>>> wrote:
>>>>>>>
>>>>>>>>
>>>>>>>> On 17 Aug 2015, at 19:50, Andy Doddington
>>>>>>>> <an...@googlemail.com> wrote:
>>>>>>>>
>>>>>>>> Hoping the subject makes my query clear - since I am a total newbie
>>>>>>>> in
>>>>>>>> this area.
>>>>>>>>
>>>>>>>> I have created a tiny model, using ModelFactory.createDefaultModel()
>>>>>>>> to
>>>>>>>> create my initially empty model,
>>>>>>>> which I then populate manually.
>>>>>>>>
>>>>>>>> So, having done this, is there any way that I can persist this to a
>>>>>>>> Fuseki database running on a remote server?
>>>>>>>>
>>>>>>>> Thanks for any help,
>>>>>>>>
>>>>>>>>            Andy D
>>>>>>>>
>>>>>>>
>>>>>>
>>>>
>>


Re: Can I save an in-memory Jena Model to a remote Fuseki-managed database?

Posted by Martynas Jusevičius <ma...@graphity.org>.
So what are the semantics of POSTing quads and PUTing quads?

On Mon, Aug 17, 2015 at 11:32 PM, Andy Seaborne <an...@apache.org> wrote:
> On 17/08/15 22:21, Martynas Jusevičius wrote:
>>
>> Is that an oversight in the GSP spec?
>
>
> Not really - the GET/POST/PUT on the dataset itself is just normal use of
> HTTP.
>
> The "Graph Store Protocol" for managing a graph store.  What it really adds
> is the naming convention, ?default and ?graph.
>
>         Andy
>
>
>>
>> I had done something similar (which I use as a low-level API):
>>
>> https://github.com/Graphity/graphity-core/blob/master/src/main/java/org/graphity/core/util/DataManager.java
>>
>>
>> On Mon, Aug 17, 2015 at 10:16 PM, Andy Seaborne <an...@apache.org> wrote:
>>>
>>> On 17/08/15 20:26, Martynas Jusevičius wrote:
>>>>
>>>>
>>>> Andy,
>>>>
>>>> I have a related question. What if I have a Dataset at hand, not a
>>>> Model - how do I send it to a remote Graph Store?
>>>
>>>
>>>
>>> The SPARQL Graph Store Protocol does not mention this.  Fuseki supports
>>> REST-ish PUT/POST/GET on the dataset URL.
>>>
>>> Currently, you need to send it yourself -- HttpOp.execHttpPost has lots
>>> for
>>> support for that e.g. see DatasetGraphAccessorHTTP for sending a model -
>>> generalise to datasets.
>>>
>>> We have been talking about this on dev@
>>>
>>>
>>> http://mail-archives.apache.org/mod_mbox/jena-dev/201508.mbox/%3C55BE6A0B.5020404%40apache.org%3E
>>>
>>> where we're talking about bring the remote (and local) interaction
>>> together
>>> and whetre I'm suggesting adding the plain-old HTTP ops on teh dataset
>>> URL.
>>>
>>>          Andy
>>>
>>>
>>>>
>>>> Martynas
>>>>
>>>> On Mon, Aug 17, 2015 at 9:19 PM, Andy Seaborne <an...@apache.org> wrote:
>>>>>
>>>>>
>>>>> DatasetAccessor
>>>>>
>>>>> This is the API to the SPARQL Graph Store Protocol.
>>>>>
>>>>> Model model = ...
>>>>> DatasetAccessor acc = DatasetAccessorFactory.createHTTP
>>>>>           ("http://.../datasets/data") ;
>>>>> acc.add(model) ; // adds to existign data, if any.
>>>>>
>>>>> or
>>>>>
>>>>> acc.putModel(model) -- which overwrites existing data
>>>>>
>>>>>
>>>>> On 17/08/15 20:11, ajs6f@virginia.edu wrote:
>>>>>>
>>>>>>
>>>>>>
>>>>>> There may be a better answer for this, but at the very least, you can
>>>>>> serialize your triples/quads and use SPARQL Update to send them to
>>>>>> your
>>>>>> Fuseki instance.
>>>>>>
>>>>>>
>>>>>> ---
>>>>>> A. Soroka
>>>>>> The University of Virginia Library
>>>>>>
>>>>>> On Aug 17, 2015, at 3:08 PM, Andy Doddington
>>>>>> <an...@gmail.com>
>>>>>> wrote:
>>>>>>
>>>>>>>
>>>>>>> On 17 Aug 2015, at 19:50, Andy Doddington
>>>>>>> <an...@googlemail.com> wrote:
>>>>>>>
>>>>>>> Hoping the subject makes my query clear - since I am a total newbie
>>>>>>> in
>>>>>>> this area.
>>>>>>>
>>>>>>> I have created a tiny model, using ModelFactory.createDefaultModel()
>>>>>>> to
>>>>>>> create my initially empty model,
>>>>>>> which I then populate manually.
>>>>>>>
>>>>>>> So, having done this, is there any way that I can persist this to a
>>>>>>> Fuseki database running on a remote server?
>>>>>>>
>>>>>>> Thanks for any help,
>>>>>>>
>>>>>>>           Andy D
>>>>>>>
>>>>>>
>>>>>
>>>
>

Re: Can I save an in-memory Jena Model to a remote Fuseki-managed database?

Posted by Andy Seaborne <an...@apache.org>.
On 17/08/15 22:21, Martynas Jusevičius wrote:
> Is that an oversight in the GSP spec?

Not really - the GET/POST/PUT on the dataset itself is just normal use 
of HTTP.

The "Graph Store Protocol" for managing a graph store.  What it really 
adds is the naming convention, ?default and ?graph.

	Andy

>
> I had done something similar (which I use as a low-level API):
> https://github.com/Graphity/graphity-core/blob/master/src/main/java/org/graphity/core/util/DataManager.java
>
>
> On Mon, Aug 17, 2015 at 10:16 PM, Andy Seaborne <an...@apache.org> wrote:
>> On 17/08/15 20:26, Martynas Jusevičius wrote:
>>>
>>> Andy,
>>>
>>> I have a related question. What if I have a Dataset at hand, not a
>>> Model - how do I send it to a remote Graph Store?
>>
>>
>> The SPARQL Graph Store Protocol does not mention this.  Fuseki supports
>> REST-ish PUT/POST/GET on the dataset URL.
>>
>> Currently, you need to send it yourself -- HttpOp.execHttpPost has lots for
>> support for that e.g. see DatasetGraphAccessorHTTP for sending a model -
>> generalise to datasets.
>>
>> We have been talking about this on dev@
>>
>> http://mail-archives.apache.org/mod_mbox/jena-dev/201508.mbox/%3C55BE6A0B.5020404%40apache.org%3E
>>
>> where we're talking about bring the remote (and local) interaction together
>> and whetre I'm suggesting adding the plain-old HTTP ops on teh dataset URL.
>>
>>          Andy
>>
>>
>>>
>>> Martynas
>>>
>>> On Mon, Aug 17, 2015 at 9:19 PM, Andy Seaborne <an...@apache.org> wrote:
>>>>
>>>> DatasetAccessor
>>>>
>>>> This is the API to the SPARQL Graph Store Protocol.
>>>>
>>>> Model model = ...
>>>> DatasetAccessor acc = DatasetAccessorFactory.createHTTP
>>>>           ("http://.../datasets/data") ;
>>>> acc.add(model) ; // adds to existign data, if any.
>>>>
>>>> or
>>>>
>>>> acc.putModel(model) -- which overwrites existing data
>>>>
>>>>
>>>> On 17/08/15 20:11, ajs6f@virginia.edu wrote:
>>>>>
>>>>>
>>>>> There may be a better answer for this, but at the very least, you can
>>>>> serialize your triples/quads and use SPARQL Update to send them to your
>>>>> Fuseki instance.
>>>>>
>>>>>
>>>>> ---
>>>>> A. Soroka
>>>>> The University of Virginia Library
>>>>>
>>>>> On Aug 17, 2015, at 3:08 PM, Andy Doddington <an...@gmail.com>
>>>>> wrote:
>>>>>
>>>>>>
>>>>>> On 17 Aug 2015, at 19:50, Andy Doddington
>>>>>> <an...@googlemail.com> wrote:
>>>>>>
>>>>>> Hoping the subject makes my query clear - since I am a total newbie in
>>>>>> this area.
>>>>>>
>>>>>> I have created a tiny model, using ModelFactory.createDefaultModel() to
>>>>>> create my initially empty model,
>>>>>> which I then populate manually.
>>>>>>
>>>>>> So, having done this, is there any way that I can persist this to a
>>>>>> Fuseki database running on a remote server?
>>>>>>
>>>>>> Thanks for any help,
>>>>>>
>>>>>>           Andy D
>>>>>>
>>>>>
>>>>
>>


Re: Can I save an in-memory Jena Model to a remote Fuseki-managed database?

Posted by Martynas Jusevičius <ma...@graphity.org>.
Is that an oversight in the GSP spec?

I had done something similar (which I use as a low-level API):
https://github.com/Graphity/graphity-core/blob/master/src/main/java/org/graphity/core/util/DataManager.java


On Mon, Aug 17, 2015 at 10:16 PM, Andy Seaborne <an...@apache.org> wrote:
> On 17/08/15 20:26, Martynas Jusevičius wrote:
>>
>> Andy,
>>
>> I have a related question. What if I have a Dataset at hand, not a
>> Model - how do I send it to a remote Graph Store?
>
>
> The SPARQL Graph Store Protocol does not mention this.  Fuseki supports
> REST-ish PUT/POST/GET on the dataset URL.
>
> Currently, you need to send it yourself -- HttpOp.execHttpPost has lots for
> support for that e.g. see DatasetGraphAccessorHTTP for sending a model -
> generalise to datasets.
>
> We have been talking about this on dev@
>
> http://mail-archives.apache.org/mod_mbox/jena-dev/201508.mbox/%3C55BE6A0B.5020404%40apache.org%3E
>
> where we're talking about bring the remote (and local) interaction together
> and whetre I'm suggesting adding the plain-old HTTP ops on teh dataset URL.
>
>         Andy
>
>
>>
>> Martynas
>>
>> On Mon, Aug 17, 2015 at 9:19 PM, Andy Seaborne <an...@apache.org> wrote:
>>>
>>> DatasetAccessor
>>>
>>> This is the API to the SPARQL Graph Store Protocol.
>>>
>>> Model model = ...
>>> DatasetAccessor acc = DatasetAccessorFactory.createHTTP
>>>          ("http://.../datasets/data") ;
>>> acc.add(model) ; // adds to existign data, if any.
>>>
>>> or
>>>
>>> acc.putModel(model) -- which overwrites existing data
>>>
>>>
>>> On 17/08/15 20:11, ajs6f@virginia.edu wrote:
>>>>
>>>>
>>>> There may be a better answer for this, but at the very least, you can
>>>> serialize your triples/quads and use SPARQL Update to send them to your
>>>> Fuseki instance.
>>>>
>>>>
>>>> ---
>>>> A. Soroka
>>>> The University of Virginia Library
>>>>
>>>> On Aug 17, 2015, at 3:08 PM, Andy Doddington <an...@gmail.com>
>>>> wrote:
>>>>
>>>>>
>>>>> On 17 Aug 2015, at 19:50, Andy Doddington
>>>>> <an...@googlemail.com> wrote:
>>>>>
>>>>> Hoping the subject makes my query clear - since I am a total newbie in
>>>>> this area.
>>>>>
>>>>> I have created a tiny model, using ModelFactory.createDefaultModel() to
>>>>> create my initially empty model,
>>>>> which I then populate manually.
>>>>>
>>>>> So, having done this, is there any way that I can persist this to a
>>>>> Fuseki database running on a remote server?
>>>>>
>>>>> Thanks for any help,
>>>>>
>>>>>          Andy D
>>>>>
>>>>
>>>
>

Re: Can I save an in-memory Jena Model to a remote Fuseki-managed database?

Posted by Andy Seaborne <an...@apache.org>.
On 17/08/15 20:26, Martynas Jusevičius wrote:
> Andy,
>
> I have a related question. What if I have a Dataset at hand, not a
> Model - how do I send it to a remote Graph Store?

The SPARQL Graph Store Protocol does not mention this.  Fuseki supports 
REST-ish PUT/POST/GET on the dataset URL.

Currently, you need to send it yourself -- HttpOp.execHttpPost has lots 
for support for that e.g. see DatasetGraphAccessorHTTP for sending a 
model - generalise to datasets.

We have been talking about this on dev@

http://mail-archives.apache.org/mod_mbox/jena-dev/201508.mbox/%3C55BE6A0B.5020404%40apache.org%3E

where we're talking about bring the remote (and local) interaction 
together and whetre I'm suggesting adding the plain-old HTTP ops on teh 
dataset URL.

	Andy

>
> Martynas
>
> On Mon, Aug 17, 2015 at 9:19 PM, Andy Seaborne <an...@apache.org> wrote:
>> DatasetAccessor
>>
>> This is the API to the SPARQL Graph Store Protocol.
>>
>> Model model = ...
>> DatasetAccessor acc = DatasetAccessorFactory.createHTTP
>>          ("http://.../datasets/data") ;
>> acc.add(model) ; // adds to existign data, if any.
>>
>> or
>>
>> acc.putModel(model) -- which overwrites existing data
>>
>>
>> On 17/08/15 20:11, ajs6f@virginia.edu wrote:
>>>
>>> There may be a better answer for this, but at the very least, you can
>>> serialize your triples/quads and use SPARQL Update to send them to your
>>> Fuseki instance.
>>>
>>>
>>> ---
>>> A. Soroka
>>> The University of Virginia Library
>>>
>>> On Aug 17, 2015, at 3:08 PM, Andy Doddington <an...@gmail.com>
>>> wrote:
>>>
>>>>
>>>> On 17 Aug 2015, at 19:50, Andy Doddington
>>>> <an...@googlemail.com> wrote:
>>>>
>>>> Hoping the subject makes my query clear - since I am a total newbie in
>>>> this area.
>>>>
>>>> I have created a tiny model, using ModelFactory.createDefaultModel() to
>>>> create my initially empty model,
>>>> which I then populate manually.
>>>>
>>>> So, having done this, is there any way that I can persist this to a
>>>> Fuseki database running on a remote server?
>>>>
>>>> Thanks for any help,
>>>>
>>>>          Andy D
>>>>
>>>
>>


Re: Can I save an in-memory Jena Model to a remote Fuseki-managed database?

Posted by Martynas Jusevičius <ma...@graphity.org>.
Andy,

I have a related question. What if I have a Dataset at hand, not a
Model - how do I send it to a remote Graph Store?

Martynas

On Mon, Aug 17, 2015 at 9:19 PM, Andy Seaborne <an...@apache.org> wrote:
> DatasetAccessor
>
> This is the API to the SPARQL Graph Store Protocol.
>
> Model model = ...
> DatasetAccessor acc = DatasetAccessorFactory.createHTTP
>         ("http://.../datasets/data") ;
> acc.add(model) ; // adds to existign data, if any.
>
> or
>
> acc.putModel(model) -- which overwrites existing data
>
>
> On 17/08/15 20:11, ajs6f@virginia.edu wrote:
>>
>> There may be a better answer for this, but at the very least, you can
>> serialize your triples/quads and use SPARQL Update to send them to your
>> Fuseki instance.
>>
>>
>> ---
>> A. Soroka
>> The University of Virginia Library
>>
>> On Aug 17, 2015, at 3:08 PM, Andy Doddington <an...@gmail.com>
>> wrote:
>>
>>>
>>> On 17 Aug 2015, at 19:50, Andy Doddington
>>> <an...@googlemail.com> wrote:
>>>
>>> Hoping the subject makes my query clear - since I am a total newbie in
>>> this area.
>>>
>>> I have created a tiny model, using ModelFactory.createDefaultModel() to
>>> create my initially empty model,
>>> which I then populate manually.
>>>
>>> So, having done this, is there any way that I can persist this to a
>>> Fuseki database running on a remote server?
>>>
>>> Thanks for any help,
>>>
>>>         Andy D
>>>
>>
>

Re: Can I save an in-memory Jena Model to a remote Fuseki-managed database?

Posted by Andy Doddington <an...@gmail.com>.
That’s great - in the end I solved the problem by adding the line:

/$/** = anon

to the shiva.ini file.

Many thanks for all your help (and patience).

	Andy D
————————————————

On 18 Aug 2015, at 22:45, Andy Seaborne <an...@apache.org> wrote:

Out of the box, the UI only responds to the localhost. If you access it
from a different machine, or (unfortunately) the same machine but its
external IP address, the Fuseki refuses access to the JSON calls driving
the interface. You can change the default to a user/password.

https://jena.apache.org/documentation/fuseki2/fuseki-security.html

   Andy

On Tue, 18 Aug 2015 17:48 Andy Doddington <an...@gmail.com> wrote:

> Hah! I hadn’t configured a dataset. Now rectified by setting the
> config.ttl to be one of the templates provided
> as part of the build.
> 
> Curiously though, although I can see this when I run a browser locally on
> the server, and set the url to "localhost:3030",
> I don't see any datasets listed when I explicitly specify the ip address,
> nor when I try to access it from any other box.
> 
> I realise that I’ve gone *waaaay* off topic now, so unless the answer is
> obvious, don't feel the need to address this new
> issue. I’ll try searching in the fuseki knowledge base. Oh and btw: I
> don’t have any firewall set up, afaik (although
> if I did, I’d expect this to block the entire fuseki site, rather than
> just the dataset listings.
> 
> Sheeesh, this is tiring :-/
> 
> Andy D
> 
> —————————————
> 
> On 18 Aug 2015, at 12:11, Andy Seaborne <an...@apache.org> wrote:
> 
> The dataset (not the graph)  needs to exist before the operation is
> attempted.  e.g. via the UI, or via startup with "--update /ds" for a name
> of "ds".
> 
> http://foobar:3030/myDatasetName/data
> 
> /myDatasetName --  dataset name - must exist
> /myDatasetName/data -- service endpoint for GSP on that dataset (thats'
> the default name
> 
> and update must enabled.  How are you running the server?
> 
> 
> 
>        Andy
> 
> On 18/08/15 11:49, Andy Doddington wrote:
>> You’ll think me very dense, but how do I specify the dataset name? When
> I specify the dummy URL that
>> you suggest (I don’t care what the dataset is called at the moment) I
> get:
>> 
>>      Exception in thread "main"
> org.apache.jena.atlas.web.HttpException: 404 - Not Found
>> 
>> I feel I’m missing some trivial step here, but don’t know what it is :-(
>> 
>> Andy D
>> ——————————————
>> 
>> On 18 Aug 2015, at 09:36, Andy Seaborne <an...@apache.org> wrote:
>> 
>> Wrong URL: It will be something like
>> 
>>  http://foobar:3030/myDatasetName/data
>> 
>> which is the service endpoint for the Graph Store protocol by default.
> (It needs a config file to change it - the UI puts it there automatically)
> where the query one is http://foobar:3030/myDatasetName/query and the
> SPARQL Update one is http://foobar:3030/myDatasetName/update.
>> 
>> "myDatasetName" is whatever you you decided to call it.
>> 
>> ((
>> What you have actually done is POSTed to the web pages serving part of
> the UI at index.html.  It just returns the web page.  if anything POSTs to
> an HTML page, the content is thrown away (AFAIK true for all webservers).
>> ))
>> 
>>      Andy
>> 
>> 
>> On 18/08/15 09:17, Andy Doddington wrote:
>>> OK, I’ve created the model, which I can successfully print out using
> 'model.write(System.out, "RDF/XML-ABBREV”);'
>>> 
>>> However, when I use your code below, and do an acc.put(model) I find
> that there is nothing on the server, even though
>>> no errors are indicated.
>>> 
>>> The URL that I am using for the createHTTP request is the URL of my
> Fuseki server: "http://foobar:3030”, which I
>>> am inspecting using the built in web-based browser.
>>> 
>>> At the risk of stretching your patience, can you explain what I’m doing
> wrong? Given that there are no errors, I would
>>> have expected the model to appear somewhere or other :-/ If I specify
> an invalid URL (e.g. incorrect port) then
>>> I get an error, which seems to indicate that the code is actually
> talking to the server.
>>> 
>>> Thanks,
>>> 
>>>     Andy D.
>>> ————————————————
>>> 
>>> On 17 Aug 2015, at 20:19, Andy Seaborne <an...@apache.org> wrote:
>>> 
>>> DatasetAccessor
>>> 
>>> This is the API to the SPARQL Graph Store Protocol.
>>> 
>>> Model model = ...
>>> DatasetAccessor acc = DatasetAccessorFactory.createHTTP
>>>     ("http://.../datasets/data") ;
>>> acc.add(model) ; // adds to existign data, if any.
>>> 
>>> or
>>> 
>>> acc.putModel(model) -- which overwrites existing data
>>> 
>>> On 17/08/15 20:11, ajs6f@virginia.edu wrote:
>>>> There may be a better answer for this, but at the very least, you can
> serialize your triples/quads and use SPARQL Update to send them to your
> Fuseki instance.
>>>> 
>>>> 
>>>> ---
>>>> A. Soroka
>>>> The University of Virginia Library
>>>> 
>>>> On Aug 17, 2015, at 3:08 PM, Andy Doddington <
> andy.doddington@gmail.com> wrote:
>>>> 
>>>>> 
>>>>> On 17 Aug 2015, at 19:50, Andy Doddington <
> andy.doddington@googlemail.com> wrote:
>>>>> 
>>>>> Hoping the subject makes my query clear - since I am a total newbie
> in this area.
>>>>> 
>>>>> I have created a tiny model, using ModelFactory.createDefaultModel()
> to  create my initially empty model,
>>>>> which I then populate manually.
>>>>> 
>>>>> So, having done this, is there any way that I can persist this to a
> Fuseki database running on a remote server?
>>>>> 
>>>>> Thanks for any help,
>>>>> 
>>>>>   Andy D
>>>>> 
>>>> 
>>> 
>>> 
>>> 
>> 
>> 
> 
> 
> 


Re: Can I save an in-memory Jena Model to a remote Fuseki-managed database?

Posted by Andy Seaborne <an...@apache.org>.
Out of the box, the UI only responds to the localhost. If you access it
from a different machine, or (unfortunately) the same machine but its
external IP address, the Fuseki refuses access to the JSON calls driving
the interface. You can change the default to a user/password.

https://jena.apache.org/documentation/fuseki2/fuseki-security.html

    Andy

On Tue, 18 Aug 2015 17:48 Andy Doddington <an...@gmail.com> wrote:

> Hah! I hadn’t configured a dataset. Now rectified by setting the
> config.ttl to be one of the templates provided
> as part of the build.
>
> Curiously though, although I can see this when I run a browser locally on
> the server, and set the url to "localhost:3030",
> I don't see any datasets listed when I explicitly specify the ip address,
> nor when I try to access it from any other box.
>
> I realise that I’ve gone *waaaay* off topic now, so unless the answer is
> obvious, don't feel the need to address this new
> issue. I’ll try searching in the fuseki knowledge base. Oh and btw: I
> don’t have any firewall set up, afaik (although
> if I did, I’d expect this to block the entire fuseki site, rather than
> just the dataset listings.
>
> Sheeesh, this is tiring :-/
>
> Andy D
>
> —————————————
>
> On 18 Aug 2015, at 12:11, Andy Seaborne <an...@apache.org> wrote:
>
> The dataset (not the graph)  needs to exist before the operation is
> attempted.  e.g. via the UI, or via startup with "--update /ds" for a name
> of "ds".
>
> http://foobar:3030/myDatasetName/data
>
> /myDatasetName --  dataset name - must exist
> /myDatasetName/data -- service endpoint for GSP on that dataset (thats'
> the default name
>
> and update must enabled.  How are you running the server?
>
>
>
>         Andy
>
> On 18/08/15 11:49, Andy Doddington wrote:
> > You’ll think me very dense, but how do I specify the dataset name? When
> I specify the dummy URL that
> > you suggest (I don’t care what the dataset is called at the moment) I
> get:
> >
> >       Exception in thread "main"
> org.apache.jena.atlas.web.HttpException: 404 - Not Found
> >
> > I feel I’m missing some trivial step here, but don’t know what it is :-(
> >
> > Andy D
> > ——————————————
> >
> > On 18 Aug 2015, at 09:36, Andy Seaborne <an...@apache.org> wrote:
> >
> > Wrong URL: It will be something like
> >
> >   http://foobar:3030/myDatasetName/data
> >
> > which is the service endpoint for the Graph Store protocol by default.
> (It needs a config file to change it - the UI puts it there automatically)
> where the query one is http://foobar:3030/myDatasetName/query and the
> SPARQL Update one is http://foobar:3030/myDatasetName/update.
> >
> > "myDatasetName" is whatever you you decided to call it.
> >
> > ((
> > What you have actually done is POSTed to the web pages serving part of
> the UI at index.html.  It just returns the web page.  if anything POSTs to
> an HTML page, the content is thrown away (AFAIK true for all webservers).
> > ))
> >
> >       Andy
> >
> >
> > On 18/08/15 09:17, Andy Doddington wrote:
> >> OK, I’ve created the model, which I can successfully print out using
> 'model.write(System.out, "RDF/XML-ABBREV”);'
> >>
> >> However, when I use your code below, and do an acc.put(model) I find
> that there is nothing on the server, even though
> >> no errors are indicated.
> >>
> >> The URL that I am using for the createHTTP request is the URL of my
> Fuseki server: "http://foobar:3030”, which I
> >> am inspecting using the built in web-based browser.
> >>
> >> At the risk of stretching your patience, can you explain what I’m doing
> wrong? Given that there are no errors, I would
> >> have expected the model to appear somewhere or other :-/ If I specify
> an invalid URL (e.g. incorrect port) then
> >> I get an error, which seems to indicate that the code is actually
> talking to the server.
> >>
> >> Thanks,
> >>
> >>      Andy D.
> >> ————————————————
> >>
> >> On 17 Aug 2015, at 20:19, Andy Seaborne <an...@apache.org> wrote:
> >>
> >> DatasetAccessor
> >>
> >> This is the API to the SPARQL Graph Store Protocol.
> >>
> >> Model model = ...
> >> DatasetAccessor acc = DatasetAccessorFactory.createHTTP
> >>      ("http://.../datasets/data") ;
> >> acc.add(model) ; // adds to existign data, if any.
> >>
> >> or
> >>
> >> acc.putModel(model) -- which overwrites existing data
> >>
> >> On 17/08/15 20:11, ajs6f@virginia.edu wrote:
> >>> There may be a better answer for this, but at the very least, you can
> serialize your triples/quads and use SPARQL Update to send them to your
> Fuseki instance.
> >>>
> >>>
> >>> ---
> >>> A. Soroka
> >>> The University of Virginia Library
> >>>
> >>> On Aug 17, 2015, at 3:08 PM, Andy Doddington <
> andy.doddington@gmail.com> wrote:
> >>>
> >>>>
> >>>> On 17 Aug 2015, at 19:50, Andy Doddington <
> andy.doddington@googlemail.com> wrote:
> >>>>
> >>>> Hoping the subject makes my query clear - since I am a total newbie
> in this area.
> >>>>
> >>>> I have created a tiny model, using ModelFactory.createDefaultModel()
> to  create my initially empty model,
> >>>> which I then populate manually.
> >>>>
> >>>> So, having done this, is there any way that I can persist this to a
> Fuseki database running on a remote server?
> >>>>
> >>>> Thanks for any help,
> >>>>
> >>>>    Andy D
> >>>>
> >>>
> >>
> >>
> >>
> >
> >
>
>
>

Re: Can I save an in-memory Jena Model to a remote Fuseki-managed database?

Posted by Andy Doddington <an...@gmail.com>.
Hah! I hadn’t configured a dataset. Now rectified by setting the config.ttl to be one of the templates provided
as part of the build.

Curiously though, although I can see this when I run a browser locally on the server, and set the url to "localhost:3030",
I don't see any datasets listed when I explicitly specify the ip address, nor when I try to access it from any other box.

I realise that I’ve gone *waaaay* off topic now, so unless the answer is obvious, don't feel the need to address this new
issue. I’ll try searching in the fuseki knowledge base. Oh and btw: I don’t have any firewall set up, afaik (although
if I did, I’d expect this to block the entire fuseki site, rather than just the dataset listings.

Sheeesh, this is tiring :-/

Andy D

—————————————

On 18 Aug 2015, at 12:11, Andy Seaborne <an...@apache.org> wrote:

The dataset (not the graph)  needs to exist before the operation is attempted.  e.g. via the UI, or via startup with "--update /ds" for a name of "ds".

http://foobar:3030/myDatasetName/data

/myDatasetName --  dataset name - must exist
/myDatasetName/data -- service endpoint for GSP on that dataset (thats' the default name

and update must enabled.  How are you running the server?



	Andy

On 18/08/15 11:49, Andy Doddington wrote:
> You’ll think me very dense, but how do I specify the dataset name? When I specify the dummy URL that
> you suggest (I don’t care what the dataset is called at the moment) I get:
> 
> 	Exception in thread "main" org.apache.jena.atlas.web.HttpException: 404 - Not Found
> 
> I feel I’m missing some trivial step here, but don’t know what it is :-(
> 
> Andy D
> ——————————————
> 
> On 18 Aug 2015, at 09:36, Andy Seaborne <an...@apache.org> wrote:
> 
> Wrong URL: It will be something like
> 
>   http://foobar:3030/myDatasetName/data
> 
> which is the service endpoint for the Graph Store protocol by default. (It needs a config file to change it - the UI puts it there automatically) where the query one is http://foobar:3030/myDatasetName/query and the SPARQL Update one is http://foobar:3030/myDatasetName/update.
> 
> "myDatasetName" is whatever you you decided to call it.
> 
> ((
> What you have actually done is POSTed to the web pages serving part of the UI at index.html.  It just returns the web page.  if anything POSTs to an HTML page, the content is thrown away (AFAIK true for all webservers).
> ))
> 
> 	Andy
> 
> 
> On 18/08/15 09:17, Andy Doddington wrote:
>> OK, I’ve created the model, which I can successfully print out using 'model.write(System.out, "RDF/XML-ABBREV”);'
>> 
>> However, when I use your code below, and do an acc.put(model) I find that there is nothing on the server, even though
>> no errors are indicated.
>> 
>> The URL that I am using for the createHTTP request is the URL of my Fuseki server: "http://foobar:3030”, which I
>> am inspecting using the built in web-based browser.
>> 
>> At the risk of stretching your patience, can you explain what I’m doing wrong? Given that there are no errors, I would
>> have expected the model to appear somewhere or other :-/ If I specify an invalid URL (e.g. incorrect port) then
>> I get an error, which seems to indicate that the code is actually talking to the server.
>> 
>> Thanks,
>> 
>> 	Andy D.
>> ————————————————
>> 
>> On 17 Aug 2015, at 20:19, Andy Seaborne <an...@apache.org> wrote:
>> 
>> DatasetAccessor
>> 
>> This is the API to the SPARQL Graph Store Protocol.
>> 
>> Model model = ...
>> DatasetAccessor acc = DatasetAccessorFactory.createHTTP
>> 	("http://.../datasets/data") ;
>> acc.add(model) ; // adds to existign data, if any.
>> 
>> or
>> 
>> acc.putModel(model) -- which overwrites existing data
>> 
>> On 17/08/15 20:11, ajs6f@virginia.edu wrote:
>>> There may be a better answer for this, but at the very least, you can serialize your triples/quads and use SPARQL Update to send them to your Fuseki instance.
>>> 
>>> 
>>> ---
>>> A. Soroka
>>> The University of Virginia Library
>>> 
>>> On Aug 17, 2015, at 3:08 PM, Andy Doddington <an...@gmail.com> wrote:
>>> 
>>>> 
>>>> On 17 Aug 2015, at 19:50, Andy Doddington <an...@googlemail.com> wrote:
>>>> 
>>>> Hoping the subject makes my query clear - since I am a total newbie in this area.
>>>> 
>>>> I have created a tiny model, using ModelFactory.createDefaultModel() to  create my initially empty model,
>>>> which I then populate manually.
>>>> 
>>>> So, having done this, is there any way that I can persist this to a Fuseki database running on a remote server?
>>>> 
>>>> Thanks for any help,
>>>> 
>>>> 	Andy D
>>>> 
>>> 
>> 
>> 
>> 
> 
> 



Re: Can I save an in-memory Jena Model to a remote Fuseki-managed database?

Posted by Andy Seaborne <an...@apache.org>.
The dataset (not the graph)  needs to exist before the operation is 
attempted.  e.g. via the UI, or via startup with "--update /ds" for a 
name of "ds".

http://foobar:3030/myDatasetName/data

/myDatasetName --  dataset name - must exist
/myDatasetName/data -- service endpoint for GSP on that dataset (thats' 
the default name

and update must enabled.  How are you running the server?



	Andy

On 18/08/15 11:49, Andy Doddington wrote:
> You’ll think me very dense, but how do I specify the dataset name? When I specify the dummy URL that
> you suggest (I don’t care what the dataset is called at the moment) I get:
>
> 	Exception in thread "main" org.apache.jena.atlas.web.HttpException: 404 - Not Found
>
> I feel I’m missing some trivial step here, but don’t know what it is :-(
>
> Andy D
> ——————————————
>
> On 18 Aug 2015, at 09:36, Andy Seaborne <an...@apache.org> wrote:
>
> Wrong URL: It will be something like
>
>    http://foobar:3030/myDatasetName/data
>
> which is the service endpoint for the Graph Store protocol by default. (It needs a config file to change it - the UI puts it there automatically) where the query one is http://foobar:3030/myDatasetName/query and the SPARQL Update one is http://foobar:3030/myDatasetName/update.
>
> "myDatasetName" is whatever you you decided to call it.
>
> ((
> What you have actually done is POSTed to the web pages serving part of the UI at index.html.  It just returns the web page.  if anything POSTs to an HTML page, the content is thrown away (AFAIK true for all webservers).
> ))
>
> 	Andy
>
>
> On 18/08/15 09:17, Andy Doddington wrote:
>> OK, I’ve created the model, which I can successfully print out using 'model.write(System.out, "RDF/XML-ABBREV”);'
>>
>> However, when I use your code below, and do an acc.put(model) I find that there is nothing on the server, even though
>> no errors are indicated.
>>
>> The URL that I am using for the createHTTP request is the URL of my Fuseki server: "http://foobar:3030”, which I
>> am inspecting using the built in web-based browser.
>>
>> At the risk of stretching your patience, can you explain what I’m doing wrong? Given that there are no errors, I would
>> have expected the model to appear somewhere or other :-/ If I specify an invalid URL (e.g. incorrect port) then
>> I get an error, which seems to indicate that the code is actually talking to the server.
>>
>> Thanks,
>>
>> 	Andy D.
>> ————————————————
>>
>> On 17 Aug 2015, at 20:19, Andy Seaborne <an...@apache.org> wrote:
>>
>> DatasetAccessor
>>
>> This is the API to the SPARQL Graph Store Protocol.
>>
>> Model model = ...
>> DatasetAccessor acc = DatasetAccessorFactory.createHTTP
>> 	("http://.../datasets/data") ;
>> acc.add(model) ; // adds to existign data, if any.
>>
>> or
>>
>> acc.putModel(model) -- which overwrites existing data
>>
>> On 17/08/15 20:11, ajs6f@virginia.edu wrote:
>>> There may be a better answer for this, but at the very least, you can serialize your triples/quads and use SPARQL Update to send them to your Fuseki instance.
>>>
>>>
>>> ---
>>> A. Soroka
>>> The University of Virginia Library
>>>
>>> On Aug 17, 2015, at 3:08 PM, Andy Doddington <an...@gmail.com> wrote:
>>>
>>>>
>>>> On 17 Aug 2015, at 19:50, Andy Doddington <an...@googlemail.com> wrote:
>>>>
>>>> Hoping the subject makes my query clear - since I am a total newbie in this area.
>>>>
>>>> I have created a tiny model, using ModelFactory.createDefaultModel() to  create my initially empty model,
>>>> which I then populate manually.
>>>>
>>>> So, having done this, is there any way that I can persist this to a Fuseki database running on a remote server?
>>>>
>>>> Thanks for any help,
>>>>
>>>> 	Andy D
>>>>
>>>
>>
>>
>>
>
>


Re: Can I save an in-memory Jena Model to a remote Fuseki-managed database?

Posted by Andy Doddington <an...@gmail.com>.
You’ll think me very dense, but how do I specify the dataset name? When I specify the dummy URL that
you suggest (I don’t care what the dataset is called at the moment) I get:

	Exception in thread "main" org.apache.jena.atlas.web.HttpException: 404 - Not Found

I feel I’m missing some trivial step here, but don’t know what it is :-(

Andy D
——————————————

On 18 Aug 2015, at 09:36, Andy Seaborne <an...@apache.org> wrote:

Wrong URL: It will be something like

  http://foobar:3030/myDatasetName/data

which is the service endpoint for the Graph Store protocol by default. (It needs a config file to change it - the UI puts it there automatically) where the query one is http://foobar:3030/myDatasetName/query and the SPARQL Update one is http://foobar:3030/myDatasetName/update.

"myDatasetName" is whatever you you decided to call it.

((
What you have actually done is POSTed to the web pages serving part of the UI at index.html.  It just returns the web page.  if anything POSTs to an HTML page, the content is thrown away (AFAIK true for all webservers).
))

	Andy


On 18/08/15 09:17, Andy Doddington wrote:
> OK, I’ve created the model, which I can successfully print out using 'model.write(System.out, "RDF/XML-ABBREV”);'
> 
> However, when I use your code below, and do an acc.put(model) I find that there is nothing on the server, even though
> no errors are indicated.
> 
> The URL that I am using for the createHTTP request is the URL of my Fuseki server: "http://foobar:3030”, which I
> am inspecting using the built in web-based browser.
> 
> At the risk of stretching your patience, can you explain what I’m doing wrong? Given that there are no errors, I would
> have expected the model to appear somewhere or other :-/ If I specify an invalid URL (e.g. incorrect port) then
> I get an error, which seems to indicate that the code is actually talking to the server.
> 
> Thanks,
> 
> 	Andy D.
> ————————————————
> 
> On 17 Aug 2015, at 20:19, Andy Seaborne <an...@apache.org> wrote:
> 
> DatasetAccessor
> 
> This is the API to the SPARQL Graph Store Protocol.
> 
> Model model = ...
> DatasetAccessor acc = DatasetAccessorFactory.createHTTP
> 	("http://.../datasets/data") ;
> acc.add(model) ; // adds to existign data, if any.
> 
> or
> 
> acc.putModel(model) -- which overwrites existing data
> 
> On 17/08/15 20:11, ajs6f@virginia.edu wrote:
>> There may be a better answer for this, but at the very least, you can serialize your triples/quads and use SPARQL Update to send them to your Fuseki instance.
>> 
>> 
>> ---
>> A. Soroka
>> The University of Virginia Library
>> 
>> On Aug 17, 2015, at 3:08 PM, Andy Doddington <an...@gmail.com> wrote:
>> 
>>> 
>>> On 17 Aug 2015, at 19:50, Andy Doddington <an...@googlemail.com> wrote:
>>> 
>>> Hoping the subject makes my query clear - since I am a total newbie in this area.
>>> 
>>> I have created a tiny model, using ModelFactory.createDefaultModel() to  create my initially empty model,
>>> which I then populate manually.
>>> 
>>> So, having done this, is there any way that I can persist this to a Fuseki database running on a remote server?
>>> 
>>> Thanks for any help,
>>> 
>>> 	Andy D
>>> 
>> 
> 
> 
> 



Re: Can I save an in-memory Jena Model to a remote Fuseki-managed database?

Posted by Andy Seaborne <an...@apache.org>.
Wrong URL: It will be something like

    http://foobar:3030/myDatasetName/data

which is the service endpoint for the Graph Store protocol by default. 
(It needs a config file to change it - the UI puts it there 
automatically) where the query one is 
http://foobar:3030/myDatasetName/query and the SPARQL Update one is 
http://foobar:3030/myDatasetName/update.

"myDatasetName" is whatever you you decided to call it.

((
What you have actually done is POSTed to the web pages serving part of 
the UI at index.html.  It just returns the web page.  if anything POSTs 
to an HTML page, the content is thrown away (AFAIK true for all webservers).
))

	Andy


On 18/08/15 09:17, Andy Doddington wrote:
> OK, I’ve created the model, which I can successfully print out using 'model.write(System.out, "RDF/XML-ABBREV”);'
>
> However, when I use your code below, and do an acc.put(model) I find that there is nothing on the server, even though
> no errors are indicated.
>
> The URL that I am using for the createHTTP request is the URL of my Fuseki server: "http://foobar:3030”, which I
> am inspecting using the built in web-based browser.
>
> At the risk of stretching your patience, can you explain what I’m doing wrong? Given that there are no errors, I would
> have expected the model to appear somewhere or other :-/ If I specify an invalid URL (e.g. incorrect port) then
> I get an error, which seems to indicate that the code is actually talking to the server.
>
> Thanks,
>
> 	Andy D.
> ————————————————
>
> On 17 Aug 2015, at 20:19, Andy Seaborne <an...@apache.org> wrote:
>
> DatasetAccessor
>
> This is the API to the SPARQL Graph Store Protocol.
>
> Model model = ...
> DatasetAccessor acc = DatasetAccessorFactory.createHTTP
> 	("http://.../datasets/data") ;
> acc.add(model) ; // adds to existign data, if any.
>
> or
>
> acc.putModel(model) -- which overwrites existing data
>
> On 17/08/15 20:11, ajs6f@virginia.edu wrote:
>> There may be a better answer for this, but at the very least, you can serialize your triples/quads and use SPARQL Update to send them to your Fuseki instance.
>>
>>
>> ---
>> A. Soroka
>> The University of Virginia Library
>>
>> On Aug 17, 2015, at 3:08 PM, Andy Doddington <an...@gmail.com> wrote:
>>
>>>
>>> On 17 Aug 2015, at 19:50, Andy Doddington <an...@googlemail.com> wrote:
>>>
>>> Hoping the subject makes my query clear - since I am a total newbie in this area.
>>>
>>> I have created a tiny model, using ModelFactory.createDefaultModel() to  create my initially empty model,
>>> which I then populate manually.
>>>
>>> So, having done this, is there any way that I can persist this to a Fuseki database running on a remote server?
>>>
>>> Thanks for any help,
>>>
>>> 	Andy D
>>>
>>
>
>
>


Re: Can I save an in-memory Jena Model to a remote Fuseki-managed database?

Posted by Andy Doddington <an...@gmail.com>.
OK, I’ve created the model, which I can successfully print out using 'model.write(System.out, "RDF/XML-ABBREV”);'

However, when I use your code below, and do an acc.put(model) I find that there is nothing on the server, even though
no errors are indicated.

The URL that I am using for the createHTTP request is the URL of my Fuseki server: "http://foobar:3030”, which I
am inspecting using the built in web-based browser.

At the risk of stretching your patience, can you explain what I’m doing wrong? Given that there are no errors, I would
have expected the model to appear somewhere or other :-/ If I specify an invalid URL (e.g. incorrect port) then
I get an error, which seems to indicate that the code is actually talking to the server.

Thanks,

	Andy D.
————————————————

On 17 Aug 2015, at 20:19, Andy Seaborne <an...@apache.org> wrote:

DatasetAccessor

This is the API to the SPARQL Graph Store Protocol.

Model model = ...
DatasetAccessor acc = DatasetAccessorFactory.createHTTP
	("http://.../datasets/data") ;
acc.add(model) ; // adds to existign data, if any.

or

acc.putModel(model) -- which overwrites existing data

On 17/08/15 20:11, ajs6f@virginia.edu wrote:
> There may be a better answer for this, but at the very least, you can serialize your triples/quads and use SPARQL Update to send them to your Fuseki instance.
> 
> 
> ---
> A. Soroka
> The University of Virginia Library
> 
> On Aug 17, 2015, at 3:08 PM, Andy Doddington <an...@gmail.com> wrote:
> 
>> 
>> On 17 Aug 2015, at 19:50, Andy Doddington <an...@googlemail.com> wrote:
>> 
>> Hoping the subject makes my query clear - since I am a total newbie in this area.
>> 
>> I have created a tiny model, using ModelFactory.createDefaultModel() to  create my initially empty model,
>> which I then populate manually.
>> 
>> So, having done this, is there any way that I can persist this to a Fuseki database running on a remote server?
>> 
>> Thanks for any help,
>> 
>> 	Andy D
>> 
> 




Re: Can I save an in-memory Jena Model to a remote Fuseki-managed database?

Posted by Andy Seaborne <an...@apache.org>.
DatasetAccessor

This is the API to the SPARQL Graph Store Protocol.

Model model = ...
DatasetAccessor acc = DatasetAccessorFactory.createHTTP
	("http://.../datasets/data") ;
acc.add(model) ; // adds to existign data, if any.

or

acc.putModel(model) -- which overwrites existing data

On 17/08/15 20:11, ajs6f@virginia.edu wrote:
> There may be a better answer for this, but at the very least, you can serialize your triples/quads and use SPARQL Update to send them to your Fuseki instance.
>
>
> ---
> A. Soroka
> The University of Virginia Library
>
> On Aug 17, 2015, at 3:08 PM, Andy Doddington <an...@gmail.com> wrote:
>
>>
>> On 17 Aug 2015, at 19:50, Andy Doddington <an...@googlemail.com> wrote:
>>
>> Hoping the subject makes my query clear - since I am a total newbie in this area.
>>
>> I have created a tiny model, using ModelFactory.createDefaultModel() to  create my initially empty model,
>> which I then populate manually.
>>
>> So, having done this, is there any way that I can persist this to a Fuseki database running on a remote server?
>>
>> Thanks for any help,
>>
>> 	Andy D
>>
>


Re: Can I save an in-memory Jena Model to a remote Fuseki-managed database?

Posted by "ajs6f@virginia.edu" <aj...@virginia.edu>.
There may be a better answer for this, but at the very least, you can serialize your triples/quads and use SPARQL Update to send them to your Fuseki instance.


---
A. Soroka
The University of Virginia Library

On Aug 17, 2015, at 3:08 PM, Andy Doddington <an...@gmail.com> wrote:

> 
> On 17 Aug 2015, at 19:50, Andy Doddington <an...@googlemail.com> wrote:
> 
> Hoping the subject makes my query clear - since I am a total newbie in this area.
> 
> I have created a tiny model, using ModelFactory.createDefaultModel() to  create my initially empty model,
> which I then populate manually.
> 
> So, having done this, is there any way that I can persist this to a Fuseki database running on a remote server?
> 
> Thanks for any help,
> 
> 	Andy D
>