On 06/09/13 15:09, Frederic Toublanc wrote:
Hello,

I'd like to know how i can specify the system file mode of the fuseki
server when it access the TDB.

I'm using the following property when initializing the TDB in java :

TDB.getContext().set(SystemTDB.symFileMode, FileMode.direct);

And when i use Fuseki i would like it to connect to the same TDB with the
property system file mode set to "direct". It doesn't seem to be the case
by default in fuseki.

On a 64bit JVM the default is mapped mode.


Any idea ?


Tricky.  This has to be set before any TDB code runs.

I can think of two things to try:

1/ Set the context in fuseki:Server block:


[] rdf:type fuseki:Server ;
   ...
   ja:context [ ja:cxtName "tdb:fileMode" ;  ja:cxtValue "direct" ] ;
   ...
   fuseki:services (
     <#service1>
     <#service2>
   ) .


2/ Your own intialization. Instead of this line:

[] ja:loadClass "com.hp.hpl.jena.tdb.TDB" .

put in your own code here (a public class with public static void init().

[] ja:loadClass "foo.bar.MyTDBInit" .

Your code sets the file mode then calls TDB.init().

Please let me know what you try and what works.

        Andy

Reply via email to