You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@jena.apache.org by "Bell, Paul M." <pb...@syncsort.com> on 2012/11/22 20:18:40 UTC

Storage and Query Questions

Hi,

I have a few questions about Jena's storage and query capabilities.


 1.
Jena seems to support RDF stores of these types: in-memory, SQL, native tuple store (TDB), and "custom." How are these stores initially populated, i.e., does Jena offer some kind of "load facility" that reads from, say, SQL and writes RDF?
 2.
If there is such a load facility, can it read from a NoSQL DB, e.g., MongoDB, and write to the RDF store?
 3.
Suppose that a SPARQL query needed to reference non-triplestore data. Can Jena call into a custom "adapter" that reads these non-triplestore data, receive these data from the adapter, and incorporate them into its query resolution?

A more general question: what are some common practices concerning RDF store consistency? I suppose that most RDF stores are initially populated from SQL stores. Given the likely volatility of SQL stores, doesn't this mean that the RDF store can quickly grow stale, i.e., it might contain relationships among resources that no longer exist? How is this consistency issue handled in the real world?



Thanks for your help.



Cordially,



Paul







________________________________


ATTENTION: -----

The information contained in this message (including any files transmitted with this message) may contain proprietary, trade secret or other confidential and/or legally privileged information. Any pricing information contained in this message or in any files transmitted with this message is always confidential and cannot be shared with any third parties without prior written approval from Syncsort. This message is intended to be read only by the individual or entity to whom it is addressed or by their designee. If the reader of this message is not the intended recipient, you are on notice that any use, disclosure, copying or distribution of this message, in any form, is strictly prohibited. If you have received this message in error, please immediately notify the sender and/or Syncsort and destroy all copies of this message in your possession, custody or control.

Re: Storage and Query Questions

Posted by Claude Warren <cl...@xenei.com>.
Just my 2-cents here but I recall reading the the schema of the NoSQL
storage (e.g. key and lots of values per row) can significantly impact
the ability to support the graph search operations (e.g find all
triples that have a given predicate).

If you are creating a NoSQL database to underpin a graph then you
should probably spend some time looking at the search requirements on
the graph.

If you are mapping an existing NoSQL to a graph you may want to
consider how you will handle the cases that are not directly supported
by the database schema.

-- Claude


On Fri, Nov 23, 2012 at 6:08 PM, Andy Seaborne <an...@apache.org> wrote:
> On 23/11/12 16:05, Bell, Paul M. wrote:
>>
>> Hi Andy,
>>
>> Thanks for your helpful replies.
>>
>> Some brief follow-up:
>>
>> 1. I thought that D2RQ could present a virtual RDF graph based on SQL
>> DB only. Can it be customized (via some kind of adapter plug-in) to
>> handle NoSQL DB?
>
>
> I don't know - that's a question best answered by the D2QR project. They may
> have plans.
>
> It would at least be a good starting point (depending on the NoSQL) because
> one NoSQL database often looks like a single table, maybe a bit ragged
> (missing values in rows)
>
>         Andy
>
>
>>
>> Thanks again.
>>
>> -paul
>>
>> Technology Architect Syncsort Data Protection "Heideggerian Magneto
>> Reluctance Algorithms risk Sinusoidal Depleneration"
>
>



-- 
I like: Like Like - The likeliest place on the web
Identity: https://www.identify.nu/user.php?claude@xenei.com
LinkedIn: http://www.linkedin.com/in/claudewarren

Re: Storage and Query Questions

Posted by Andy Seaborne <an...@apache.org>.
On 23/11/12 16:05, Bell, Paul M. wrote:
> Hi Andy,
>
> Thanks for your helpful replies.
>
> Some brief follow-up:
>
> 1. I thought that D2RQ could present a virtual RDF graph based on SQL
> DB only. Can it be customized (via some kind of adapter plug-in) to
> handle NoSQL DB?

I don't know - that's a question best answered by the D2QR project. 
They may have plans.

It would at least be a good starting point (depending on the NoSQL) 
because one NoSQL database often looks like a single table, maybe a bit 
ragged (missing values in rows)

	Andy

>
> Thanks again.
>
> -paul
>
> Technology Architect Syncsort Data Protection "Heideggerian Magneto
> Reluctance Algorithms risk Sinusoidal Depleneration"


Re: Storage and Query Questions

Posted by "Bell, Paul M." <pb...@syncsort.com>.
Hi Andy,

Thanks for your helpful replies.

Some brief follow-up:

1. I thought that D2RQ could present a virtual RDF graph based on SQL DB only. Can it be customized (via some kind of adapter plug-in) to handle NoSQL DB?

Thanks again.

-paul

Technology Architect
Syncsort Data Protection
"Heideggerian Magneto Reluctance Algorithms risk Sinusoidal Depleneration"

On Nov 23, 2012, at 10:17 AM, "Andy Seaborne" <an...@apache.org> wrote:

> On 22/11/12 19:18, Bell, Paul M. wrote:
>> Hi,
>>
>> I have a few questions about Jena's storage and query capabilities.
>>
>>
>> 1. Jena seems to support RDF stores of these types: in-memory, SQL,
>> native tuple store (TDB), and "custom." How are these stores
>> initially populated, i.e., does Jena offer some kind of "load
>> facility" that reads from, say, SQL and writes RDF?
>
> The Jena APi can be used on any store so once code has got a hanle on
> the store (dataset, model) everythign is the same.
>
> Jena itself does not offer a legacy SQL to RDF path - theer are tools
> such as D2RQ that offer that as a dump or as a live connection back to
> the original (and live) data. Look for R2RML tools - R2RML is the W3C
> standard for this.
>
> D2RQ offers R2RML or soon will do (it's not from the Apache Jena
> project, it used Jena IIRC).
>
> There are commercial tools.
>
>> 2. If there is such a load facility, can it read from a NoSQL DB,
>> e.g., MongoDB, and write to the RDF store?
>
> Not in Jena per se.  A key stap is mapping the data to an RDF data
> model.  That can be simple (close to being a RDFization of the NoSQL
> store), or complex (presenting higher level modelling concepts).
>
>> 3. Suppose that a SPARQL query needed to reference non-triplestore
>> data. Can Jena call into a custom "adapter" that reads these
>> non-triplestore data, receive these data from the adapter, and
>> incorporate them into its query resolution?
>
> See R2RML - that would give a SPARQL interface to an existing SQL DB.
>
>> A more general question: what are some common practices concerning
>> RDF store consistency? I suppose that most RDF stores are initially
>> populated from SQL stores. Given the likely volatility of SQL stores,
>> doesn't this mean that the RDF store can quickly grow stale, i.e., it
>> might contain relationships among resources that no longer exist? How
>> is this consistency issue handled in the real world?
>
> Not sure that most stores are populated from SQL.
>
> If liveness matters, a dynamic connection such as D2RQ offers up-to-date
> access.
>
>    Andy
>
>>
>>
>>
>> Thanks for your help.
>>
>>
>>
>> Cordially,
>>
>>
>>
>> Paul



ATTENTION: -----

The information contained in this message (including any files transmitted with this message) may contain proprietary, trade secret or other  confidential and/or legally privileged information. Any pricing information contained in this message or in any files transmitted with this message is always confidential and cannot be shared with any third parties without prior written approval from Syncsort. This message is intended to be read only by the individual or entity to whom it is addressed or by their designee. If the reader of this message is not the intended recipient, you are on notice that any use, disclosure, copying or distribution of this message, in any form, is strictly prohibited. If you have received this message in error, please immediately notify the sender and/or Syncsort and destroy all copies of this message in your possession, custody or control.

Re: Storage and Query Questions

Posted by Andy Seaborne <an...@apache.org>.
On 22/11/12 19:18, Bell, Paul M. wrote:
> Hi,
>
> I have a few questions about Jena's storage and query capabilities.
>
>
> 1. Jena seems to support RDF stores of these types: in-memory, SQL,
> native tuple store (TDB), and "custom." How are these stores
> initially populated, i.e., does Jena offer some kind of "load
> facility" that reads from, say, SQL and writes RDF?

The Jena APi can be used on any store so once code has got a hanle on 
the store (dataset, model) everythign is the same.

Jena itself does not offer a legacy SQL to RDF path - theer are tools 
such as D2RQ that offer that as a dump or as a live connection back to 
the original (and live) data. Look for R2RML tools - R2RML is the W3C 
standard for this.

D2RQ offers R2RML or soon will do (it's not from the Apache Jena 
project, it used Jena IIRC).

There are commercial tools.

> 2. If there is such a load facility, can it read from a NoSQL DB,
> e.g., MongoDB, and write to the RDF store?

Not in Jena per se.  A key stap is mapping the data to an RDF data 
model.  That can be simple (close to being a RDFization of the NoSQL 
store), or complex (presenting higher level modelling concepts).

> 3. Suppose that a SPARQL query needed to reference non-triplestore
> data. Can Jena call into a custom "adapter" that reads these
> non-triplestore data, receive these data from the adapter, and
> incorporate them into its query resolution?

See R2RML - that would give a SPARQL interface to an existing SQL DB.

> A more general question: what are some common practices concerning
> RDF store consistency? I suppose that most RDF stores are initially
> populated from SQL stores. Given the likely volatility of SQL stores,
> doesn't this mean that the RDF store can quickly grow stale, i.e., it
> might contain relationships among resources that no longer exist? How
> is this consistency issue handled in the real world?

Not sure that most stores are populated from SQL.

If liveness matters, a dynamic connection such as D2RQ offers up-to-date 
access.

	Andy

>
>
>
> Thanks for your help.
>
>
>
> Cordially,
>
>
>
> Paul