This is very interesting. It's a synchronization bug of mine which never happens with 0.8.9 and is perfectly reproducible with the snapshot. I have a 'background sync' thread.
So, the steps are something like: load a new graph into the database with some ontology. try to run my query. in parallel, the sync thread calls TDB.sync, with no synchronization between the thread running the query and the sync. *blam* I assume that this is entirely my problem unless you tell me otherwise, in which case I'll attach the small test case I just concocted. On Thu, Feb 3, 2011 at 4:33 AM, Andy Seaborne <[email protected]> wrote: > Works for me (on the test data from before). > > tdbloader --loc DB ~/Desktop/1k_news.nq.gz > tdbquery --loc=DB --file=Q.rq > => result model. > > Iterators count as read operations - you can't update a model and continue > to iterate over results (which is what CONSTRUCT is doing). > > sync'ing a dataset is a write operation. > > Andy > > PS The file extension for SPARQL queries is ".rq". The extension for SPARQL > Update is ".ru" (where "is" is defined to be "when the W3C registers the > MIME type"). > > > On 03/02/11 02:02, Benson Margulies wrote: >> >> Jira shortly I hope. >> >> Caused by: java.util.ConcurrentModificationException: Iterator: >> started at 266532, now 266533 >> at >> com.hp.hpl.jena.tdb.sys.ConcurrencyPolicyMRSW.policyError(ConcurrencyPolicyMRSW.java:127) >> at >> com.hp.hpl.jena.tdb.sys.ConcurrencyPolicyMRSW.access$000(ConcurrencyPolicyMRSW.java:18) >> at >> com.hp.hpl.jena.tdb.sys.ConcurrencyPolicyMRSW$IteratorCheckNotConcurrent.checkCourrentModification(ConcurrencyPolicyMRSW.java:90) >> at >> com.hp.hpl.jena.tdb.sys.ConcurrencyPolicyMRSW$IteratorCheckNotConcurrent.hasNext(ConcurrencyPolicyMRSW.java:97) >> at org.openjena.atlas.iterator.Iter$4.hasNext(Iter.java:262) >> at org.openjena.atlas.iterator.Iter$3.hasNext(Iter.java:152) >> at org.openjena.atlas.iterator.Iter.hasNext(Iter.java:596) >> at >> org.openjena.atlas.iterator.RepeatApplyIterator.hasNext(RepeatApplyIterator.java:46) >> at org.openjena.atlas.iterator.Iter$4.hasNext(Iter.java:262) >> at >> com.hp.hpl.jena.sparql.engine.iterator.QueryIterPlainWrapper.hasNextBinding(QueryIterPlainWrapper.java:42) >> at >> com.hp.hpl.jena.sparql.engine.iterator.QueryIteratorBase.hasNext(QueryIteratorBase.java:66) >> at >> com.hp.hpl.jena.sparql.engine.iterator.QueryIterProcessBinding.hasNextBinding(QueryIterProcessBinding.java:48) >> at >> com.hp.hpl.jena.sparql.engine.iterator.QueryIteratorBase.hasNext(QueryIteratorBase.java:66) >> at >> com.hp.hpl.jena.sparql.engine.iterator.QueryIterConcat.hasNextBinding(QueryIterConcat.java:70) >> at >> com.hp.hpl.jena.sparql.engine.iterator.QueryIteratorBase.hasNext(QueryIteratorBase.java:66) >> at >> com.hp.hpl.jena.sparql.engine.iterator.QueryIterRepeatApply.hasNextBinding(QueryIterRepeatApply.java:57) >> at >> com.hp.hpl.jena.sparql.engine.iterator.QueryIteratorBase.hasNext(QueryIteratorBase.java:66) >> at >> com.hp.hpl.jena.sparql.engine.iterator.QueryIterProcessBinding.hasNextBinding(QueryIterProcessBinding.java:48) >> at >> com.hp.hpl.jena.sparql.engine.iterator.QueryIteratorBase.hasNext(QueryIteratorBase.java:66) >> at >> com.hp.hpl.jena.sparql.engine.iterator.QueryIterDefaulting.hasNextBinding(QueryIterDefaulting.java:43) >> at >> com.hp.hpl.jena.sparql.engine.iterator.QueryIteratorBase.hasNext(QueryIteratorBase.java:66) >> at >> com.hp.hpl.jena.sparql.engine.iterator.QueryIterRepeatApply.hasNextBinding(QueryIterRepeatApply.java:57) >> at >> com.hp.hpl.jena.sparql.engine.iterator.QueryIteratorBase.hasNext(QueryIteratorBase.java:66) >> at >> com.hp.hpl.jena.sparql.engine.iterator.QueryIteratorWrapper.hasNextBinding(QueryIteratorWrapper.java:28) >> at >> com.hp.hpl.jena.sparql.engine.iterator.QueryIteratorBase.hasNext(QueryIteratorBase.java:66) >> at >> com.hp.hpl.jena.sparql.engine.iterator.QueryIteratorWrapper.hasNextBinding(QueryIteratorWrapper.java:28) >> at >> com.hp.hpl.jena.sparql.engine.iterator.QueryIteratorBase.hasNext(QueryIteratorBase.java:66) >> at >> com.hp.hpl.jena.sparql.engine.QueryExecutionBase.execConstruct(QueryExecutionBase.java:117) >> at >> com.basistech.jug.rdfdb.jena.JenaStore.executeConstructQuery(JenaStore.java:127) >> at >> com.basistech.jug.rdfdb.jena.QueryManager.runConstructQuery(QueryManager.java:59) >> at >> com.basistech.jug.rdfdb.service.query.QueryService.constructQuery(QueryService.java:166) >> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) >> at >> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) >> at >> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) >> at java.lang.reflect.Method.invoke(Method.java:597) >> at >> org.apache.cxf.service.invoker.AbstractInvoker.performInvocation(AbstractInvoker.java:173) >> at >> org.apache.cxf.service.invoker.AbstractInvoker.invoke(AbstractInvoker.java:89) >> ... 29 more >
