By the way, only --set "arq:outputGraphBNodeLabels=true" works;
after insert
... ja:context
      [ ja:cxtName "arq:outputGraphBNodeLabels" ;
        ja:cxtValue "true" ] ;
to config file and restarting fuseki (1.0.0) outputs blank nodes as _:b0,
not as <_: ...>

Moreover, if I run fuseki-server with --config=config-inf-tdb.ttl --set
"arq:outputGraphBNodeLabels=true, it also ouputs as _:b0.

May be, this should be in other place?

Full config file in the end of letter.

2013/9/13 Andy Seaborne <[email protected]>

> On 12/09/13 14:52, Alexei Golovko wrote:
>
>> Is it possible to enable skolemization in Fuseki? I've found in mail
>> archive<http://mail-archives.**apache.org/mod_mbox/jena-dev/**
>> 201202.mbox/%**3CCAPTxtVMBy8JpJkkuYH0-**n2AwTiS-reN7Eur0w_01paRiu+A_**
>> [email protected]%3E<http://mail-archives.apache.org/mod_mbox/jena-dev/201202.mbox/%3ccaptxtvmby8jpjkkuyh0-n2awtis-ren7eur0w_01pariu+a...@mail.gmail.com%3E>
>> >that
>>
>> «Bnodes can be handled by enabling bNode label output, and using
>> <_:...> on input.»
>>
>> However, I couldn't find how to enable this blank node label output, or
>> use
>> it with default settings:
>> if I run
>> INSERT { 
>> [<http://www.w3.org/1999/02/**22-rdf-syntax-ns#type<http://www.w3.org/1999/02/22-rdf-syntax-ns#type>>
>> <
>> http://example.org/class>] . } WHERE {}
>> then SELECT-queries return inserted blank nodes as _:b0 or _:b2 (if query
>> result include or does not include other two blank nodes).
>>
>> I have seen an open issue https://issues.apache.org/**
>> jira/browse/JENA-193 <https://issues.apache.org/jira/browse/JENA-193>,
>> but status of each item is not clear for me.
>>
>>
> Alexei,
>
> Good question - by trail-and-error, and looking at the code, if you start
> the server with
>
> --set "arq:outputGraphBNodeLabels=**true"
>
> or have
>
> [] rdf:type fuseki:Server ;
>    ja:context
>       [ ja:cxtName "arq:outputGraphBNodeLabels" ;
>         ja:cxtValue "true" ] ;
>    ...
>
> it seems to partially works.  The bnode labels returned (XML, JSON, TSV
> formats) are the internal ids but they are not in <_:...> form and so code
> needs to text mangle them.  So there isn't consistent handling.
>
> It's server-wide, not per request.
>
> Seems like this needs cleaning up.
>
>         Andy
>
> I updated JENA-193 in passing.
>
>


Modified config-inf-tdb.ttl:

# Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0

@prefix :        <#> .
@prefix fuseki:  <http://jena.apache.org/fuseki#> .
@prefix rdf:     <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .

@prefix rdfs:   <http://www.w3.org/2000/01/rdf-schema#> .
@prefix tdb:     <http://jena.hpl.hp.com/2008/tdb#> .
@prefix ja:      <http://jena.hpl.hp.com/2005/11/Assembler#> .

[] rdf:type fuseki:Server ;
   ja:context [ ja:cxtName "arq:outputGraphBNodeLabels" ; ja:cxtValue
"true" ] ;
   fuseki:services (
     <#service1>
   ) .

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

# TDB
tdb:DatasetTDB  rdfs:subClassOf  ja:RDFDataset .
tdb:GraphTDB    rdfs:subClassOf  ja:Model .

## ---------------------------------------------------------------
## Service with only SPARQL query on an inference model.
## Inference model bbase data in TDB.

<#service1>  rdf:type fuseki:Service ;
    fuseki:name              "inf" ;             # http://host/inf
    fuseki:serviceQuery      "sparql" ;          # SPARQL query service
    fuseki:serviceUpdate     "update" ;
    fuseki:dataset           <#dataset> ;
    .

<#dataset> rdf:type       ja:RDFDataset ;
    ja:defaultGraph       <#model_inf> ;
     .

<#model_inf> a ja:InfModel ;
     ja:baseModel <#tdbGraph> ;
     ja:reasoner [
         #ja:reasonerURL <http://jena.hpl.hp.com/2003/OWLFBRuleReasoner>
         ja:reasoner [ja:reasonerClass
"org.mindswap.pellet.jena.PelletReasonerFactory"]
     ] .

<#tdbDataset> rdf:type tdb:DatasetTDB ;
    tdb:location "DB" ;
    # If the unionDefaultGraph is used, then the "update" service should be
removed.
    # The unionDefaultGraph is read only.
    # tdb:unionDefaultGraph true ;
    .

<#tdbGraph> rdf:type tdb:GraphTDB ;
    tdb:dataset <#tdbDataset> .

Reply via email to