You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@jena.apache.org by Bardo Nelgen <ma...@bnnperformances.de> on 2021/04/22 07:10:06 UTC

Jena 4 and RDF/XML via Fuseki

Hi all,
�
Maybe there is something about Jena 4 with outputting „pretty“ 
RDF/XML via Fuseki ?
�
Whenever asking Fuseki (i.e. via HTTP… – be it from the GUI or via 
curl) for RDF/XML results, it now ALWAYS defaults to SRX 
(application/SPARQL-results+xml).
�
The behaviour could be changed in older versions by sending an 
Accept-Header for application/rdf+xml. With version 4.0, this option 
appears to be gone.

For now, I am through with the release notes, existing bug reports and 
the list archive already but find nothing coming similar to what we 
currently experience.�

What is the contemporary approach to achieve the desired result ?
�
Thanks in advance for any input.
�
 Best,

 Bardo

Re: Jena 4 and RDF/XML via Fuseki

Posted by Andy Seaborne <an...@apache.org>.

On 23/04/2021 10:23, Bardo Nelgen wrote:
> Thanks Andy, for the hint.
> 
> Would you mind explaining what you mean by "read the result locally" – 

In the client:

Model model = execConstruct ...
StringWriter out = ...
RDFDataMgr.write(out, model, RDFFormat.RDFXML_PRETTY)
Strign rdfxml = out.toString();

> or point to a link with the explanation ?�
> 
> The official JENA documentation still describes the "old" way…

It isn't documented what the exact form of the RDF/XML format is for 
Fuseki. The HTTP content negotiation contract is valid RDF/XML which it is.

The server is protected, and has less CPU load, and consequently is more 
stable, if it uses the plain RDF/XML.

> My problem is not RDF validity – but an entire XSLT-based web portal 
> relying on the rather foreseeable outputs of RIOT.

RDFXML_PRETTY can jump around on quite small changes in the data, mainly 
due to blank nodes.

Plain RDF/XML is more predicable, as is TriX.

> Any suggestion is highly appreciated, as "using any toolkit" 
> doesobviouslyno longer include JENA.

Yes, it does. See above.

RDFFormat.RDFXML_PRETTY
https://jena.apache.org/documentation/io/rdf-output.html#rdfxml

     Andy

> �
> 
> On 23.04.21 10.29 Uhr, Andy Seaborne wrote:
>> You can read the result locally and writing it out in the format 
>> variant of choice using any toolkit. RDF/XML is a standards-defined 
>> format.
>>
>> No information is lost in the plain format nor does one format relate 
>> to the RDF structure in a way the other does not.
>>
>>    Andy
>>
>> On 23/04/2021 07:25, Bardo Nelgen wrote:
>>> Indeed. But that was just an example – I need the subsequent cascades 
>>> as well…
>>>
>>> On 23.04.21 08.00 Uhr, Martynas Jusevičius wrote:
>>>> Not what I said :)
>>>>
>>>> Changing <rdf:Description> to an element with class name would take one 
>>> or
>>>> two XSLT templates.
>>>>
>>>> On Fri, 23 Apr 2021 at 07.45, Bardo Nelgen <
>>>> mailing.list.inbox@bnnperformances.de> wrote:
>>>>
>>>>> Re-Writing entire RIOT in XSLT ?
>>>>>
>>>>> Probably not the most versatile approach… ;-)
>>>>>
>>>>> On 23.04.21 07.40 Uhr, Martynas Jusevičius wrote:
>>>>>> Is your client reading the data as RDF or XML?
>>>>>>
>>>>>> You could apply an XSLT stylesheet to transform plain RDF/XML to 
>>>>>> pretty.
>>>>>>
>>>>>> On Fri, 23 Apr 2021 at 06.38, Bardo Nelgen <
>>>>>> mailing.list.inbox@bnnperformances.de> wrote:
>>>>>>
>>>>>>> Thanks for the insight – I do not doubt, that turningoff"pretty",
>>>>>>>
>>>>>>> rather than improving it, has been the "easier" choice an the time;
>>>>>>> though this does not change the fact, that I need my data 
>>>>>>> formatted this
>>>>>>> way and would like to learn how to get it.
>>>>>>>
>>>>>>> On 22.04.21 18.47 Uhr, Martynas Jusevičius wrote:
>>>>>>>> Actually Andy explained in this thread why this change was 
>>>>>>>> introduced
>>>>>>>> back in 3.15.0:https://issues.apache.org/jira/browse/JENA-1826
>>>>>>>>
>>>>>>>> On Thu, Apr 22, 2021 at 6:44 PM Martynas Jusevičius
>>>>>>>> <ma...@atomgraph.com>    wrote:
>>>>>>>>> It's the same data, just formatted in a slightly different way. It
>>>>>>>>> seems that RDFXML_PLAIN is the default RDF/XML writer in Jena 4.0:
>>>>>>>>> https://jena.apache.org/documentation/io/rdf-output.html#rdfxml
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On Thu, Apr 22, 2021 at 5:27 PM Bardo Nelgen
>>>>>>>>> <ma...@bnnperformances.de>  � wrote:
>>>>>>>>>> Sorry, of course you are right – both.
>>>>>>>>>>
>>>>>>>>>> When I looked at the output for the last time, I had a SELECT 
>>>>>>>>>> query
>>>>>>>>>> running – thus completely foreseeable getting
>>>>>>>>>> application/sparql-results+xml.
>>>>>>>>>>
>>>>>>>>>> What I was originally looking for is to format the result of a
>>>>>>> CONSTRUCT
>>>>>>>>>> query, which as of now comes out quite linear like:
>>>>>>>>>>
>>>>>>>>>>>        <rdf:Description
>>>>>>>>>>> rdf:about="
>>>>>>> http://resources.semaworx.eu/inventory/ActivityStreams/current/">
>>>>>>>>>>>            <rdf:type
>>>>>>>>>>> rdf:resource="
>>>>>>> http://namespaces.semaworx.org/inventoryControl/ActivityStreamGroup"/> 
>>>>>>>
>>>>>>>>>>>            (… some ?p ?o here …)
>>>>>>>>>>>
>>>>>>>>>>>        </rdf:Description>
>>>>>>>>>> Though, what I have been looking for, is supposed to come out 
>>>>>>>>>> more
>>>>>>> like:
>>>>>>>>>>>        <rdf:RDF
>>>>>>>>>>> xmlns:ive="http://namespaces.semaworx.org/inventoryControl/">
>>>>>>>>>>>
>>>>>>>>>>>        <ive:ActivityStreamGroup
>>>>>>>>>>> rdf:about="
>>>>>>> http://resources.semaworx.eu/inventory/ActivityStreams/current/">
>>>>>>>>>>>        (… some ?p ?o here …)
>>>>>>>>>>>
>>>>>>>>>>>        </ive:ActivityStreamGroup>
>>>>>>>>>>>
>>>>>>>>>>>     Â </rdf:RDF>
>>>>>>>>>> I’m quite aware I may have missed a change of defaults here.
>>>>>>>>>>
>>>>>>>>>> All I need to know is learning how to do this from now on.
>>>>>>>>>>
>>>>>>>>>> — Bardo
>>>>>>>>>>
>>>>>>>>>> On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
>>>>>>>>>>> On 22/04/2021 09:55, Rob Vesse wrote:
>>>>>>>>>>>> What is the query?
>>>>>>>>>>>>
>>>>>>>>>>>> RDF/XML is a graph format and so only makes sense for
>>>>>>>>>>>> CONSTRUCT/DESCRIBE queries
>>>>>>>>>>>>
>>>>>>>>>>>> ASK/SELECT queries are going to produce tabular results 
>>>>>>>>>>>> which uses
>>>>>>>>>>>> the SPARQL XML Results format by default.
>>>>>>>>>>>>
>>>>>>>>>>>> Historically there was an ability to transcribe the tabular 
>>>>>>>>>>>> format
>>>>>>>>>>>> into a graph but this was a very niche use case (primarily only
>>>>> used
>>>>>>>>>>>> in the SPARQL test suite itself).  There were a bunch of 
> 
>>>>>>>>>>>> changes in
>>>>>>>>>>>> Jena 4.x to simplify Content-Type handling to only use 
>>>>>>>>>>>> canonical
>>>>>>>>>>>> formats by default.
>>>>>>>>>>>>
>>>>>>>>>>>> Rob
>>>>>>>>>>> Using
>>>>>>>>>>>
>>>>>>>>>>> curl --header 'Accept: application/rdf+xml'
>>>>>>>>>>>
>>>>>>>>>>> works for me.
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Use of "pretty", to become the more basic form of RDF/XML 
>>>>>>>>>>> changed
>>>>>>>>>>> several versions ago at 3.15.0. But that is not
>>>>>>>>>>> application/sparql-results+xml.
>>>>>>>>>>>
>>>>>>>>>>> https://issues.apache.org/jira/browse/JENA-1826
>>>>>>>>>>>
>>>>>>>>>>> Please can we have an example with query, curl call and versions
>>>>>>> numbers?
>>>>>>>>>>>       Andy
>>>>>>>>>>>
>>>>>>>>>>>> On 22/04/2021, 08:10, "Bardo Nelgen"
>>>>>>>>>>>> <ma...@bnnperformances.de>    wrote:
>>>>>>>>>>>>
>>>>>>>>>>>>         Hi all,
>>>>>>>>>>>>         �
>>>>>>>>>>>>         Maybe there is something about Jena 4 with outputting
>>>>>>>>>>>> „pretty“
>>>>>>>>>>>>         RDF/XML via Fuseki 
> ?
>>>>>>>>>>>>         �
>>>>>>>>>>>>         Whenever asking Fuseki (i.e. via HTTP…
>>>>>>>>>> – be it from the
>>>>>>>>>>>> GUI or via
>>>>>>>>>>>>         curl) for RDF/XML results, it now ALWAYS defaults to 
>>>>>>>>>>>> SRX
>>>>>>>>>>>>         (application/SPARQL-results+xml).
>>>>>>>>>>>>         �
>>>>>>>>>>>>         The behaviour could be changed in older versions by 
>>>>>>>>>>>> sending
>>>>> an
>>>>>>>>>>>>         Accept-Header for application/rdf+xml. With version 
>>>>>>>>>>>> 4.0,
>>>>>>>>>>>> this option
>>>>>>>>>>>>         appears to be gone.
>>>>>>>>>>>>
>>>>>>>>>>>>         For now, I am through with the release notes,
>>>>>>>>>> existing bug
>>>>>>>>>>>> reports and
>>>>>>>>>>>>         the list archive already but find nothing coming 
>>>>>>>>>>>> similar to
>>>>>>>>>>>> what we
>>>>>>>>>>>>         currently experience.�
>>>>>>>>>>>>
>>>>>>>>>>>>         What is the contemporary approach to achieve the 
>>>>>>>>>>>> desired
>>>>>>>>>>>> result ?
>>>>>>>>>>>>         �
>>>>>>>>>>>>         Thanks in advance for any input.
>>>>>>>>>>>>         �
>>>>>>>>>>>>          Best,
>>>>>>>>>>>>
>>>>>>>>>>>>          Bardo
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>> On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
>>>>>>>>>>> On 22/04/2021 09:55, Rob Vesse wrote:
>>>>>>>>>>>> What is the query?
>>>>>>>>>>>>
>>>>>>>>>>>> RDF/XML is a graph format and so only makes sense for
>>>>>>>>>>>> CONSTRUCT/DESCRIBE queries
>>>>>>>>>>>>
>>>>>>>>>>>> ASK/SELECT queries are going to produce tabular results 
>>>>>>>>>>>> which uses
>>>>>>>>>>>> the SPARQL XML Results format by default.
>>>>>>>>>>>>
>>>>>>>>>>>> Historically there was an ability to transcribe the tabular 
>>>>>>>>>>>> format
>>>>>>>>>>>> into a graph but this was a very niche use case (primarily only
>>>>> used
>>>>>>>>>>>> in the SPARQL test suite itself).  There were a bunch of 
> 
>>>>>>>>>>>> changes in
>>>>>>>>>>>> Jena 4.x to simplify Content-Type handling to only use 
>>>>>>>>>>>> canonical
>>>>>>>>>>>> formats by default.
>>>>>>>>>>>>
>>>>>>>>>>>> Rob
>>>>>>>>>>> Using
>>>>>>>>>>>
>>>>>>>>>>> curl --header 'Accept: application/rdf+xml'
>>>>>>>>>>>
>>>>>>>>>>> works for me.
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Use of "pretty", to become the more basic form of RDF/XML 
>>>>>>>>>>> changed
>>>>>>>>>>> several versions ago at 3.15.0. But that is not
>>>>>>>>>>> application/sparql-results+xml.
>>>>>>>>>>>
>>>>>>>>>>> https://issues.apache.org/jira/browse/JENA-1826
>>>>>>>>>>>
>>>>>>>>>>> Please can we have an example with query, curl call and versions
>>>>>>> numbers?
>>>>>>>>>>>       Andy
>>>>>>>>>>>
>>>>>>>>>>>> On 22/04/2021, 08:10, "Bardo Nelgen"
>>>>>>>>>>>> <ma...@bnnperformances.de>    wrote:
>>>>>>>>>>>>
>>>>>>>>>>>>         Hi all,
>>>>>>>>>>>>         �
>>>>>>>>>>>>         Maybe there is something about Jena 4 with outputting
>>>>>>>>>>>> „pretty“
>>>>>>>>>>>>         RDF/XML via Fuseki 
> ?
>>>>>>>>>>>>         �
>>>>>>>>>>>>         Whenever asking Fuseki (i.e. via HTTP…
>>>>>>>>>> – be it from the
>>>>>>>>>>>> GUI or via
>>>>>>>>>>>>         curl) for RDF/XML results, it now ALWAYS defaults to 
>>>>>>>>>>>> SRX
>>>>>>>>>>>>         (application/SPARQL-results+xml).
>>>>>>>>>>>>         �
>>>>>>>>>>>>         The behaviour could be changed in older versions by 
>>>>>>>>>>>> sending
>>>>> an
>>>>>>>>>>>>         Accept-Header for application/rdf+xml. With version 
>>>>>>>>>>>> 4.0,
>>>>>>>>>>>> this option
>>>>>>>>>>>>         appears to be gone.
>>>>>>>>>>>>
>>>>>>>>>>>>         For now, I am through with the release notes,
>>>>>>>>>> existing bug
>>>>>>>>>>>> reports and
>>>>>>>>>>>>         the list archive already but find nothing coming 
>>>>>>>>>>>> similar to
>>>>>>>>>>>> what we
>>>>>>>>>>>>         currently experience.�
>>>>>>>>>>>>
>>>>>>>>>>>>         What is the contemporary approach to achieve the 
>>>>>>>>>>>> desired
>>>>>>>>>>>> result ?
>>>>>>>>>>>>         �
>>>>>>>>>>>>         Thanks in advance for any input.
>>>>>>>>>>>>         �
>>>>>>>>>>>>          Best,
>>>>>>>>>>>>
>>>>>>>>>>>>          Bardo
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>

Re: Jena 4 and RDF/XML via Fuseki

Posted by Bardo Nelgen <ma...@bnnperformances.de>.
Thanks Andy, for the hint.

Would you mind explaining what you mean by "read the result locally" – 
or point to a link with the explanation ?�

The official JENA documentation still describes the "old" way…

My problem is not RDF validity – but an entire XSLT-based web portal 
relying on the rather foreseeable outputs of RIOT.

Any suggestion is highly appreciated, as "using any toolkit" 
doesobviouslyno longer include JENA.
�

On 23.04.21 10.29 Uhr, Andy Seaborne wrote:
> You can read the result locally and writing it out in the format 
> variant of choice using any toolkit. RDF/XML is a standards-defined 
> format.
>
> No information is lost in the plain format nor does one format relate 
> to the RDF structure in a way the other does not.
>
>    Andy
>
> On 23/04/2021 07:25, Bardo Nelgen wrote:
>> Indeed. But that was just an example – I need the subsequent 
>> cascades as well…
>>
>> On 23.04.21 08.00 Uhr, Martynas Jusevičius wrote:
>>> Not what I said :)
>>>
>>> Changing <rdf:Description> to an element with class name would take one 
>> or
>>> two XSLT templates.
>>>
>>> On Fri, 23 Apr 2021 at 07.45, Bardo Nelgen <
>>> mailing.list.inbox@bnnperformances.de> wrote:
>>>
>>>> Re-Writing entire RIOT in XSLT ?
>>>>
>>>> Probably not the most versatile approach… ;-)
>>>>
>>>> On 23.04.21 07.40 Uhr, Martynas Jusevičius wrote:
>>>>> Is your client reading the data as RDF or XML?
>>>>>
>>>>> You could apply an XSLT stylesheet to transform plain RDF/XML to 
>>>>> pretty.
>>>>>
>>>>> On Fri, 23 Apr 2021 at 06.38, Bardo Nelgen <
>>>>> mailing.list.inbox@bnnperformances.de> wrote:
>>>>>
>>>>>> Thanks for the insight – I do not doubt, that turningoff"pretty",
>>>>>>
>>>>>> rather than improving it, has been the "easier" choice an the time;
>>>>>> though this does not change the fact, that I need my data 
>>>>>> formatted this
>>>>>> way and would like to learn how to get it.
>>>>>>
>>>>>> On 22.04.21 18.47 Uhr, Martynas Jusevičius wrote:
>>>>>>> Actually Andy explained in this thread why this change was 
>>>>>>> introduced
>>>>>>> back in 3.15.0:https://issues.apache.org/jira/browse/JENA-1826
>>>>>>>
>>>>>>> On Thu, Apr 22, 2021 at 6:44 PM Martynas Jusevičius
>>>>>>> <ma...@atomgraph.com>    wrote:
>>>>>>>> It's the same data, just formatted in a slightly different way. It
>>>>>>>> seems that RDFXML_PLAIN is the default RDF/XML writer in Jena 4.0:
>>>>>>>> https://jena.apache.org/documentation/io/rdf-output.html#rdfxml
>>>>>>>>
>>>>>>>>
>>>>>>>> On Thu, Apr 22, 2021 at 5:27 PM Bardo Nelgen
>>>>>>>> <ma...@bnnperformances.de>  � wrote:
>>>>>>>>> Sorry, of course you are right – both.
>>>>>>>>>
>>>>>>>>> When I looked at the output for the last time, I had a SELECT 
>>>>>>>>> query
>>>>>>>>> running – thus completely foreseeable getting
>>>>>>>>> application/sparql-results+xml.
>>>>>>>>>
>>>>>>>>> What I was originally looking for is to format the result of a
>>>>>> CONSTRUCT
>>>>>>>>> query, which as of now comes out quite linear like:
>>>>>>>>>
>>>>>>>>>>        <rdf:Description
>>>>>>>>>> rdf:about="
>>>>>> http://resources.semaworx.eu/inventory/ActivityStreams/current/">
>>>>>>>>>>            <rdf:type
>>>>>>>>>> rdf:resource="
>>>>>> http://namespaces.semaworx.org/inventoryControl/ActivityStreamGroup"/> 
>>>>>>
>>>>>>>>>>            (… some ?p ?o here …)
>>>>>>>>>>
>>>>>>>>>>        </rdf:Description>
>>>>>>>>> Though, what I have been looking for, is supposed to come out 
>>>>>>>>> more
>>>>>> like:
>>>>>>>>>>        <rdf:RDF
>>>>>>>>>> xmlns:ive="http://namespaces.semaworx.org/inventoryControl/">
>>>>>>>>>>
>>>>>>>>>>        <ive:ActivityStreamGroup
>>>>>>>>>> rdf:about="
>>>>>> http://resources.semaworx.eu/inventory/ActivityStreams/current/">
>>>>>>>>>>        (… some ?p ?o here …)
>>>>>>>>>>
>>>>>>>>>>        </ive:ActivityStreamGroup>
>>>>>>>>>>
>>>>>>>>>>     Â </rdf:RDF>
>>>>>>>>> I’m quite aware I may have missed a change of defaults here.
>>>>>>>>>
>>>>>>>>> All I need to know is learning how to do this from now on.
>>>>>>>>>
>>>>>>>>> — Bardo
>>>>>>>>>
>>>>>>>>> On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
>>>>>>>>>> On 22/04/2021 09:55, Rob Vesse wrote:
>>>>>>>>>>> What is the query?
>>>>>>>>>>>
>>>>>>>>>>> RDF/XML is a graph format and so only makes sense for
>>>>>>>>>>> CONSTRUCT/DESCRIBE queries
>>>>>>>>>>>
>>>>>>>>>>> ASK/SELECT queries are going to produce tabular results 
>>>>>>>>>>> which uses
>>>>>>>>>>> the SPARQL XML Results format by default.
>>>>>>>>>>>
>>>>>>>>>>> Historically there was an ability to transcribe the tabular 
>>>>>>>>>>> format
>>>>>>>>>>> into a graph but this was a very niche use case (primarily only
>>>> used
>>>>>>>>>>> in the SPARQL test suite itself).  There were a bunch of 

>>>>>>>>>>> changes in
>>>>>>>>>>> Jena 4.x to simplify Content-Type handling to only use 
>>>>>>>>>>> canonical
>>>>>>>>>>> formats by default.
>>>>>>>>>>>
>>>>>>>>>>> Rob
>>>>>>>>>> Using
>>>>>>>>>>
>>>>>>>>>> curl --header 'Accept: application/rdf+xml'
>>>>>>>>>>
>>>>>>>>>> works for me.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Use of "pretty", to become the more basic form of RDF/XML 
>>>>>>>>>> changed
>>>>>>>>>> several versions ago at 3.15.0. But that is not
>>>>>>>>>> application/sparql-results+xml.
>>>>>>>>>>
>>>>>>>>>> https://issues.apache.org/jira/browse/JENA-1826
>>>>>>>>>>
>>>>>>>>>> Please can we have an example with query, curl call and versions
>>>>>> numbers?
>>>>>>>>>>       Andy
>>>>>>>>>>
>>>>>>>>>>> On 22/04/2021, 08:10, "Bardo Nelgen"
>>>>>>>>>>> <ma...@bnnperformances.de>    wrote:
>>>>>>>>>>>
>>>>>>>>>>>         Hi all,
>>>>>>>>>>>         �
>>>>>>>>>>>         Maybe there is something about Jena 4 with 
>>>>>>>>>>> outputting
>>>>>>>>>>> „pretty“
>>>>>>>>>>>         RDF/XML via Fuseki 
?
>>>>>>>>>>>         �
>>>>>>>>>>>         Whenever asking Fuseki (i.e. via HTTP…
>>>>>>>>> – be it from the
>>>>>>>>>>> GUI or via
>>>>>>>>>>>         curl) for RDF/XML results, it now ALWAYS 
>>>>>>>>>>> defaults to SRX
>>>>>>>>>>>         (application/SPARQL-results+xml).
>>>>>>>>>>>         �
>>>>>>>>>>>         The behaviour could be changed in older 
>>>>>>>>>>> versions by sending
>>>> an
>>>>>>>>>>>         Accept-Header for application/rdf+xml. With 
>>>>>>>>>>> version 4.0,
>>>>>>>>>>> this option
>>>>>>>>>>>         appears to be gone.
>>>>>>>>>>>
>>>>>>>>>>>         For now, I am through with the release notes,
>>>>>>>>> existing bug
>>>>>>>>>>> reports and
>>>>>>>>>>>         the list archive already but find nothing 
>>>>>>>>>>> coming similar to
>>>>>>>>>>> what we
>>>>>>>>>>>         currently experience.�
>>>>>>>>>>>
>>>>>>>>>>>         What is the contemporary approach to achieve 
>>>>>>>>>>> the desired
>>>>>>>>>>> result ?
>>>>>>>>>>>         �
>>>>>>>>>>>         Thanks in advance for any input.
>>>>>>>>>>>         �
>>>>>>>>>>>          Best,
>>>>>>>>>>>
>>>>>>>>>>>          Bardo
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>> On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
>>>>>>>>>> On 22/04/2021 09:55, Rob Vesse wrote:
>>>>>>>>>>> What is the query?
>>>>>>>>>>>
>>>>>>>>>>> RDF/XML is a graph format and so only makes sense for
>>>>>>>>>>> CONSTRUCT/DESCRIBE queries
>>>>>>>>>>>
>>>>>>>>>>> ASK/SELECT queries are going to produce tabular results 
>>>>>>>>>>> which uses
>>>>>>>>>>> the SPARQL XML Results format by default.
>>>>>>>>>>>
>>>>>>>>>>> Historically there was an ability to transcribe the tabular 
>>>>>>>>>>> format
>>>>>>>>>>> into a graph but this was a very niche use case (primarily only
>>>> used
>>>>>>>>>>> in the SPARQL test suite itself).  There were a bunch of 

>>>>>>>>>>> changes in
>>>>>>>>>>> Jena 4.x to simplify Content-Type handling to only use 
>>>>>>>>>>> canonical
>>>>>>>>>>> formats by default.
>>>>>>>>>>>
>>>>>>>>>>> Rob
>>>>>>>>>> Using
>>>>>>>>>>
>>>>>>>>>> curl --header 'Accept: application/rdf+xml'
>>>>>>>>>>
>>>>>>>>>> works for me.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Use of "pretty", to become the more basic form of RDF/XML 
>>>>>>>>>> changed
>>>>>>>>>> several versions ago at 3.15.0. But that is not
>>>>>>>>>> application/sparql-results+xml.
>>>>>>>>>>
>>>>>>>>>> https://issues.apache.org/jira/browse/JENA-1826
>>>>>>>>>>
>>>>>>>>>> Please can we have an example with query, curl call and versions
>>>>>> numbers?
>>>>>>>>>>       Andy
>>>>>>>>>>
>>>>>>>>>>> On 22/04/2021, 08:10, "Bardo Nelgen"
>>>>>>>>>>> <ma...@bnnperformances.de>    wrote:
>>>>>>>>>>>
>>>>>>>>>>>         Hi all,
>>>>>>>>>>>         �
>>>>>>>>>>>         Maybe there is something about Jena 4 with 
>>>>>>>>>>> outputting
>>>>>>>>>>> „pretty“
>>>>>>>>>>>         RDF/XML via Fuseki 
?
>>>>>>>>>>>         �
>>>>>>>>>>>         Whenever asking Fuseki (i.e. via HTTP…
>>>>>>>>> – be it from the
>>>>>>>>>>> GUI or via
>>>>>>>>>>>         curl) for RDF/XML results, it now ALWAYS 
>>>>>>>>>>> defaults to SRX
>>>>>>>>>>>         (application/SPARQL-results+xml).
>>>>>>>>>>>         �
>>>>>>>>>>>         The behaviour could be changed in older 
>>>>>>>>>>> versions by sending
>>>> an
>>>>>>>>>>>         Accept-Header for application/rdf+xml. With 
>>>>>>>>>>> version 4.0,
>>>>>>>>>>> this option
>>>>>>>>>>>         appears to be gone.
>>>>>>>>>>>
>>>>>>>>>>>         For now, I am through with the release notes,
>>>>>>>>> existing bug
>>>>>>>>>>> reports and
>>>>>>>>>>>         the list archive already but find nothing 
>>>>>>>>>>> coming similar to
>>>>>>>>>>> what we
>>>>>>>>>>>         currently experience.�
>>>>>>>>>>>
>>>>>>>>>>>         What is the contemporary approach to achieve 
>>>>>>>>>>> the desired
>>>>>>>>>>> result ?
>>>>>>>>>>>         �
>>>>>>>>>>>         Thanks in advance for any input.
>>>>>>>>>>>         �
>>>>>>>>>>>          Best,
>>>>>>>>>>>
>>>>>>>>>>>          Bardo
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>

Re: Jena 4 and RDF/XML via Fuseki

Posted by Andy Seaborne <an...@apache.org>.
You can read the result locally and writing it out in the format variant 
of choice using any toolkit. RDF/XML is a standards-defined format.

No information is lost in the plain format nor does one format relate to 
the RDF structure in a way the other does not.

     Andy

On 23/04/2021 07:25, Bardo Nelgen wrote:
> Indeed. But that was just an example – I need the subsequent cascades as 
> well…
> 
> On 23.04.21 08.00 Uhr, Martynas Jusevičius wrote:
>> Not what I said :)
>>
>> Changing <rdf:Description> to an element with class name would take one 
> or
>> two XSLT templates.
>>
>> On Fri, 23 Apr 2021 at 07.45, Bardo Nelgen <
>> mailing.list.inbox@bnnperformances.de> wrote:
>>
>>> Re-Writing entire RIOT in XSLT ?
>>>
>>> Probably not the most versatile approach… ;-)
>>>
>>> On 23.04.21 07.40 Uhr, Martynas Jusevičius wrote:
>>>> Is your client reading the data as RDF or XML?
>>>>
>>>> You could apply an XSLT stylesheet to transform plain RDF/XML to 
>>>> pretty.
>>>>
>>>> On Fri, 23 Apr 2021 at 06.38, Bardo Nelgen <
>>>> mailing.list.inbox@bnnperformances.de> wrote:
>>>>
>>>>> Thanks for the insight – I do not doubt, that turningoff"pretty",
>>>>>
>>>>> rather than improving it, has been the "easier" choice an the time;
>>>>> though this does not change the fact, that I need my data formatted 
>>>>> this
>>>>> way and would like to learn how to get it.
>>>>>
>>>>> On 22.04.21 18.47 Uhr, Martynas Jusevičius wrote:
>>>>>> Actually Andy explained in this thread why this change was introduced
>>>>>> back in 3.15.0:https://issues.apache.org/jira/browse/JENA-1826
>>>>>>
>>>>>> On Thu, Apr 22, 2021 at 6:44 PM Martynas Jusevičius
>>>>>> <ma...@atomgraph.com>    wrote:
>>>>>>> It's the same data, just formatted in a slightly different way. It
>>>>>>> seems that RDFXML_PLAIN is the default RDF/XML writer in Jena 4.0:
>>>>>>> https://jena.apache.org/documentation/io/rdf-output.html#rdfxml
>>>>>>>
>>>>>>>
>>>>>>> On Thu, Apr 22, 2021 at 5:27 PM Bardo Nelgen
>>>>>>> <ma...@bnnperformances.de>    wrote:
>>>>>>>> Sorry, of course you are right – both.
>>>>>>>>
>>>>>>>> When I looked at the output for the last time, I had a SELECT query
>>>>>>>> running – thus completely foreseeable getting
>>>>>>>> application/sparql-results+xml.
>>>>>>>>
>>>>>>>> What I was originally looking for is to format the result of a
>>>>> CONSTRUCT
>>>>>>>> query, which as of now comes out quite linear like:
>>>>>>>>
>>>>>>>>>        <rdf:Description
>>>>>>>>> rdf:about="
>>>>> http://resources.semaworx.eu/inventory/ActivityStreams/current/">
>>>>>>>>>            <rdf:type
>>>>>>>>> rdf:resource="
>>>>> http://namespaces.semaworx.org/inventoryControl/ActivityStreamGroup"/>
>>>>>>>>>            (… some ?p ?o here …)
>>>>>>>>>
>>>>>>>>>        </rdf:Description>
>>>>>>>> Though, what I have been looking for, is supposed to come out more
>>>>> like:
>>>>>>>>>        <rdf:RDF
>>>>>>>>> xmlns:ive="http://namespaces.semaworx.org/inventoryControl/">
>>>>>>>>>
>>>>>>>>>        <ive:ActivityStreamGroup
>>>>>>>>> rdf:about="
>>>>> http://resources.semaworx.eu/inventory/ActivityStreams/current/">
>>>>>>>>>        (… some ?p ?o here …)
>>>>>>>>>
>>>>>>>>>        </ive:ActivityStreamGroup>
>>>>>>>>>
>>>>>>>>>     Â </rdf:RDF>
>>>>>>>> I’m quite aware I may have missed a change of defaults here.
>>>>>>>>
>>>>>>>> All I need to know is learning how to do this from now on.
>>>>>>>>
>>>>>>>> — Bardo
>>>>>>>>
>>>>>>>> On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
>>>>>>>>> On 22/04/2021 09:55, Rob Vesse wrote:
>>>>>>>>>> What is the query?
>>>>>>>>>>
>>>>>>>>>> RDF/XML is a graph format and so only makes sense for
>>>>>>>>>> CONSTRUCT/DESCRIBE queries
>>>>>>>>>>
>>>>>>>>>> ASK/SELECT queries are going to produce tabular results which 
>>>>>>>>>> uses
>>>>>>>>>> the SPARQL XML Results format by default.
>>>>>>>>>>
>>>>>>>>>> Historically there was an ability to transcribe the tabular 
>>>>>>>>>> format
>>>>>>>>>> into a graph but this was a very niche use case (primarily only
>>> used
>>>>>>>>>> in the SPARQL test suite itself).  There were a bunch of 
>>>>>>>>>> changes in
>>>>>>>>>> Jena 4.x to simplify Content-Type handling to only use canonical
>>>>>>>>>> formats by default.
>>>>>>>>>>
>>>>>>>>>> Rob
>>>>>>>>> Using
>>>>>>>>>
>>>>>>>>> curl --header 'Accept: application/rdf+xml'
>>>>>>>>>
>>>>>>>>> works for me.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Use of "pretty", to become the more basic form of RDF/XML changed
>>>>>>>>> several versions ago at 3.15.0. But that is not
>>>>>>>>> application/sparql-results+xml.
>>>>>>>>>
>>>>>>>>> https://issues.apache.org/jira/browse/JENA-1826
>>>>>>>>>
>>>>>>>>> Please can we have an example with query, curl call and versions
>>>>> numbers?
>>>>>>>>>       Andy
>>>>>>>>>
>>>>>>>>>> On 22/04/2021, 08:10, "Bardo Nelgen"
>>>>>>>>>> <ma...@bnnperformances.de>    wrote:
>>>>>>>>>>
>>>>>>>>>>         Hi all,
>>>>>>>>>>         �
>>>>>>>>>>         Maybe there is something about Jena 4 with outputting
>>>>>>>>>> „pretty“
>>>>>>>>>>         RDF/XML via Fuseki ?
>>>>>>>>>>         �
>>>>>>>>>>         Whenever asking Fuseki (i.e. via HTTP…
>>>>>>>> – be it from the
>>>>>>>>>> GUI or via
>>>>>>>>>>         curl) for RDF/XML results, it now ALWAYS defaults to SRX
>>>>>>>>>>         (application/SPARQL-results+xml).
>>>>>>>>>>         �
>>>>>>>>>>         The behaviour could be changed in older versions by 
>>>>>>>>>> sending
>>> an
>>>>>>>>>>         Accept-Header for application/rdf+xml. With version 4.0,
>>>>>>>>>> this option
>>>>>>>>>>         appears to be gone.
>>>>>>>>>>
>>>>>>>>>>         For now, I am through with the release notes,
>>>>>>>> existing bug
>>>>>>>>>> reports and
>>>>>>>>>>         the list archive already but find nothing coming 
>>>>>>>>>> similar to
>>>>>>>>>> what we
>>>>>>>>>>         currently experience.�
>>>>>>>>>>
>>>>>>>>>>         What is the contemporary approach to achieve the desired
>>>>>>>>>> result ?
>>>>>>>>>>         �
>>>>>>>>>>         Thanks in advance for any input.
>>>>>>>>>>         �
>>>>>>>>>>          Best,
>>>>>>>>>>
>>>>>>>>>>          Bardo
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>> On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
>>>>>>>>> On 22/04/2021 09:55, Rob Vesse wrote:
>>>>>>>>>> What is the query?
>>>>>>>>>>
>>>>>>>>>> RDF/XML is a graph format and so only makes sense for
>>>>>>>>>> CONSTRUCT/DESCRIBE queries
>>>>>>>>>>
>>>>>>>>>> ASK/SELECT queries are going to produce tabular results which 
>>>>>>>>>> uses
>>>>>>>>>> the SPARQL XML Results format by default.
>>>>>>>>>>
>>>>>>>>>> Historically there was an ability to transcribe the tabular 
>>>>>>>>>> format
>>>>>>>>>> into a graph but this was a very niche use case (primarily only
>>> used
>>>>>>>>>> in the SPARQL test suite itself).  There were a bunch of 
>>>>>>>>>> changes in
>>>>>>>>>> Jena 4.x to simplify Content-Type handling to only use canonical
>>>>>>>>>> formats by default.
>>>>>>>>>>
>>>>>>>>>> Rob
>>>>>>>>> Using
>>>>>>>>>
>>>>>>>>> curl --header 'Accept: application/rdf+xml'
>>>>>>>>>
>>>>>>>>> works for me.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Use of "pretty", to become the more basic form of RDF/XML changed
>>>>>>>>> several versions ago at 3.15.0. But that is not
>>>>>>>>> application/sparql-results+xml.
>>>>>>>>>
>>>>>>>>> https://issues.apache.org/jira/browse/JENA-1826
>>>>>>>>>
>>>>>>>>> Please can we have an example with query, curl call and versions
>>>>> numbers?
>>>>>>>>>       Andy
>>>>>>>>>
>>>>>>>>>> On 22/04/2021, 08:10, "Bardo Nelgen"
>>>>>>>>>> <ma...@bnnperformances.de>    wrote:
>>>>>>>>>>
>>>>>>>>>>         Hi all,
>>>>>>>>>>         �
>>>>>>>>>>         Maybe there is something about Jena 4 with outputting
>>>>>>>>>> „pretty“
>>>>>>>>>>         RDF/XML via Fuseki ?
>>>>>>>>>>         �
>>>>>>>>>>         Whenever asking Fuseki (i.e. via HTTP…
>>>>>>>> – be it from the
>>>>>>>>>> GUI or via
>>>>>>>>>>         curl) for RDF/XML results, it now ALWAYS defaults to SRX
>>>>>>>>>>         (application/SPARQL-results+xml).
>>>>>>>>>>         �
>>>>>>>>>>         The behaviour could be changed in older versions by 
>>>>>>>>>> sending
>>> an
>>>>>>>>>>         Accept-Header for application/rdf+xml. With version 4.0,
>>>>>>>>>> this option
>>>>>>>>>>         appears to be gone.
>>>>>>>>>>
>>>>>>>>>>         For now, I am through with the release notes,
>>>>>>>> existing bug
>>>>>>>>>> reports and
>>>>>>>>>>         the list archive already but find nothing coming 
>>>>>>>>>> similar to
>>>>>>>>>> what we
>>>>>>>>>>         currently experience.�
>>>>>>>>>>
>>>>>>>>>>         What is the contemporary approach to achieve the desired
>>>>>>>>>> result ?
>>>>>>>>>>         �
>>>>>>>>>>         Thanks in advance for any input.
>>>>>>>>>>         �
>>>>>>>>>>          Best,
>>>>>>>>>>
>>>>>>>>>>          Bardo
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>

Re: Jena 4 and RDF/XML via Fuseki

Posted by Bardo Nelgen <ma...@bnnperformances.de>.
Indeed. But that was just an example – I need the subsequent cascades 
as well…

On 23.04.21 08.00 Uhr, Martynas Jusevičius wrote:
> Not what I said :)
>
> Changing <rdf:Description> to an element with class name would take one 
or
> two XSLT templates.
>
> On Fri, 23 Apr 2021 at 07.45, Bardo Nelgen <
> mailing.list.inbox@bnnperformances.de> wrote:
>
>> Re-Writing entire RIOT in XSLT ?
>>
>> Probably not the most versatile approach… ;-)
>>
>> On 23.04.21 07.40 Uhr, Martynas Jusevičius wrote:
>>> Is your client reading the data as RDF or XML?
>>>
>>> You could apply an XSLT stylesheet to transform plain RDF/XML to pretty.
>>>
>>> On Fri, 23 Apr 2021 at 06.38, Bardo Nelgen <
>>> mailing.list.inbox@bnnperformances.de> wrote:
>>>
>>>> Thanks for the insight – I do not doubt, that turningoff"pretty",
>>>>
>>>> rather than improving it, has been the "easier" choice an the time;
>>>> though this does not change the fact, that I need my data formatted this
>>>> way and would like to learn how to get it.
>>>>
>>>> On 22.04.21 18.47 Uhr, Martynas Jusevičius wrote:
>>>>> Actually Andy explained in this thread why this change was introduced
>>>>> back in 3.15.0:https://issues.apache.org/jira/browse/JENA-1826
>>>>>
>>>>> On Thu, Apr 22, 2021 at 6:44 PM Martynas Jusevičius
>>>>> <ma...@atomgraph.com>    wrote:
>>>>>> It's the same data, just formatted in a slightly different way. It
>>>>>> seems that RDFXML_PLAIN is the default RDF/XML writer in Jena 4.0:
>>>>>> https://jena.apache.org/documentation/io/rdf-output.html#rdfxml
>>>>>>
>>>>>>
>>>>>> On Thu, Apr 22, 2021 at 5:27 PM Bardo Nelgen
>>>>>> <ma...@bnnperformances.de>    wrote:
>>>>>>> Sorry, of course you are right – both.
>>>>>>>
>>>>>>> When I looked at the output for the last time, I had a SELECT query
>>>>>>> running – thus completely foreseeable getting
>>>>>>> application/sparql-results+xml.
>>>>>>>
>>>>>>> What I was originally looking for is to format the result of a
>>>> CONSTRUCT
>>>>>>> query, which as of now comes out quite linear like:
>>>>>>>
>>>>>>>>        <rdf:Description
>>>>>>>> rdf:about="
>>>> http://resources.semaworx.eu/inventory/ActivityStreams/current/">
>>>>>>>>            <rdf:type
>>>>>>>> rdf:resource="
>>>> http://namespaces.semaworx.org/inventoryControl/ActivityStreamGroup"/>
>>>>>>>>            (… some ?p ?o here …)
>>>>>>>>
>>>>>>>>        </rdf:Description>
>>>>>>> Though, what I have been looking for, is supposed to come out more
>>>> like:
>>>>>>>>        <rdf:RDF
>>>>>>>> xmlns:ive="http://namespaces.semaworx.org/inventoryControl/">
>>>>>>>>
>>>>>>>>        <ive:ActivityStreamGroup
>>>>>>>> rdf:about="
>>>> http://resources.semaworx.eu/inventory/ActivityStreams/current/">
>>>>>>>>        (… some ?p ?o here …)
>>>>>>>>
>>>>>>>>        </ive:ActivityStreamGroup>
>>>>>>>>
>>>>>>>>     Â </rdf:RDF>
>>>>>>> I’m quite aware I may have missed a change of defaults here.
>>>>>>>
>>>>>>> All I need to know is learning how to do this from now on.
>>>>>>>
>>>>>>> — Bardo
>>>>>>>
>>>>>>> On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
>>>>>>>> On 22/04/2021 09:55, Rob Vesse wrote:
>>>>>>>>> What is the query?
>>>>>>>>>
>>>>>>>>> RDF/XML is a graph format and so only makes sense for
>>>>>>>>> CONSTRUCT/DESCRIBE queries
>>>>>>>>>
>>>>>>>>> ASK/SELECT queries are going to produce tabular results which uses
>>>>>>>>> the SPARQL XML Results format by default.
>>>>>>>>>
>>>>>>>>> Historically there was an ability to transcribe the tabular format
>>>>>>>>> into a graph but this was a very niche use case (primarily only
>> used
>>>>>>>>> in the SPARQL test suite itself).  There were a bunch of changes in
>>>>>>>>> Jena 4.x to simplify Content-Type handling to only use canonical
>>>>>>>>> formats by default.
>>>>>>>>>
>>>>>>>>> Rob
>>>>>>>> Using
>>>>>>>>
>>>>>>>> curl --header 'Accept: application/rdf+xml'
>>>>>>>>
>>>>>>>> works for me.
>>>>>>>>
>>>>>>>>
>>>>>>>> Use of "pretty", to become the more basic form of RDF/XML changed
>>>>>>>> several versions ago at 3.15.0. But that is not
>>>>>>>> application/sparql-results+xml.
>>>>>>>>
>>>>>>>> https://issues.apache.org/jira/browse/JENA-1826
>>>>>>>>
>>>>>>>> Please can we have an example with query, curl call and versions
>>>> numbers?
>>>>>>>>       Andy
>>>>>>>>
>>>>>>>>> On 22/04/2021, 08:10, "Bardo Nelgen"
>>>>>>>>> <ma...@bnnperformances.de>    wrote:
>>>>>>>>>
>>>>>>>>>         Hi all,
>>>>>>>>>         �
>>>>>>>>>         Maybe there is something about Jena 4 with outputting
>>>>>>>>> „pretty“
>>>>>>>>>         RDF/XML via Fuseki ?
>>>>>>>>>         �
>>>>>>>>>         Whenever asking Fuseki (i.e. via HTTP…
>>>>>>> – be it from the
>>>>>>>>> GUI or via
>>>>>>>>>         curl) for RDF/XML results, it now ALWAYS defaults to SRX
>>>>>>>>>         (application/SPARQL-results+xml).
>>>>>>>>>         �
>>>>>>>>>         The behaviour could be changed in older versions by sending
>> an
>>>>>>>>>         Accept-Header for application/rdf+xml. With version 4.0,
>>>>>>>>> this option
>>>>>>>>>         appears to be gone.
>>>>>>>>>
>>>>>>>>>         For now, I am through with the release notes,
>>>>>>> existing bug
>>>>>>>>> reports and
>>>>>>>>>         the list archive already but find nothing coming similar to
>>>>>>>>> what we
>>>>>>>>>         currently experience.�
>>>>>>>>>
>>>>>>>>>         What is the contemporary approach to achieve the desired
>>>>>>>>> result ?
>>>>>>>>>         �
>>>>>>>>>         Thanks in advance for any input.
>>>>>>>>>         �
>>>>>>>>>          Best,
>>>>>>>>>
>>>>>>>>>          Bardo
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>> On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
>>>>>>>> On 22/04/2021 09:55, Rob Vesse wrote:
>>>>>>>>> What is the query?
>>>>>>>>>
>>>>>>>>> RDF/XML is a graph format and so only makes sense for
>>>>>>>>> CONSTRUCT/DESCRIBE queries
>>>>>>>>>
>>>>>>>>> ASK/SELECT queries are going to produce tabular results which uses
>>>>>>>>> the SPARQL XML Results format by default.
>>>>>>>>>
>>>>>>>>> Historically there was an ability to transcribe the tabular format
>>>>>>>>> into a graph but this was a very niche use case (primarily only
>> used
>>>>>>>>> in the SPARQL test suite itself).  There were a bunch of changes in
>>>>>>>>> Jena 4.x to simplify Content-Type handling to only use canonical
>>>>>>>>> formats by default.
>>>>>>>>>
>>>>>>>>> Rob
>>>>>>>> Using
>>>>>>>>
>>>>>>>> curl --header 'Accept: application/rdf+xml'
>>>>>>>>
>>>>>>>> works for me.
>>>>>>>>
>>>>>>>>
>>>>>>>> Use of "pretty", to become the more basic form of RDF/XML changed
>>>>>>>> several versions ago at 3.15.0. But that is not
>>>>>>>> application/sparql-results+xml.
>>>>>>>>
>>>>>>>> https://issues.apache.org/jira/browse/JENA-1826
>>>>>>>>
>>>>>>>> Please can we have an example with query, curl call and versions
>>>> numbers?
>>>>>>>>       Andy
>>>>>>>>
>>>>>>>>> On 22/04/2021, 08:10, "Bardo Nelgen"
>>>>>>>>> <ma...@bnnperformances.de>    wrote:
>>>>>>>>>
>>>>>>>>>         Hi all,
>>>>>>>>>         �
>>>>>>>>>         Maybe there is something about Jena 4 with outputting
>>>>>>>>> „pretty“
>>>>>>>>>         RDF/XML via Fuseki ?
>>>>>>>>>         �
>>>>>>>>>         Whenever asking Fuseki (i.e. via HTTP…
>>>>>>> – be it from the
>>>>>>>>> GUI or via
>>>>>>>>>         curl) for RDF/XML results, it now ALWAYS defaults to SRX
>>>>>>>>>         (application/SPARQL-results+xml).
>>>>>>>>>         �
>>>>>>>>>         The behaviour could be changed in older versions by sending
>> an
>>>>>>>>>         Accept-Header for application/rdf+xml. With version 4.0,
>>>>>>>>> this option
>>>>>>>>>         appears to be gone.
>>>>>>>>>
>>>>>>>>>         For now, I am through with the release notes,
>>>>>>> existing bug
>>>>>>>>> reports and
>>>>>>>>>         the list archive already but find nothing coming similar to
>>>>>>>>> what we
>>>>>>>>>         currently experience.�
>>>>>>>>>
>>>>>>>>>         What is the contemporary approach to achieve the desired
>>>>>>>>> result ?
>>>>>>>>>         �
>>>>>>>>>         Thanks in advance for any input.
>>>>>>>>>         �
>>>>>>>>>          Best,
>>>>>>>>>
>>>>>>>>>          Bardo
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>

Re: Jena 4 and RDF/XML via Fuseki

Posted by Martynas Jusevičius <ma...@atomgraph.com>.
Not what I said :)

Changing <rdf:Description> to an element with class name would take one or
two XSLT templates.

On Fri, 23 Apr 2021 at 07.45, Bardo Nelgen <
mailing.list.inbox@bnnperformances.de> wrote:

> Re-Writing entire RIOT in XSLT ?
>
> Probably not the most versatile approach… ;-)
>
> On 23.04.21 07.40 Uhr, Martynas Jusevičius wrote:
> > Is your client reading the data as RDF or XML?
> >
> > You could apply an XSLT stylesheet to transform plain RDF/XML to pretty.
> >
> > On Fri, 23 Apr 2021 at 06.38, Bardo Nelgen <
> > mailing.list.inbox@bnnperformances.de> wrote:
> >
> >> Thanks for the insight – I do not doubt, that turningoff"pretty",
> >>
> >> rather than improving it, has been the "easier" choice an the time;
> >> though this does not change the fact, that I need my data formatted this
> >> way and would like to learn how to get it.
> >>
> >> On 22.04.21 18.47 Uhr, Martynas Jusevičius wrote:
> >>> Actually Andy explained in this thread why this change was introduced
> >>> back in 3.15.0:https://issues.apache.org/jira/browse/JENA-1826
> >>>
> >>> On Thu, Apr 22, 2021 at 6:44 PM Martynas Jusevičius
> >>> <ma...@atomgraph.com>   wrote:
> >>>> It's the same data, just formatted in a slightly different way. It
> >>>> seems that RDFXML_PLAIN is the default RDF/XML writer in Jena 4.0:
> >>>> https://jena.apache.org/documentation/io/rdf-output.html#rdfxml
> >>>>
> >>>>
> >>>> On Thu, Apr 22, 2021 at 5:27 PM Bardo Nelgen
> >>>> <ma...@bnnperformances.de>   wrote:
> >>>>> Sorry, of course you are right – both.
> >>>>>
> >>>>> When I looked at the output for the last time, I had a SELECT query
> >>>>> running – thus completely foreseeable getting
> >>>>> application/sparql-results+xml.
> >>>>>
> >>>>> What I was originally looking for is to format the result of a
> >> CONSTRUCT
> >>>>> query, which as of now comes out quite linear like:
> >>>>>
> >>>>>>       <rdf:Description
> >>>>>> rdf:about="
> >> http://resources.semaworx.eu/inventory/ActivityStreams/current/">
> >>>>>>           <rdf:type
> >>>>>> rdf:resource="
> >> http://namespaces.semaworx.org/inventoryControl/ActivityStreamGroup"/>
> >>>>>>           (… some ?p ?o here …)
> >>>>>>
> >>>>>>       </rdf:Description>
> >>>>> Though, what I have been looking for, is supposed to come out more
> >> like:
> >>>>>>       <rdf:RDF
> >>>>>> xmlns:ive="http://namespaces.semaworx.org/inventoryControl/">
> >>>>>>
> >>>>>>       <ive:ActivityStreamGroup
> >>>>>> rdf:about="
> >> http://resources.semaworx.eu/inventory/ActivityStreams/current/">
> >>>>>>       (… some ?p ?o here …)
> >>>>>>
> >>>>>>       </ive:ActivityStreamGroup>
> >>>>>>
> >>>>>>    Â </rdf:RDF>
> >>>>> I’m quite aware I may have missed a change of defaults here.
> >>>>>
> >>>>> All I need to know is learning how to do this from now on.
> >>>>>
> >>>>> — Bardo
> >>>>>
> >>>>> On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
> >>>>>> On 22/04/2021 09:55, Rob Vesse wrote:
> >>>>>>> What is the query?
> >>>>>>>
> >>>>>>> RDF/XML is a graph format and so only makes sense for
> >>>>>>> CONSTRUCT/DESCRIBE queries
> >>>>>>>
> >>>>>>> ASK/SELECT queries are going to produce tabular results which uses
> >>>>>>> the SPARQL XML Results format by default.
> >>>>>>>
> >>>>>>> Historically there was an ability to transcribe the tabular format
> >>>>>>> into a graph but this was a very niche use case (primarily only
> used
> >>>>>>> in the SPARQL test suite itself).  There were a bunch of changes in
> >>>>>>> Jena 4.x to simplify Content-Type handling to only use canonical
> >>>>>>> formats by default.
> >>>>>>>
> >>>>>>> Rob
> >>>>>> Using
> >>>>>>
> >>>>>> curl --header 'Accept: application/rdf+xml'
> >>>>>>
> >>>>>> works for me.
> >>>>>>
> >>>>>>
> >>>>>> Use of "pretty", to become the more basic form of RDF/XML changed
> >>>>>> several versions ago at 3.15.0. But that is not
> >>>>>> application/sparql-results+xml.
> >>>>>>
> >>>>>> https://issues.apache.org/jira/browse/JENA-1826
> >>>>>>
> >>>>>> Please can we have an example with query, curl call and versions
> >> numbers?
> >>>>>>      Andy
> >>>>>>
> >>>>>>> On 22/04/2021, 08:10, "Bardo Nelgen"
> >>>>>>> <ma...@bnnperformances.de>   wrote:
> >>>>>>>
> >>>>>>>        Hi all,
> >>>>>>>        �
> >>>>>>>        Maybe there is something about Jena 4 with outputting
> >>>>>>> „pretty“
> >>>>>>>        RDF/XML via Fuseki ?
> >>>>>>>        �
> >>>>>>>        Whenever asking Fuseki (i.e. via HTTP…
> >>>>> – be it from the
> >>>>>>> GUI or via
> >>>>>>>        curl) for RDF/XML results, it now ALWAYS defaults to SRX
> >>>>>>>        (application/SPARQL-results+xml).
> >>>>>>>        �
> >>>>>>>        The behaviour could be changed in older versions by sending
> an
> >>>>>>>        Accept-Header for application/rdf+xml. With version 4.0,
> >>>>>>> this option
> >>>>>>>        appears to be gone.
> >>>>>>>
> >>>>>>>        For now, I am through with the release notes,
> >>>>> existing bug
> >>>>>>> reports and
> >>>>>>>        the list archive already but find nothing coming similar to
> >>>>>>> what we
> >>>>>>>        currently experience.�
> >>>>>>>
> >>>>>>>        What is the contemporary approach to achieve the desired
> >>>>>>> result ?
> >>>>>>>        �
> >>>>>>>        Thanks in advance for any input.
> >>>>>>>        �
> >>>>>>>         Best,
> >>>>>>>
> >>>>>>>         Bardo
> >>>>>>>
> >>>>>>>
> >>>>>>>
> >>>>>>>
> >>>>> On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
> >>>>>> On 22/04/2021 09:55, Rob Vesse wrote:
> >>>>>>> What is the query?
> >>>>>>>
> >>>>>>> RDF/XML is a graph format and so only makes sense for
> >>>>>>> CONSTRUCT/DESCRIBE queries
> >>>>>>>
> >>>>>>> ASK/SELECT queries are going to produce tabular results which uses
> >>>>>>> the SPARQL XML Results format by default.
> >>>>>>>
> >>>>>>> Historically there was an ability to transcribe the tabular format
> >>>>>>> into a graph but this was a very niche use case (primarily only
> used
> >>>>>>> in the SPARQL test suite itself).  There were a bunch of changes in
> >>>>>>> Jena 4.x to simplify Content-Type handling to only use canonical
> >>>>>>> formats by default.
> >>>>>>>
> >>>>>>> Rob
> >>>>>> Using
> >>>>>>
> >>>>>> curl --header 'Accept: application/rdf+xml'
> >>>>>>
> >>>>>> works for me.
> >>>>>>
> >>>>>>
> >>>>>> Use of "pretty", to become the more basic form of RDF/XML changed
> >>>>>> several versions ago at 3.15.0. But that is not
> >>>>>> application/sparql-results+xml.
> >>>>>>
> >>>>>> https://issues.apache.org/jira/browse/JENA-1826
> >>>>>>
> >>>>>> Please can we have an example with query, curl call and versions
> >> numbers?
> >>>>>>      Andy
> >>>>>>
> >>>>>>> On 22/04/2021, 08:10, "Bardo Nelgen"
> >>>>>>> <ma...@bnnperformances.de>   wrote:
> >>>>>>>
> >>>>>>>        Hi all,
> >>>>>>>        �
> >>>>>>>        Maybe there is something about Jena 4 with outputting
> >>>>>>> „pretty“
> >>>>>>>        RDF/XML via Fuseki ?
> >>>>>>>        �
> >>>>>>>        Whenever asking Fuseki (i.e. via HTTP…
> >>>>> – be it from the
> >>>>>>> GUI or via
> >>>>>>>        curl) for RDF/XML results, it now ALWAYS defaults to SRX
> >>>>>>>        (application/SPARQL-results+xml).
> >>>>>>>        �
> >>>>>>>        The behaviour could be changed in older versions by sending
> an
> >>>>>>>        Accept-Header for application/rdf+xml. With version 4.0,
> >>>>>>> this option
> >>>>>>>        appears to be gone.
> >>>>>>>
> >>>>>>>        For now, I am through with the release notes,
> >>>>> existing bug
> >>>>>>> reports and
> >>>>>>>        the list archive already but find nothing coming similar to
> >>>>>>> what we
> >>>>>>>        currently experience.�
> >>>>>>>
> >>>>>>>        What is the contemporary approach to achieve the desired
> >>>>>>> result ?
> >>>>>>>        �
> >>>>>>>        Thanks in advance for any input.
> >>>>>>>        �
> >>>>>>>         Best,
> >>>>>>>
> >>>>>>>         Bardo
> >>>>>>>
> >>>>>>>
> >>>>>>>
> >>>>>>>

Re: Jena 4 and RDF/XML via Fuseki

Posted by Bardo Nelgen <ma...@bnnperformances.de>.
Re-Writing entire RIOT in XSLT ?

Probably not the most versatile approach… ;-)

On 23.04.21 07.40 Uhr, Martynas Jusevičius wrote:
> Is your client reading the data as RDF or XML?
>
> You could apply an XSLT stylesheet to transform plain RDF/XML to pretty.
>
> On Fri, 23 Apr 2021 at 06.38, Bardo Nelgen <
> mailing.list.inbox@bnnperformances.de> wrote:
>
>> Thanks for the insight – I do not doubt, that turningoff"pretty",
>>
>> rather than improving it, has been the "easier" choice an the time;
>> though this does not change the fact, that I need my data formatted this
>> way and would like to learn how to get it.
>>
>> On 22.04.21 18.47 Uhr, Martynas Jusevičius wrote:
>>> Actually Andy explained in this thread why this change was introduced
>>> back in 3.15.0:https://issues.apache.org/jira/browse/JENA-1826
>>>
>>> On Thu, Apr 22, 2021 at 6:44 PM Martynas Jusevičius
>>> <ma...@atomgraph.com>   wrote:
>>>> It's the same data, just formatted in a slightly different way. It
>>>> seems that RDFXML_PLAIN is the default RDF/XML writer in Jena 4.0:
>>>> https://jena.apache.org/documentation/io/rdf-output.html#rdfxml
>>>>
>>>>
>>>> On Thu, Apr 22, 2021 at 5:27 PM Bardo Nelgen
>>>> <ma...@bnnperformances.de>   wrote:
>>>>> Sorry, of course you are right – both.
>>>>>
>>>>> When I looked at the output for the last time, I had a SELECT query
>>>>> running – thus completely foreseeable getting
>>>>> application/sparql-results+xml.
>>>>>
>>>>> What I was originally looking for is to format the result of a
>> CONSTRUCT
>>>>> query, which as of now comes out quite linear like:
>>>>>
>>>>>>       <rdf:Description
>>>>>> rdf:about="
>> http://resources.semaworx.eu/inventory/ActivityStreams/current/">
>>>>>>           <rdf:type
>>>>>> rdf:resource="
>> http://namespaces.semaworx.org/inventoryControl/ActivityStreamGroup"/>
>>>>>>           (… some ?p ?o here …)
>>>>>>
>>>>>>       </rdf:Description>
>>>>> Though, what I have been looking for, is supposed to come out more
>> like:
>>>>>>       <rdf:RDF
>>>>>> xmlns:ive="http://namespaces.semaworx.org/inventoryControl/">
>>>>>>
>>>>>>       <ive:ActivityStreamGroup
>>>>>> rdf:about="
>> http://resources.semaworx.eu/inventory/ActivityStreams/current/">
>>>>>>       (… some ?p ?o here …)
>>>>>>
>>>>>>       </ive:ActivityStreamGroup>
>>>>>>
>>>>>>    Â </rdf:RDF>
>>>>> I’m quite aware I may have missed a change of defaults here.
>>>>>
>>>>> All I need to know is learning how to do this from now on.
>>>>>
>>>>> — Bardo
>>>>>
>>>>> On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
>>>>>> On 22/04/2021 09:55, Rob Vesse wrote:
>>>>>>> What is the query?
>>>>>>>
>>>>>>> RDF/XML is a graph format and so only makes sense for
>>>>>>> CONSTRUCT/DESCRIBE queries
>>>>>>>
>>>>>>> ASK/SELECT queries are going to produce tabular results which uses
>>>>>>> the SPARQL XML Results format by default.
>>>>>>>
>>>>>>> Historically there was an ability to transcribe the tabular format
>>>>>>> into a graph but this was a very niche use case (primarily only used
>>>>>>> in the SPARQL test suite itself).  There were a bunch of changes in
>>>>>>> Jena 4.x to simplify Content-Type handling to only use canonical
>>>>>>> formats by default.
>>>>>>>
>>>>>>> Rob
>>>>>> Using
>>>>>>
>>>>>> curl --header 'Accept: application/rdf+xml'
>>>>>>
>>>>>> works for me.
>>>>>>
>>>>>>
>>>>>> Use of "pretty", to become the more basic form of RDF/XML changed
>>>>>> several versions ago at 3.15.0. But that is not
>>>>>> application/sparql-results+xml.
>>>>>>
>>>>>> https://issues.apache.org/jira/browse/JENA-1826
>>>>>>
>>>>>> Please can we have an example with query, curl call and versions
>> numbers?
>>>>>>      Andy
>>>>>>
>>>>>>> On 22/04/2021, 08:10, "Bardo Nelgen"
>>>>>>> <ma...@bnnperformances.de>   wrote:
>>>>>>>
>>>>>>>        Hi all,
>>>>>>>        �
>>>>>>>        Maybe there is something about Jena 4 with outputting
>>>>>>> „pretty“
>>>>>>>        RDF/XML via Fuseki ?
>>>>>>>        �
>>>>>>>        Whenever asking Fuseki (i.e. via HTTP…
>>>>> – be it from the
>>>>>>> GUI or via
>>>>>>>        curl) for RDF/XML results, it now ALWAYS defaults to SRX
>>>>>>>        (application/SPARQL-results+xml).
>>>>>>>        �
>>>>>>>        The behaviour could be changed in older versions by sending an
>>>>>>>        Accept-Header for application/rdf+xml. With version 4.0,
>>>>>>> this option
>>>>>>>        appears to be gone.
>>>>>>>
>>>>>>>        For now, I am through with the release notes,
>>>>> existing bug
>>>>>>> reports and
>>>>>>>        the list archive already but find nothing coming similar to
>>>>>>> what we
>>>>>>>        currently experience.�
>>>>>>>
>>>>>>>        What is the contemporary approach to achieve the desired
>>>>>>> result ?
>>>>>>>        �
>>>>>>>        Thanks in advance for any input.
>>>>>>>        �
>>>>>>>         Best,
>>>>>>>
>>>>>>>         Bardo
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>> On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
>>>>>> On 22/04/2021 09:55, Rob Vesse wrote:
>>>>>>> What is the query?
>>>>>>>
>>>>>>> RDF/XML is a graph format and so only makes sense for
>>>>>>> CONSTRUCT/DESCRIBE queries
>>>>>>>
>>>>>>> ASK/SELECT queries are going to produce tabular results which uses
>>>>>>> the SPARQL XML Results format by default.
>>>>>>>
>>>>>>> Historically there was an ability to transcribe the tabular format
>>>>>>> into a graph but this was a very niche use case (primarily only used
>>>>>>> in the SPARQL test suite itself).  There were a bunch of changes in
>>>>>>> Jena 4.x to simplify Content-Type handling to only use canonical
>>>>>>> formats by default.
>>>>>>>
>>>>>>> Rob
>>>>>> Using
>>>>>>
>>>>>> curl --header 'Accept: application/rdf+xml'
>>>>>>
>>>>>> works for me.
>>>>>>
>>>>>>
>>>>>> Use of "pretty", to become the more basic form of RDF/XML changed
>>>>>> several versions ago at 3.15.0. But that is not
>>>>>> application/sparql-results+xml.
>>>>>>
>>>>>> https://issues.apache.org/jira/browse/JENA-1826
>>>>>>
>>>>>> Please can we have an example with query, curl call and versions
>> numbers?
>>>>>>      Andy
>>>>>>
>>>>>>> On 22/04/2021, 08:10, "Bardo Nelgen"
>>>>>>> <ma...@bnnperformances.de>   wrote:
>>>>>>>
>>>>>>>        Hi all,
>>>>>>>        �
>>>>>>>        Maybe there is something about Jena 4 with outputting
>>>>>>> „pretty“
>>>>>>>        RDF/XML via Fuseki ?
>>>>>>>        �
>>>>>>>        Whenever asking Fuseki (i.e. via HTTP…
>>>>> – be it from the
>>>>>>> GUI or via
>>>>>>>        curl) for RDF/XML results, it now ALWAYS defaults to SRX
>>>>>>>        (application/SPARQL-results+xml).
>>>>>>>        �
>>>>>>>        The behaviour could be changed in older versions by sending an
>>>>>>>        Accept-Header for application/rdf+xml. With version 4.0,
>>>>>>> this option
>>>>>>>        appears to be gone.
>>>>>>>
>>>>>>>        For now, I am through with the release notes,
>>>>> existing bug
>>>>>>> reports and
>>>>>>>        the list archive already but find nothing coming similar to
>>>>>>> what we
>>>>>>>        currently experience.�
>>>>>>>
>>>>>>>        What is the contemporary approach to achieve the desired
>>>>>>> result ?
>>>>>>>        �
>>>>>>>        Thanks in advance for any input.
>>>>>>>        �
>>>>>>>         Best,
>>>>>>>
>>>>>>>         Bardo
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>

Re: Jena 4 and RDF/XML via Fuseki

Posted by Martynas Jusevičius <ma...@atomgraph.com>.
Is your client reading the data as RDF or XML?

You could apply an XSLT stylesheet to transform plain RDF/XML to pretty.

On Fri, 23 Apr 2021 at 06.38, Bardo Nelgen <
mailing.list.inbox@bnnperformances.de> wrote:

> Thanks for the insight – I do not doubt, that turningoff"pretty",
>
> rather than improving it, has been the "easier" choice an the time;
> though this does not change the fact, that I need my data formatted this
> way and would like to learn how to get it.
>
> On 22.04.21 18.47 Uhr, Martynas Jusevičius wrote:
> > Actually Andy explained in this thread why this change was introduced
> > back in 3.15.0:https://issues.apache.org/jira/browse/JENA-1826
> >
> > On Thu, Apr 22, 2021 at 6:44 PM Martynas Jusevičius
> > <ma...@atomgraph.com>  wrote:
> >> It's the same data, just formatted in a slightly different way. It
> >> seems that RDFXML_PLAIN is the default RDF/XML writer in Jena 4.0:
> >> https://jena.apache.org/documentation/io/rdf-output.html#rdfxml
> >>
> >>
> >> On Thu, Apr 22, 2021 at 5:27 PM Bardo Nelgen
> >> <ma...@bnnperformances.de>  wrote:
> >>> Sorry, of course you are right – both.
> >>>
> >>> When I looked at the output for the last time, I had a SELECT query
> >>> running – thus completely foreseeable getting
> >>> application/sparql-results+xml.
> >>>
> >>> What I was originally looking for is to format the result of a
> CONSTRUCT
> >>> query, which as of now comes out quite linear like:
> >>>
> >>>>      <rdf:Description
> >>>> rdf:about="
> http://resources.semaworx.eu/inventory/ActivityStreams/current/">
> >>>>          <rdf:type
> >>>> rdf:resource="
> http://namespaces.semaworx.org/inventoryControl/ActivityStreamGroup"/>
> >>>>
> >>>>          (… some ?p ?o here …)
> >>>>
> >>>>      </rdf:Description>
> >>> Though, what I have been looking for, is supposed to come out more
> like:
> >>>>      <rdf:RDF
> >>>> xmlns:ive="http://namespaces.semaworx.org/inventoryControl/">
> >>>>
> >>>>      <ive:ActivityStreamGroup
> >>>> rdf:about="
> http://resources.semaworx.eu/inventory/ActivityStreams/current/">
> >>>>
> >>>>      (… some ?p ?o here …)
> >>>>
> >>>>      </ive:ActivityStreamGroup>
> >>>>
> >>>>   Â </rdf:RDF>
> >>> I’m quite aware I may have missed a change of defaults here.
> >>>
> >>> All I need to know is learning how to do this from now on.
> >>>
> >>> — Bardo
> >>>
> >>> On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
> >>>>
> >>>> On 22/04/2021 09:55, Rob Vesse wrote:
> >>>>> What is the query?
> >>>>>
> >>>>> RDF/XML is a graph format and so only makes sense for
> >>>>> CONSTRUCT/DESCRIBE queries
> >>>>>
> >>>>> ASK/SELECT queries are going to produce tabular results which uses
> >>>>> the SPARQL XML Results format by default.
> >>>>>
> >>>>> Historically there was an ability to transcribe the tabular format
> >>>>> into a graph but this was a very niche use case (primarily only used
> >>>>> in the SPARQL test suite itself).  There were a bunch of changes in
> >>>>> Jena 4.x to simplify Content-Type handling to only use canonical
> >>>>> formats by default.
> >>>>>
> >>>>> Rob
> >>>> Using
> >>>>
> >>>> curl --header 'Accept: application/rdf+xml'
> >>>>
> >>>> works for me.
> >>>>
> >>>>
> >>>> Use of "pretty", to become the more basic form of RDF/XML changed
> >>>> several versions ago at 3.15.0. But that is not
> >>>> application/sparql-results+xml.
> >>>>
> >>>> https://issues.apache.org/jira/browse/JENA-1826
> >>>>
> >>>> Please can we have an example with query, curl call and versions
> numbers?
> >>>>
> >>>>     Andy
> >>>>
> >>>>> On 22/04/2021, 08:10, "Bardo Nelgen"
> >>>>> <ma...@bnnperformances.de>  wrote:
> >>>>>
> >>>>>       Hi all,
> >>>>>       �
> >>>>>       Maybe there is something about Jena 4 with outputting
> >>>>> „pretty“
> >>>>>       RDF/XML via Fuseki ?
> >>>>>       �
> >>>>>       Whenever asking Fuseki (i.e. via HTTP…
> >>> – be it from the
> >>>>> GUI or via
> >>>>>       curl) for RDF/XML results, it now ALWAYS defaults to SRX
> >>>>>       (application/SPARQL-results+xml).
> >>>>>       �
> >>>>>       The behaviour could be changed in older versions by sending an
> >>>>>       Accept-Header for application/rdf+xml. With version 4.0,
> >>>>> this option
> >>>>>       appears to be gone.
> >>>>>
> >>>>>       For now, I am through with the release notes,
> >>> existing bug
> >>>>> reports and
> >>>>>       the list archive already but find nothing coming similar to
> >>>>> what we
> >>>>>       currently experience.�
> >>>>>
> >>>>>       What is the contemporary approach to achieve the desired
> >>>>> result ?
> >>>>>       �
> >>>>>       Thanks in advance for any input.
> >>>>>       �
> >>>>>        Best,
> >>>>>
> >>>>>        Bardo
> >>>>>
> >>>>>
> >>>>>
> >>>>>
> >>> On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
> >>>>
> >>>> On 22/04/2021 09:55, Rob Vesse wrote:
> >>>>> What is the query?
> >>>>>
> >>>>> RDF/XML is a graph format and so only makes sense for
> >>>>> CONSTRUCT/DESCRIBE queries
> >>>>>
> >>>>> ASK/SELECT queries are going to produce tabular results which uses
> >>>>> the SPARQL XML Results format by default.
> >>>>>
> >>>>> Historically there was an ability to transcribe the tabular format
> >>>>> into a graph but this was a very niche use case (primarily only used
> >>>>> in the SPARQL test suite itself).  There were a bunch of changes in
> >>>>> Jena 4.x to simplify Content-Type handling to only use canonical
> >>>>> formats by default.
> >>>>>
> >>>>> Rob
> >>>> Using
> >>>>
> >>>> curl --header 'Accept: application/rdf+xml'
> >>>>
> >>>> works for me.
> >>>>
> >>>>
> >>>> Use of "pretty", to become the more basic form of RDF/XML changed
> >>>> several versions ago at 3.15.0. But that is not
> >>>> application/sparql-results+xml.
> >>>>
> >>>> https://issues.apache.org/jira/browse/JENA-1826
> >>>>
> >>>> Please can we have an example with query, curl call and versions
> numbers?
> >>>>
> >>>>     Andy
> >>>>
> >>>>> On 22/04/2021, 08:10, "Bardo Nelgen"
> >>>>> <ma...@bnnperformances.de>  wrote:
> >>>>>
> >>>>>       Hi all,
> >>>>>       �
> >>>>>       Maybe there is something about Jena 4 with outputting
> >>>>> „pretty“
> >>>>>       RDF/XML via Fuseki ?
> >>>>>       �
> >>>>>       Whenever asking Fuseki (i.e. via HTTP…
> >>> – be it from the
> >>>>> GUI or via
> >>>>>       curl) for RDF/XML results, it now ALWAYS defaults to SRX
> >>>>>       (application/SPARQL-results+xml).
> >>>>>       �
> >>>>>       The behaviour could be changed in older versions by sending an
> >>>>>       Accept-Header for application/rdf+xml. With version 4.0,
> >>>>> this option
> >>>>>       appears to be gone.
> >>>>>
> >>>>>       For now, I am through with the release notes,
> >>> existing bug
> >>>>> reports and
> >>>>>       the list archive already but find nothing coming similar to
> >>>>> what we
> >>>>>       currently experience.�
> >>>>>
> >>>>>       What is the contemporary approach to achieve the desired
> >>>>> result ?
> >>>>>       �
> >>>>>       Thanks in advance for any input.
> >>>>>       �
> >>>>>        Best,
> >>>>>
> >>>>>        Bardo
> >>>>>
> >>>>>
> >>>>>
> >>>>>

Re: Jena 4 and RDF/XML via Fuseki

Posted by Bardo Nelgen <ma...@bnnperformances.de>.
Thanks for the insight – I do not doubt, that turningoff"pretty", 

rather than improving it, has been the "easier" choice an the time; 
though this does not change the fact, that I need my data formatted this 
way and would like to learn how to get it.

On 22.04.21 18.47 Uhr, Martynas Jusevičius wrote:
> Actually Andy explained in this thread why this change was introduced
> back in 3.15.0:https://issues.apache.org/jira/browse/JENA-1826
>
> On Thu, Apr 22, 2021 at 6:44 PM Martynas Jusevičius
> <ma...@atomgraph.com>  wrote:
>> It's the same data, just formatted in a slightly different way. It
>> seems that RDFXML_PLAIN is the default RDF/XML writer in Jena 4.0:
>> https://jena.apache.org/documentation/io/rdf-output.html#rdfxml
>>
>>
>> On Thu, Apr 22, 2021 at 5:27 PM Bardo Nelgen
>> <ma...@bnnperformances.de>  wrote:
>>> Sorry, of course you are right – both.
>>>
>>> When I looked at the output for the last time, I had a SELECT query
>>> running – thus completely foreseeable getting
>>> application/sparql-results+xml.
>>>
>>> What I was originally looking for is to format the result of a CONSTRUCT
>>> query, which as of now comes out quite linear like:
>>>
>>>>      <rdf:Description
>>>> rdf:about="http://resources.semaworx.eu/inventory/ActivityStreams/current/">
>>>>          <rdf:type
>>>> rdf:resource="http://namespaces.semaworx.org/inventoryControl/ActivityStreamGroup"/>
>>>>
>>>>          (… some ?p ?o here …)
>>>>
>>>>      </rdf:Description>
>>> Though, what I have been looking for, is supposed to come out more like:
>>>>      <rdf:RDF
>>>> xmlns:ive="http://namespaces.semaworx.org/inventoryControl/">
>>>>
>>>>      <ive:ActivityStreamGroup
>>>> rdf:about="http://resources.semaworx.eu/inventory/ActivityStreams/current/">
>>>>
>>>>      (… some ?p ?o here …)
>>>>
>>>>      </ive:ActivityStreamGroup>
>>>>
>>>>   Â </rdf:RDF>
>>> I’m quite aware I may have missed a change of defaults here.
>>>
>>> All I need to know is learning how to do this from now on.
>>>
>>> — Bardo
>>>
>>> On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
>>>>
>>>> On 22/04/2021 09:55, Rob Vesse wrote:
>>>>> What is the query?
>>>>>
>>>>> RDF/XML is a graph format and so only makes sense for
>>>>> CONSTRUCT/DESCRIBE queries
>>>>>
>>>>> ASK/SELECT queries are going to produce tabular results which uses
>>>>> the SPARQL XML Results format by default.
>>>>>
>>>>> Historically there was an ability to transcribe the tabular format
>>>>> into a graph but this was a very niche use case (primarily only used
>>>>> in the SPARQL test suite itself).  There were a bunch of changes in
>>>>> Jena 4.x to simplify Content-Type handling to only use canonical
>>>>> formats by default.
>>>>>
>>>>> Rob
>>>> Using
>>>>
>>>> curl --header 'Accept: application/rdf+xml'
>>>>
>>>> works for me.
>>>>
>>>>
>>>> Use of "pretty", to become the more basic form of RDF/XML changed
>>>> several versions ago at 3.15.0. But that is not
>>>> application/sparql-results+xml.
>>>>
>>>> https://issues.apache.org/jira/browse/JENA-1826
>>>>
>>>> Please can we have an example with query, curl call and versions numbers?
>>>>
>>>>     Andy
>>>>
>>>>> On 22/04/2021, 08:10, "Bardo Nelgen"
>>>>> <ma...@bnnperformances.de>  wrote:
>>>>>
>>>>>       Hi all,
>>>>>       �
>>>>>       Maybe there is something about Jena 4 with outputting
>>>>> „pretty“
>>>>>       RDF/XML via Fuseki ?
>>>>>       �
>>>>>       Whenever asking Fuseki (i.e. via HTTP…
>>> – be it from the
>>>>> GUI or via
>>>>>       curl) for RDF/XML results, it now ALWAYS defaults to SRX
>>>>>       (application/SPARQL-results+xml).
>>>>>       �
>>>>>       The behaviour could be changed in older versions by sending an
>>>>>       Accept-Header for application/rdf+xml. With version 4.0,
>>>>> this option
>>>>>       appears to be gone.
>>>>>
>>>>>       For now, I am through with the release notes,
>>> existing bug
>>>>> reports and
>>>>>       the list archive already but find nothing coming similar to
>>>>> what we
>>>>>       currently experience.�
>>>>>
>>>>>       What is the contemporary approach to achieve the desired
>>>>> result ?
>>>>>       �
>>>>>       Thanks in advance for any input.
>>>>>       �
>>>>>        Best,
>>>>>
>>>>>        Bardo
>>>>>
>>>>>
>>>>>
>>>>>
>>> On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
>>>>
>>>> On 22/04/2021 09:55, Rob Vesse wrote:
>>>>> What is the query?
>>>>>
>>>>> RDF/XML is a graph format and so only makes sense for
>>>>> CONSTRUCT/DESCRIBE queries
>>>>>
>>>>> ASK/SELECT queries are going to produce tabular results which uses
>>>>> the SPARQL XML Results format by default.
>>>>>
>>>>> Historically there was an ability to transcribe the tabular format
>>>>> into a graph but this was a very niche use case (primarily only used
>>>>> in the SPARQL test suite itself).  There were a bunch of changes in
>>>>> Jena 4.x to simplify Content-Type handling to only use canonical
>>>>> formats by default.
>>>>>
>>>>> Rob
>>>> Using
>>>>
>>>> curl --header 'Accept: application/rdf+xml'
>>>>
>>>> works for me.
>>>>
>>>>
>>>> Use of "pretty", to become the more basic form of RDF/XML changed
>>>> several versions ago at 3.15.0. But that is not
>>>> application/sparql-results+xml.
>>>>
>>>> https://issues.apache.org/jira/browse/JENA-1826
>>>>
>>>> Please can we have an example with query, curl call and versions numbers?
>>>>
>>>>     Andy
>>>>
>>>>> On 22/04/2021, 08:10, "Bardo Nelgen"
>>>>> <ma...@bnnperformances.de>  wrote:
>>>>>
>>>>>       Hi all,
>>>>>       �
>>>>>       Maybe there is something about Jena 4 with outputting
>>>>> „pretty“
>>>>>       RDF/XML via Fuseki ?
>>>>>       �
>>>>>       Whenever asking Fuseki (i.e. via HTTP…
>>> – be it from the
>>>>> GUI or via
>>>>>       curl) for RDF/XML results, it now ALWAYS defaults to SRX
>>>>>       (application/SPARQL-results+xml).
>>>>>       �
>>>>>       The behaviour could be changed in older versions by sending an
>>>>>       Accept-Header for application/rdf+xml. With version 4.0,
>>>>> this option
>>>>>       appears to be gone.
>>>>>
>>>>>       For now, I am through with the release notes,
>>> existing bug
>>>>> reports and
>>>>>       the list archive already but find nothing coming similar to
>>>>> what we
>>>>>       currently experience.�
>>>>>
>>>>>       What is the contemporary approach to achieve the desired
>>>>> result ?
>>>>>       �
>>>>>       Thanks in advance for any input.
>>>>>       �
>>>>>        Best,
>>>>>
>>>>>        Bardo
>>>>>
>>>>>
>>>>>
>>>>>

Re: Jena 4 and RDF/XML via Fuseki

Posted by Martynas Jusevičius <ma...@atomgraph.com>.
Actually Andy explained in this thread why this change was introduced
back in 3.15.0: https://issues.apache.org/jira/browse/JENA-1826

On Thu, Apr 22, 2021 at 6:44 PM Martynas Jusevičius
<ma...@atomgraph.com> wrote:
>
> It's the same data, just formatted in a slightly different way. It
> seems that RDFXML_PLAIN is the default RDF/XML writer in Jena 4.0:
> https://jena.apache.org/documentation/io/rdf-output.html#rdfxml
>
>
> On Thu, Apr 22, 2021 at 5:27 PM Bardo Nelgen
> <ma...@bnnperformances.de> wrote:
> >
> > Sorry, of course you are right – both.
> >
> > When I looked at the output for the last time, I had a SELECT query
> > running – thus completely foreseeable getting
> > application/sparql-results+xml.
> >
> > What I was originally looking for is to format the result of a CONSTRUCT
> > query, which as of now comes out quite linear like:
> >
> > >     <rdf:Description
> > > rdf:about="http://resources.semaworx.eu/inventory/ActivityStreams/current/">
> > >         <rdf:type
> > > rdf:resource="http://namespaces.semaworx.org/inventoryControl/ActivityStreamGroup"/>
> > >
> > >         (… some ?p ?o here …)
> > >
> > >     </rdf:Description>
> >
> > Though, what I have been looking for, is supposed to come out more like:
> > >     <rdf:RDF
> > > xmlns:ive="http://namespaces.semaworx.org/inventoryControl/">
> > >
> > >     <ive:ActivityStreamGroup
> > > rdf:about="http://resources.semaworx.eu/inventory/ActivityStreams/current/">
> > >
> > >     (… some ?p ?o here …)
> > >
> > >     </ive:ActivityStreamGroup>
> > >
> > >  Â </rdf:RDF>
> >
> > I’m quite aware I may have missed a change of defaults here.
> >
> > All I need to know is learning how to do this from now on.
> >
> > — Bardo
> >
> > On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
> > >
> > >
> > > On 22/04/2021 09:55, Rob Vesse wrote:
> > >> What is the query?
> > >>
> > >> RDF/XML is a graph format and so only makes sense for
> > >> CONSTRUCT/DESCRIBE queries
> > >>
> > >> ASK/SELECT queries are going to produce tabular results which uses
> > >> the SPARQL XML Results format by default.
> > >>
> > >> Historically there was an ability to transcribe the tabular format
> > >> into a graph but this was a very niche use case (primarily only used
> > >> in the SPARQL test suite itself).  There were a bunch of changes in
> > >> Jena 4.x to simplify Content-Type handling to only use canonical
> > >> formats by default.
> > >>
> > >> Rob
> > >
> > > Using
> > >
> > > curl --header 'Accept: application/rdf+xml'
> > >
> > > works for me.
> > >
> > >
> > > Use of "pretty", to become the more basic form of RDF/XML changed
> > > several versions ago at 3.15.0. But that is not
> > > application/sparql-results+xml.
> > >
> > > https://issues.apache.org/jira/browse/JENA-1826
> > >
> > > Please can we have an example with query, curl call and versions numbers?
> > >
> > >    Andy
> > >
> > >> On 22/04/2021, 08:10, "Bardo Nelgen"
> > >> <ma...@bnnperformances.de> wrote:
> > >>
> > >>      Hi all,
> > >>      �
> > >>      Maybe there is something about Jena 4 with outputting
> > >> „pretty“
> > >>      RDF/XML via Fuseki ?
> > >>      �
> > >>      Whenever asking Fuseki (i.e. via HTTP…
> > – be it from the
> > >> GUI or via
> > >>      curl) for RDF/XML results, it now ALWAYS defaults to SRX
> > >>      (application/SPARQL-results+xml).
> > >>      �
> > >>      The behaviour could be changed in older versions by sending an
> > >>      Accept-Header for application/rdf+xml. With version 4.0,
> > >> this option
> > >>      appears to be gone.
> > >>
> > >>      For now, I am through with the release notes,
> > existing bug
> > >> reports and
> > >>      the list archive already but find nothing coming similar to
> > >> what we
> > >>      currently experience.�
> > >>
> > >>      What is the contemporary approach to achieve the desired
> > >> result ?
> > >>      �
> > >>      Thanks in advance for any input.
> > >>      �
> > >>       Best,
> > >>
> > >>       Bardo
> > >>
> > >>
> > >>
> > >>
> > On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
> > >
> > >
> > > On 22/04/2021 09:55, Rob Vesse wrote:
> > >> What is the query?
> > >>
> > >> RDF/XML is a graph format and so only makes sense for
> > >> CONSTRUCT/DESCRIBE queries
> > >>
> > >> ASK/SELECT queries are going to produce tabular results which uses
> > >> the SPARQL XML Results format by default.
> > >>
> > >> Historically there was an ability to transcribe the tabular format
> > >> into a graph but this was a very niche use case (primarily only used
> > >> in the SPARQL test suite itself).  There were a bunch of changes in
> > >> Jena 4.x to simplify Content-Type handling to only use canonical
> > >> formats by default.
> > >>
> > >> Rob
> > >
> > > Using
> > >
> > > curl --header 'Accept: application/rdf+xml'
> > >
> > > works for me.
> > >
> > >
> > > Use of "pretty", to become the more basic form of RDF/XML changed
> > > several versions ago at 3.15.0. But that is not
> > > application/sparql-results+xml.
> > >
> > > https://issues.apache.org/jira/browse/JENA-1826
> > >
> > > Please can we have an example with query, curl call and versions numbers?
> > >
> > >    Andy
> > >
> > >> On 22/04/2021, 08:10, "Bardo Nelgen"
> > >> <ma...@bnnperformances.de> wrote:
> > >>
> > >>      Hi all,
> > >>      �
> > >>      Maybe there is something about Jena 4 with outputting
> > >> „pretty“
> > >>      RDF/XML via Fuseki ?
> > >>      �
> > >>      Whenever asking Fuseki (i.e. via HTTP…
> > – be it from the
> > >> GUI or via
> > >>      curl) for RDF/XML results, it now ALWAYS defaults to SRX
> > >>      (application/SPARQL-results+xml).
> > >>      �
> > >>      The behaviour could be changed in older versions by sending an
> > >>      Accept-Header for application/rdf+xml. With version 4.0,
> > >> this option
> > >>      appears to be gone.
> > >>
> > >>      For now, I am through with the release notes,
> > existing bug
> > >> reports and
> > >>      the list archive already but find nothing coming similar to
> > >> what we
> > >>      currently experience.�
> > >>
> > >>      What is the contemporary approach to achieve the desired
> > >> result ?
> > >>      �
> > >>      Thanks in advance for any input.
> > >>      �
> > >>       Best,
> > >>
> > >>       Bardo
> > >>
> > >>
> > >>
> > >>

Re: Jena 4 and RDF/XML via Fuseki

Posted by Bardo Nelgen <ma...@bnnperformances.de>.
Just having re-read this: Is anybody aware of a way to switch-back the 
default writer of 4.0 ?


On 22.04.21 18.44 Uhr, Martynas Jusevičius wrote:
> It's the same data, just formatted in a slightly different way. It
> seems that RDFXML_PLAIN is the default RDF/XML writer in Jena 4.0:
> https://jena.apache.org/documentation/io/rdf-output.html#rdfxml
>
>
> On Thu, Apr 22, 2021 at 5:27 PM Bardo Nelgen
> <ma...@bnnperformances.de>  wrote:
>> Sorry, of course you are right – both.
>>
>> When I looked at the output for the last time, I had a SELECT query
>> running – thus completely foreseeable getting
>> application/sparql-results+xml.
>>
>> What I was originally looking for is to format the result of a CONSTRUCT
>> query, which as of now comes out quite linear like:
>>
>>>      <rdf:Description
>>> rdf:about="http://resources.semaworx.eu/inventory/ActivityStreams/current/">
>>>          <rdf:type
>>> rdf:resource="http://namespaces.semaworx.org/inventoryControl/ActivityStreamGroup"/>
>>>
>>>          (… some ?p ?o here …)
>>>
>>>      </rdf:Description>
>> Though, what I have been looking for, is supposed to come out more like:
>>>      <rdf:RDF
>>> xmlns:ive="http://namespaces.semaworx.org/inventoryControl/">
>>>
>>>      <ive:ActivityStreamGroup
>>> rdf:about="http://resources.semaworx.eu/inventory/ActivityStreams/current/">
>>>
>>>      (… some ?p ?o here …)
>>>
>>>      </ive:ActivityStreamGroup>
>>>
>>>   Â </rdf:RDF>
>> I’m quite aware I may have missed a change of defaults here.
>>
>> All I need to know is learning how to do this from now on.
>>
>> — Bardo
>>
>> On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
>>>
>>> On 22/04/2021 09:55, Rob Vesse wrote:
>>>> What is the query?
>>>>
>>>> RDF/XML is a graph format and so only makes sense for
>>>> CONSTRUCT/DESCRIBE queries
>>>>
>>>> ASK/SELECT queries are going to produce tabular results which uses
>>>> the SPARQL XML Results format by default.
>>>>
>>>> Historically there was an ability to transcribe the tabular format
>>>> into a graph but this was a very niche use case (primarily only used
>>>> in the SPARQL test suite itself).  There were a bunch of changes in
>>>> Jena 4.x to simplify Content-Type handling to only use canonical
>>>> formats by default.
>>>>
>>>> Rob
>>> Using
>>>
>>> curl --header 'Accept: application/rdf+xml'
>>>
>>> works for me.
>>>
>>>
>>> Use of "pretty", to become the more basic form of RDF/XML changed
>>> several versions ago at 3.15.0. But that is not
>>> application/sparql-results+xml.
>>>
>>> https://issues.apache.org/jira/browse/JENA-1826
>>>
>>> Please can we have an example with query, curl call and versions numbers?
>>>
>>>     Andy
>>>
>>>> On 22/04/2021, 08:10, "Bardo Nelgen"
>>>> <ma...@bnnperformances.de>  wrote:
>>>>
>>>>       Hi all,
>>>>       �
>>>>       Maybe there is something about Jena 4 with outputting
>>>> „pretty“
>>>>       RDF/XML via Fuseki ?
>>>>       �
>>>>       Whenever asking Fuseki (i.e. via HTTP…
>> – be it from the
>>>> GUI or via
>>>>       curl) for RDF/XML results, it now ALWAYS defaults to SRX
>>>>       (application/SPARQL-results+xml).
>>>>       �
>>>>       The behaviour could be changed in older versions by sending an
>>>>       Accept-Header for application/rdf+xml. With version 4.0,
>>>> this option
>>>>       appears to be gone.
>>>>
>>>>       For now, I am through with the release notes,
>> existing bug
>>>> reports and
>>>>       the list archive already but find nothing coming similar to
>>>> what we
>>>>       currently experience.�
>>>>
>>>>       What is the contemporary approach to achieve the desired
>>>> result ?
>>>>       �
>>>>       Thanks in advance for any input.
>>>>       �
>>>>        Best,
>>>>
>>>>        Bardo
>>>>
>>>>
>>>>
>>>>
>> On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
>>>
>>> On 22/04/2021 09:55, Rob Vesse wrote:
>>>> What is the query?
>>>>
>>>> RDF/XML is a graph format and so only makes sense for
>>>> CONSTRUCT/DESCRIBE queries
>>>>
>>>> ASK/SELECT queries are going to produce tabular results which uses
>>>> the SPARQL XML Results format by default.
>>>>
>>>> Historically there was an ability to transcribe the tabular format
>>>> into a graph but this was a very niche use case (primarily only used
>>>> in the SPARQL test suite itself).  There were a bunch of changes in
>>>> Jena 4.x to simplify Content-Type handling to only use canonical
>>>> formats by default.
>>>>
>>>> Rob
>>> Using
>>>
>>> curl --header 'Accept: application/rdf+xml'
>>>
>>> works for me.
>>>
>>>
>>> Use of "pretty", to become the more basic form of RDF/XML changed
>>> several versions ago at 3.15.0. But that is not
>>> application/sparql-results+xml.
>>>
>>> https://issues.apache.org/jira/browse/JENA-1826
>>>
>>> Please can we have an example with query, curl call and versions numbers?
>>>
>>>     Andy
>>>
>>>> On 22/04/2021, 08:10, "Bardo Nelgen"
>>>> <ma...@bnnperformances.de>  wrote:
>>>>
>>>>       Hi all,
>>>>       �
>>>>       Maybe there is something about Jena 4 with outputting
>>>> „pretty“
>>>>       RDF/XML via Fuseki ?
>>>>       �
>>>>       Whenever asking Fuseki (i.e. via HTTP…
>> – be it from the
>>>> GUI or via
>>>>       curl) for RDF/XML results, it now ALWAYS defaults to SRX
>>>>       (application/SPARQL-results+xml).
>>>>       �
>>>>       The behaviour could be changed in older versions by sending an
>>>>       Accept-Header for application/rdf+xml. With version 4.0,
>>>> this option
>>>>       appears to be gone.
>>>>
>>>>       For now, I am through with the release notes,
>> existing bug
>>>> reports and
>>>>       the list archive already but find nothing coming similar to
>>>> what we
>>>>       currently experience.�
>>>>
>>>>       What is the contemporary approach to achieve the desired
>>>> result ?
>>>>       �
>>>>       Thanks in advance for any input.
>>>>       �
>>>>        Best,
>>>>
>>>>        Bardo
>>>>
>>>>
>>>>
>>>>

Re: Jena 4 and RDF/XML via Fuseki

Posted by Martynas Jusevičius <ma...@atomgraph.com>.
It's the same data, just formatted in a slightly different way. It
seems that RDFXML_PLAIN is the default RDF/XML writer in Jena 4.0:
https://jena.apache.org/documentation/io/rdf-output.html#rdfxml


On Thu, Apr 22, 2021 at 5:27 PM Bardo Nelgen
<ma...@bnnperformances.de> wrote:
>
> Sorry, of course you are right – both.
>
> When I looked at the output for the last time, I had a SELECT query
> running – thus completely foreseeable getting
> application/sparql-results+xml.
>
> What I was originally looking for is to format the result of a CONSTRUCT
> query, which as of now comes out quite linear like:
>
> >     <rdf:Description
> > rdf:about="http://resources.semaworx.eu/inventory/ActivityStreams/current/">
> >         <rdf:type
> > rdf:resource="http://namespaces.semaworx.org/inventoryControl/ActivityStreamGroup"/>
> >
> >         (… some ?p ?o here …)
> >
> >     </rdf:Description>
>
> Though, what I have been looking for, is supposed to come out more like:
> >     <rdf:RDF
> > xmlns:ive="http://namespaces.semaworx.org/inventoryControl/">
> >
> >     <ive:ActivityStreamGroup
> > rdf:about="http://resources.semaworx.eu/inventory/ActivityStreams/current/">
> >
> >     (… some ?p ?o here …)
> >
> >     </ive:ActivityStreamGroup>
> >
> >  Â </rdf:RDF>
>
> I’m quite aware I may have missed a change of defaults here.
>
> All I need to know is learning how to do this from now on.
>
> — Bardo
>
> On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
> >
> >
> > On 22/04/2021 09:55, Rob Vesse wrote:
> >> What is the query?
> >>
> >> RDF/XML is a graph format and so only makes sense for
> >> CONSTRUCT/DESCRIBE queries
> >>
> >> ASK/SELECT queries are going to produce tabular results which uses
> >> the SPARQL XML Results format by default.
> >>
> >> Historically there was an ability to transcribe the tabular format
> >> into a graph but this was a very niche use case (primarily only used
> >> in the SPARQL test suite itself).  There were a bunch of changes in
> >> Jena 4.x to simplify Content-Type handling to only use canonical
> >> formats by default.
> >>
> >> Rob
> >
> > Using
> >
> > curl --header 'Accept: application/rdf+xml'
> >
> > works for me.
> >
> >
> > Use of "pretty", to become the more basic form of RDF/XML changed
> > several versions ago at 3.15.0. But that is not
> > application/sparql-results+xml.
> >
> > https://issues.apache.org/jira/browse/JENA-1826
> >
> > Please can we have an example with query, curl call and versions numbers?
> >
> >    Andy
> >
> >> On 22/04/2021, 08:10, "Bardo Nelgen"
> >> <ma...@bnnperformances.de> wrote:
> >>
> >>      Hi all,
> >>      �
> >>      Maybe there is something about Jena 4 with outputting
> >> „pretty“
> >>      RDF/XML via Fuseki ?
> >>      �
> >>      Whenever asking Fuseki (i.e. via HTTP…
> – be it from the
> >> GUI or via
> >>      curl) for RDF/XML results, it now ALWAYS defaults to SRX
> >>      (application/SPARQL-results+xml).
> >>      �
> >>      The behaviour could be changed in older versions by sending an
> >>      Accept-Header for application/rdf+xml. With version 4.0,
> >> this option
> >>      appears to be gone.
> >>
> >>      For now, I am through with the release notes,
> existing bug
> >> reports and
> >>      the list archive already but find nothing coming similar to
> >> what we
> >>      currently experience.�
> >>
> >>      What is the contemporary approach to achieve the desired
> >> result ?
> >>      �
> >>      Thanks in advance for any input.
> >>      �
> >>       Best,
> >>
> >>       Bardo
> >>
> >>
> >>
> >>
> On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
> >
> >
> > On 22/04/2021 09:55, Rob Vesse wrote:
> >> What is the query?
> >>
> >> RDF/XML is a graph format and so only makes sense for
> >> CONSTRUCT/DESCRIBE queries
> >>
> >> ASK/SELECT queries are going to produce tabular results which uses
> >> the SPARQL XML Results format by default.
> >>
> >> Historically there was an ability to transcribe the tabular format
> >> into a graph but this was a very niche use case (primarily only used
> >> in the SPARQL test suite itself).  There were a bunch of changes in
> >> Jena 4.x to simplify Content-Type handling to only use canonical
> >> formats by default.
> >>
> >> Rob
> >
> > Using
> >
> > curl --header 'Accept: application/rdf+xml'
> >
> > works for me.
> >
> >
> > Use of "pretty", to become the more basic form of RDF/XML changed
> > several versions ago at 3.15.0. But that is not
> > application/sparql-results+xml.
> >
> > https://issues.apache.org/jira/browse/JENA-1826
> >
> > Please can we have an example with query, curl call and versions numbers?
> >
> >    Andy
> >
> >> On 22/04/2021, 08:10, "Bardo Nelgen"
> >> <ma...@bnnperformances.de> wrote:
> >>
> >>      Hi all,
> >>      �
> >>      Maybe there is something about Jena 4 with outputting
> >> „pretty“
> >>      RDF/XML via Fuseki ?
> >>      �
> >>      Whenever asking Fuseki (i.e. via HTTP…
> – be it from the
> >> GUI or via
> >>      curl) for RDF/XML results, it now ALWAYS defaults to SRX
> >>      (application/SPARQL-results+xml).
> >>      �
> >>      The behaviour could be changed in older versions by sending an
> >>      Accept-Header for application/rdf+xml. With version 4.0,
> >> this option
> >>      appears to be gone.
> >>
> >>      For now, I am through with the release notes,
> existing bug
> >> reports and
> >>      the list archive already but find nothing coming similar to
> >> what we
> >>      currently experience.�
> >>
> >>      What is the contemporary approach to achieve the desired
> >> result ?
> >>      �
> >>      Thanks in advance for any input.
> >>      �
> >>       Best,
> >>
> >>       Bardo
> >>
> >>
> >>
> >>

Re: Jena 4 and RDF/XML via Fuseki

Posted by Bardo Nelgen <ma...@bnnperformances.de>.
Sorry, of course you are right – both.

When I looked at the output for the last time, I had a SELECT query 
running – thus completely foreseeable getting 
application/sparql-results+xml.

What I was originally looking for is to format the result of a CONSTRUCT 
query, which as of now comes out quite linear like:

>     <rdf:Description 
> rdf:about="http://resources.semaworx.eu/inventory/ActivityStreams/current/">
>         <rdf:type 
> rdf:resource="http://namespaces.semaworx.org/inventoryControl/ActivityStreamGroup"/>
>
>         (… some ?p ?o here …)
>
>     </rdf:Description>

Though, what I have been looking for, is supposed to come out more like:
>     <rdf:RDF 
> xmlns:ive="http://namespaces.semaworx.org/inventoryControl/">
>
>     <ive:ActivityStreamGroup 
> rdf:about="http://resources.semaworx.eu/inventory/ActivityStreams/current/">
>
>     (… some ?p ?o here …)
>
>     </ive:ActivityStreamGroup>
>
>  � </rdf:RDF>

I’m quite aware I may have missed a change of defaults here.

All I need to know is learning how to do this from now on.

— Bardo

On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
>
>
> On 22/04/2021 09:55, Rob Vesse wrote:
>> What is the query?
>>
>> RDF/XML is a graph format and so only makes sense for 
>> CONSTRUCT/DESCRIBE queries
>>
>> ASK/SELECT queries are going to produce tabular results which uses 
>> the SPARQL XML Results format by default.
>>
>> Historically there was an ability to transcribe the tabular format 
>> into a graph but this was a very niche use case (primarily only used 
>> in the SPARQL test suite itself).  There were a bunch of changes in 
>> Jena 4.x to simplify Content-Type handling to only use canonical 
>> formats by default.
>>
>> Rob
>
> Using
>
> curl --header 'Accept: application/rdf+xml'
>
> works for me.
>
>
> Use of "pretty", to become the more basic form of RDF/XML changed 
> several versions ago at 3.15.0. But that is not 
> application/sparql-results+xml.
>
> https://issues.apache.org/jira/browse/JENA-1826
>
> Please can we have an example with query, curl call and versions numbers?
>
>    Andy
>
>> On 22/04/2021, 08:10, "Bardo Nelgen" 
>> <ma...@bnnperformances.de> wrote:
>>
>>      Hi all,
>>      �
>>      Maybe there is something about Jena 4 with outputting 
>> „pretty“
>>      RDF/XML via Fuseki ?
>>      �
>>      Whenever asking Fuseki (i.e. via HTTP… 
– be it from the 
>> GUI or via
>>      curl) for RDF/XML results, it now ALWAYS defaults to SRX
>>      (application/SPARQL-results+xml).
>>      �
>>      The behaviour could be changed in older versions by sending an
>>      Accept-Header for application/rdf+xml. With version 4.0, 
>> this option
>>      appears to be gone.
>>
>>      For now, I am through with the release notes, 
existing bug 
>> reports and
>>      the list archive already but find nothing coming similar to 
>> what we
>>      currently experience.�
>>
>>      What is the contemporary approach to achieve the desired 
>> result ?
>>      �
>>      Thanks in advance for any input.
>>      �
>>       Best,
>>
>>       Bardo
>>
>>
>>
>>
On 22.04.21 11.09 Uhr, Andy Seaborne wrote:
>
>
> On 22/04/2021 09:55, Rob Vesse wrote:
>> What is the query?
>>
>> RDF/XML is a graph format and so only makes sense for 
>> CONSTRUCT/DESCRIBE queries
>>
>> ASK/SELECT queries are going to produce tabular results which uses 
>> the SPARQL XML Results format by default.
>>
>> Historically there was an ability to transcribe the tabular format 
>> into a graph but this was a very niche use case (primarily only used 
>> in the SPARQL test suite itself).  There were a bunch of changes in 
>> Jena 4.x to simplify Content-Type handling to only use canonical 
>> formats by default.
>>
>> Rob
>
> Using
>
> curl --header 'Accept: application/rdf+xml'
>
> works for me.
>
>
> Use of "pretty", to become the more basic form of RDF/XML changed 
> several versions ago at 3.15.0. But that is not 
> application/sparql-results+xml.
>
> https://issues.apache.org/jira/browse/JENA-1826
>
> Please can we have an example with query, curl call and versions numbers?
>
>    Andy
>
>> On 22/04/2021, 08:10, "Bardo Nelgen" 
>> <ma...@bnnperformances.de> wrote:
>>
>>      Hi all,
>>      �
>>      Maybe there is something about Jena 4 with outputting 
>> „pretty“
>>      RDF/XML via Fuseki ?
>>      �
>>      Whenever asking Fuseki (i.e. via HTTP… 
– be it from the 
>> GUI or via
>>      curl) for RDF/XML results, it now ALWAYS defaults to SRX
>>      (application/SPARQL-results+xml).
>>      �
>>      The behaviour could be changed in older versions by sending an
>>      Accept-Header for application/rdf+xml. With version 4.0, 
>> this option
>>      appears to be gone.
>>
>>      For now, I am through with the release notes, 
existing bug 
>> reports and
>>      the list archive already but find nothing coming similar to 
>> what we
>>      currently experience.�
>>
>>      What is the contemporary approach to achieve the desired 
>> result ?
>>      �
>>      Thanks in advance for any input.
>>      �
>>       Best,
>>
>>       Bardo
>>
>>
>>
>>

Re: Jena 4 and RDF/XML via Fuseki

Posted by Andy Seaborne <an...@apache.org>.

On 22/04/2021 09:55, Rob Vesse wrote:
> What is the query?
> 
> RDF/XML is a graph format and so only makes sense for CONSTRUCT/DESCRIBE queries
> 
> ASK/SELECT queries are going to produce tabular results which uses the SPARQL XML Results format by default.
> 
> Historically there was an ability to transcribe the tabular format into a graph but this was a very niche use case (primarily only used in the SPARQL test suite itself).  There were a bunch of changes in Jena 4.x to simplify Content-Type handling to only use canonical formats by default.
> 
> Rob

Using

curl --header 'Accept: application/rdf+xml'

works for me.


Use of "pretty", to become the more basic form of RDF/XML changed 
several versions ago at 3.15.0. But that is not 
application/sparql-results+xml.

https://issues.apache.org/jira/browse/JENA-1826

Please can we have an example with query, curl call and versions numbers?

     Andy

> On 22/04/2021, 08:10, "Bardo Nelgen" <ma...@bnnperformances.de> wrote:
> 
>      Hi all,
>      �
>      Maybe there is something about Jena 4 with outputting „pretty“
>      RDF/XML via Fuseki ?
>      �
>      Whenever asking Fuseki (i.e. via HTTP… – be it from the GUI or via
>      curl) for RDF/XML results, it now ALWAYS defaults to SRX
>      (application/SPARQL-results+xml).
>      �
>      The behaviour could be changed in older versions by sending an
>      Accept-Header for application/rdf+xml. With version 4.0, this option
>      appears to be gone.
> 
>      For now, I am through with the release notes, existing bug reports and
>      the list archive already but find nothing coming similar to what we
>      currently experience.�
> 
>      What is the contemporary approach to achieve the desired result ?
>      �
>      Thanks in advance for any input.
>      �
>       Best,
> 
>       Bardo
> 
> 
> 
> 

Re: Jena 4 and RDF/XML via Fuseki

Posted by Rob Vesse <rv...@dotnetrdf.org>.
What is the query?

RDF/XML is a graph format and so only makes sense for CONSTRUCT/DESCRIBE queries

ASK/SELECT queries are going to produce tabular results which uses the SPARQL XML Results format by default.

Historically there was an ability to transcribe the tabular format into a graph but this was a very niche use case (primarily only used in the SPARQL test suite itself).  There were a bunch of changes in Jena 4.x to simplify Content-Type handling to only use canonical formats by default.

Rob

On 22/04/2021, 08:10, "Bardo Nelgen" <ma...@bnnperformances.de> wrote:

    Hi all,
    �
    Maybe there is something about Jena 4 with outputting „pretty“ 
    RDF/XML via Fuseki ?
    �
    Whenever asking Fuseki (i.e. via HTTP… – be it from the GUI or via 
    curl) for RDF/XML results, it now ALWAYS defaults to SRX 
    (application/SPARQL-results+xml).
    �
    The behaviour could be changed in older versions by sending an 
    Accept-Header for application/rdf+xml. With version 4.0, this option 
    appears to be gone.

    For now, I am through with the release notes, existing bug reports and 
    the list archive already but find nothing coming similar to what we 
    currently experience.�

    What is the contemporary approach to achieve the desired result ?
    �
    Thanks in advance for any input.
    �
     Best,

     Bardo