[ 
https://issues.apache.org/jira/browse/JENA-1946?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17182071#comment-17182071
 ] 

Martynas Jusevičius commented on JENA-1946:
-------------------------------------------

Why JSON and not RDF? For example using the [HTTP Vocabulary in 
RDF|https://www.w3.org/TR/HTTP-in-RDF10/].

Example:
{code}
curl -H "Accept: text/turtle" https://linkeddatahub.com/whateverest

[ a       <http://www.w3.org/2011/http#Response> ;
  <http://purl.org/dc/terms/title>
          "Access not authorized" ;
  <http://www.w3.org/2011/http#absoluteURI>
          "https://linkeddatahub.com/whateverest"; ;
  <http://www.w3.org/2011/http#reasonPhrase>
          "Forbidden" ;
  <http://www.w3.org/2011/http#sc>
          <http://www.w3.org/2011/http-statusCodes#Forbidden> ;
  <http://www.w3.org/2011/http#statusCodeValue>
          "403"^^<http://www.w3.org/2001/XMLSchema#long>
] .
{code}

> Fuseki error messages
> ---------------------
>
>                 Key: JENA-1946
>                 URL: https://issues.apache.org/jira/browse/JENA-1946
>             Project: Apache Jena
>          Issue Type: Improvement
>          Components: Fuseki
>    Affects Versions: Jena 3.16.0
>            Reporter: Andy Seaborne
>            Assignee: Andy Seaborne
>            Priority: Major
>
> Fuseki error handlers try to set the "reason phrase" (one has a bug in it 
> whereby the phrase will be null).
> HTTP/2 responses do not have a reason phrase.
> Browser are reported to ignore any reason phrase.
> To prepare for the future, the error handling could change to:
>  * Use the standard reason phrase / let the system choose.
>  * Put in a plain text content body with the error message.
>  * (Future) Put in a JSON object with the error message if there is a 
> standard object format / JSON-LD schema.
> There is no ideal answer here - there is a diverse set of user expectations.
>  
>  
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to