Note that there are some explanatory texts on larger screens.

plurals
  1. POJena SDB support thread-safe transaction? Jena SDB error under multiple-thread execution enviroment
    primarykey
    data
    text
    <p>My code of jena is broken under the multiple-thread execution environment. I use the jena sdb to save the rdf triples. However, when i start the six threads to complete the saving data action, the exception be threw out. (every thread save a graph rdf into db,every graph is different)</p> <p>I need the helps are:</p> <p><strong>1. Whether jena SDB support the transaction, which is thread safe ?</strong></p> <p><strong>2. How to implement the thread safe operation for jena sdb ?</strong></p> <p><strong>3. How to solve my code problem? (The exception and key code is under below)</strong></p> <p>So appreciate for your help and any suggestions. Wish any replay from you. Good Luck ~~</p> <p><strong>My key code below:(Database is DB2, database pool: Websphere datasource pool)</strong></p> <pre><code>//DBConnector is an object that get the jdbc connection from the data source //initialize and return a sdb connection object [new SDBConnection(jdbcConnection)] SDBConnection con = DBConnector.getSDBConnection(); store = SDBFactory.connectStore(con,storeDesc); model.notifyEvent(GraphEvent.startRead); model.read(in,'',"N-Triple"); model.notifyEvent(GraphEvent.finishRead); model.close(); </code></pre> <p><strong>The exception is below:</strong></p> <p>com.hp.hpl.jena.sdb.layout2.LoaderTuplesNodes.Thread-6(): Error in thread: Problem making new tupleloader</p> <p>com.hp.hpl.jena.sdb.SDBException: Problem making new tupleloader</p> <pre><code>at com.hp.hpl.jena.sdb.layout2.LoaderTuplesNodes.updateOneTuple(LoaderTuplesNodes.java:269) at com.hp.hpl.jena.sdb.layout2.LoaderTuplesNodes.access$200(LoaderTuplesNodes.java:31) at com.hp.hpl.jena.sdb.layout2.LoaderTuplesNodes$Commiter.run(LoaderTuplesNodes.java:334) at java.lang.Thread.run(Thread.java:619) </code></pre> <p>Caused by: java.lang.reflect.InvocationTargetException</p> <pre><code>at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance(Constructor.java:513) at com.hp.hpl.jena.sdb.layout2.LoaderTuplesNodes.updateOneTuple(LoaderTuplesNodes.java:265) ... 3 more </code></pre> <p>Caused by: com.hp.hpl.jena.sdb.SDBException: Problem initialising loader for [Quads]</p> <pre><code>at com.hp.hpl.jena.sdb.layout2.TupleLoaderBase.&lt;init&gt;(TupleLoaderBase.java:47) at com.hp.hpl.jena.sdb.layout2.hash.TupleLoaderHashBase.&lt;init&gt;(TupleLoaderHashBase.java:17) at com.hp.hpl.jena.sdb.layout2.hash.TupleLoaderHashDB2.&lt;init&gt;(TupleLoaderHashDB2.java:22) ... 8 more </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload