You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@jena.apache.org by Patrick Logan <pa...@gmail.com> on 2012/06/06 19:20:41 UTC

Fuseki transactions from Java

A question about using Fuseki and TBD transactions from a Java application:

Are the transaction boundaries implicit per SPARQL operation?

If multiple operations are included in one request, by definition
either they all succeed or they all fail.

Is there some way through the Java TDB API to connect to Fuseki and
execute multiple sequential requests to query and update the
underlying Fuseki TDB model as part of one ACID transaction. i.e. the
reads before and between the updates are all consistent?

I thought I read something to that effect, but cannot find it, and am
questioning my recollection.

Thanks
-Patrick

Re: Fuseki transactions from Java

Posted by Patrick Logan <pa...@gmail.com>.
Thanks Andy. I joined the dev list to follow the discussion there.
We'll proceed with Fuseki as-is and determine whether that presents
any challenges.

-Patrick



On Wed, Jun 6, 2012 at 2:31 PM, Andy Seaborne <an...@apache.org> wrote:
> On 06/06/12 18:20, Patrick Logan wrote:
>>
>> A question about using Fuseki and TBD transactions from a Java
>> application:
>>
>> Are the transaction boundaries implicit per SPARQL operation?
>>
>> If multiple operations are included in one request, by definition
>> either they all succeed or they all fail.
>
>
> Yes.
>
>
>> Is there some way through the Java TDB API to connect to Fuseki and
>> execute multiple sequential requests to query and update the
>> underlying Fuseki TDB model as part of one ACID transaction. i.e. the
>> reads before and between the updates are all consistent?
>
>
> No - operations to Fuseki over the wire are HTTP operations and each is done
> as a transaction.  There are no controllable transaction boundaries nor any
> server state across HTTP operations (well, except for the database itself!).
>
> The interaction model is (currently) more focused on webstyle clients and
> publishing data, not written as a client-server pair.
>
> There is nothing fundamental in the design - your question has triggered a
> discussion on the dev@ list.
>
> It would be great to support the client-server style - but it's not there.
>  Contributions (to discussions, or to code, welcome).
>
>
>> I thought I read something to that effect, but cannot find it, and am
>> questioning my recollection.
>>
>> Thanks
>> -Patrick
>
>
>        Andy
>

Re: Fuseki transactions from Java

Posted by Andy Seaborne <an...@apache.org>.
On 06/06/12 18:20, Patrick Logan wrote:
> A question about using Fuseki and TBD transactions from a Java application:
>
> Are the transaction boundaries implicit per SPARQL operation?
>
> If multiple operations are included in one request, by definition
> either they all succeed or they all fail.

Yes.

> Is there some way through the Java TDB API to connect to Fuseki and
> execute multiple sequential requests to query and update the
> underlying Fuseki TDB model as part of one ACID transaction. i.e. the
> reads before and between the updates are all consistent?

No - operations to Fuseki over the wire are HTTP operations and each is 
done as a transaction.  There are no controllable transaction boundaries 
nor any server state across HTTP operations (well, except for the 
database itself!).

The interaction model is (currently) more focused on webstyle clients 
and publishing data, not written as a client-server pair.

There is nothing fundamental in the design - your question has triggered 
a discussion on the dev@ list.

It would be great to support the client-server style - but it's not 
there.  Contributions (to discussions, or to code, welcome).

> I thought I read something to that effect, but cannot find it, and am
> questioning my recollection.
>
> Thanks
> -Patrick

	Andy