Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Behavior for other SPARQL Update operations #323

Open
wants to merge 2 commits into
base: feature/sparql-update
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion protocol.html
Original file line number Diff line number Diff line change
Expand Up @@ -709,7 +709,7 @@ <h3 property="schema:name">Writing Resources</h3>
<span about="" id="server-patch-sparql-all" rel="spec:requirement" resource="#server-patch-sparql-all"><span property="spec:statement"> <span rel="spec:requirementSubject" resource="spec:Server">Servers</span> <span rel="spec:requirementLevel" resource="spec:MAY">MAY</span> further support SPARQL 1.1 Update [<cite><a class="bibref" href="#bib-sparql-overview">SPARQL</a></cite>],</span></span>
<span about="" id="server-patch-sparql-not-other" rel="spec:requirement" resource="#server-patch-sparql-not-other"><span property="spec:statement"> except that <span rel="spec:requirementSubject" resource="spec:Server">servers</span> <span rel="spec:requirementLevel" resource="spec:MUSTNOT">MUST NOT</span> allow a request with a <code>PATCH</code> method to change other resources than the target resource.</span></span> [<a href="https://github.com/solid/specification/issues/125#issuecomment-873035679" rel="cito:citesAsSourceDocument">Source</a>]
<span about="" id="server-patch-sparql-outside-subset" rel="spec:requirement" resource="#server-patch-sparql-outside-subset"><span property="spec:statement"><span rel="spec:requirementSubject" resource="spec:Server">Servers</span> that receives a request body containing a SPARQL query that falls outside of the subset they are able to process <span rel="spec:requirementLevel" resource="spec:MUST">MUST</span> respond with a <code>422</code> status code [<cite><a class="bibref" href="#bib-rfc4918">RFC4918</a></cite>] and a message body that explains the error.</span></span>

<span about="" id="server-patch-sparql-not-update" rel="spec:requirement" resource="#server-patch-sparql-not-update"><span property="spec:statement">SPARQL Update [<cite><a class="bibref" href="#bib-sparql-overview">SPARQL</a></cite>] also defines operations <code>LOAD</code>, <code>CLEAR</code>, <code>CREATE</code>, <code>DROP</code>, <code>COPY</code>, <code>MOVE</code> and <code>ADD</code>. <span rel="spec:requirementSubject" resource="spec:Server">Servers</span> that receives a <code>PATCH</code> request body containing these operations <span rel="spec:requirementLevel" resource="spec:SHOULD">SHOULD</span> respond with a <code>422</code> status code [<cite><a class="bibref" href="#bib-rfc4918">RFC4918</a></cite>] and a message body that explains the error, or MUST ensure that any access control measures apply.</span></span>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

or MUST ensure that any access control measures apply.

The 'or' there is slightly confusing -- shouldn't that be an 'and'?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
<span about="" id="server-patch-sparql-not-update" rel="spec:requirement" resource="#server-patch-sparql-not-update"><span property="spec:statement">SPARQL Update [<cite><a class="bibref" href="#bib-sparql-overview">SPARQL</a></cite>] also defines operations <code>LOAD</code>, <code>CLEAR</code>, <code>CREATE</code>, <code>DROP</code>, <code>COPY</code>, <code>MOVE</code> and <code>ADD</code>. <span rel="spec:requirementSubject" resource="spec:Server">Servers</span> that receives a <code>PATCH</code> request body containing these operations <span rel="spec:requirementLevel" resource="spec:SHOULD">SHOULD</span> respond with a <code>422</code> status code [<cite><a class="bibref" href="#bib-rfc4918">RFC4918</a></cite>] and a message body that explains the error, or MUST ensure that any access control measures apply.</span></span>
<span about="" id="server-patch-sparql-not-update" rel="spec:requirement" resource="#server-patch-sparql-not-update"><span property="spec:statement">SPARQL Update [<cite><a class="bibref" href="#bib-sparql-overview">SPARQL</a></cite>] also defines operations <code>LOAD</code>, <code>CLEAR</code>, <code>CREATE</code>, <code>DROP</code>, <code>COPY</code>, <code>MOVE</code> and <code>ADD</code>. <span rel="spec:requirementSubject" resource="spec:Server">Servers</span> that receives a <code>PATCH</code> request body containing these operations (1) <span rel="spec:requirementLevel" resource="spec:SHOULD">SHOULD</span> respond with a <code>422</code> status code [<cite><a class="bibref" href="#bib-rfc4918">RFC4918</a></cite>] and a message body that explains the error, and (2) MUST ensure that any access control measures apply.</span></span>

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's an OR, not an AND.
EITHER ensure measures apply OR respond with an error.
Not both.

Copy link
Contributor

@TallTed TallTed Oct 28, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@michielbdejong -- Note that my suggestion sprang from @dmitrizagidulin's earlier comment. I don't think "EITHER MUST ensure measures apply OR SHOULD respond with an error" makes sense. Does one of these work?

  • "MUST EITHER ensure measures apply OR respond with an error"
  • "SHOULD EITHER ensure measures apply OR respond with an error"

</p>

<p>
Expand Down