Hi Sarven,
first of all, thanks for your email.

This is about an open issue (an improvement) which aim is to add the new LARQ
(i.e. the one as separate module) to Fuseki and make it as easy as possible for
people to use.

See: https://issues.apache.org/jira/browse/JENA-63
The issue is still open and there are problems.
I cleaned up the attachments on JENA-63 and uploaded a new patch for Fuseki.

This is how you can apply the patch to Fuseki:

cd /tmp
svn co http://svn.apache.org/repos/asf/incubator/jena/Jena2/Fuseki/trunk/ fuseki
cd /tmp/fuseki
wget https://issues.apache.org/jira/secure/attachment/12482758/JENA-63_Fuseki_r1136050.patch
patch -p0 < JENA-63_Fuseki_r1136050.patch
mvn package

Then you should be able to index a dataset using:

java -cp target/fuseki-0.2.1-SNAPSHOT-sys.jar larq.larqbuilder --allow-duplicates --larq=/tmp/lucene --desc=/path/to/your/assembler.ttl

However, there is a problem (I improved the error message):

10:32:35 WARN DataSourceAssembler :: Unable to initialize LARQ using org.apache.jena.larq.assembler.AssemblerLARQ: Lock obtain timed out: NativeFSLock@/tmp/lucene/write.lock

This is the stack trace:

java.lang.reflect.InvocationTargetException
        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 com.hp.hpl.jena.sparql.core.assembler.DataSourceAssembler.createTextIndex(DataSourceAssembler.java:115) at com.hp.hpl.jena.sparql.core.assembler.DataSourceAssembler.createTextIndex(DataSourceAssembler.java:97) at com.hp.hpl.jena.sparql.core.assembler.DatasetAssembler.open(DatasetAssembler.java:22) at com.hp.hpl.jena.assembler.assemblers.AssemblerGroup$PlainAssemblerGroup.openBySpecificType(AssemblerGroup.java:118) at com.hp.hpl.jena.assembler.assemblers.AssemblerGroup$PlainAssemblerGroup.open(AssemblerGroup.java:105) at com.hp.hpl.jena.assembler.assemblers.AssemblerGroup$ExpandingAssemblerGroup.open(AssemblerGroup.java:69)
        at 
com.hp.hpl.jena.assembler.assemblers.AssemblerBase.open(AssemblerBase.java:37)
        at 
com.hp.hpl.jena.assembler.assemblers.AssemblerBase.open(AssemblerBase.java:34)
at com.hp.hpl.jena.sparql.core.assembler.AssemblerUtils.build(AssemblerUtils.java:88)
        at arq.cmdline.ModAssembler.create(ModAssembler.java:55)
        at 
arq.cmdline.ModDatasetAssembler.createDataset(ModDatasetAssembler.java:31)
        at arq.cmdline.ModDataset.getDataset(ModDataset.java:22)
        at larq.larqbuilder.exec(larqbuilder.java:84)
        at arq.cmdline.CmdMain.mainMethod(CmdMain.java:85)
        at arq.cmdline.CmdMain.mainRun(CmdMain.java:47)
        at arq.cmdline.CmdMain.mainRun(CmdMain.java:34)
        at larq.larqbuilder.main(larqbuilder.java:50)
Caused by: org.apache.lucene.store.LockObtainFailedException: Lock obtain timed out: NativeFSLock@/tmp/lucene/write.lock
        at org.apache.lucene.store.Lock.obtain(Lock.java:84)
        at org.apache.lucene.index.IndexWriter.<init>(IndexWriter.java:1097)
        at 
org.apache.jena.larq.IndexWriterFactory.create(IndexWriterFactory.java:36)
        at 
org.apache.jena.larq.assembler.AssemblerLARQ.make(AssemblerLARQ.java:85)
        ... 21 more


It seems to me that Lucene is failing to acquire the write.lock,
as if initialization code were called twice.

I have not yet identified the cause of this and I am investigating.

Apologies and be patience (until we make progress and we close JENA-63).

Paolo

Sarven Capadisli wrote:
Hi,

I'd like to get Fuseki and LARQ running. Below is where I'm at. Any help
would be great:

I use https://svn.apache.org/repos/asf/incubator/jena/Jena2/Fuseki/trunk
and it sits at /usr/lib/fuseki

I have
http://ftp.heanet.ie/mirrors/www.apache.org/dist//lucene/java/3.2.0/lucene-3.2.0.tgz
 at /usr/lib/lucene/

I've applied
https://issues.apache.org/jira/secure/attachment/12478735/JENA-63_Fuseki_r8810.patch

My /usr/lib/fuseki/pom.xml is http://pastebin.com/Cpaz75ai

My /usr/lib/fuseki/tdb2.ttl is http://pastebin.com/SXv5LWEn

When I run
$java -cp target/fuseki-0.2.1-SNAPSHOT-sys.jar larq.larqbuilder
--allow-duplicates --larq=/usr/lib/lucene/index/
--desc=/usr/lib/fuseki/tdb2.ttl

I get http://pastebin.com/JQPqsPtH

-Sarven


Reply via email to