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
Add a Preference for ServerManaged (and allow clients to exclude Server Managed properties on update) #549
Conversation
rdfStream.concat(getTriples(AclRdfContext.class)); | ||
rdfStream.concat(getTriples(TypeRdfContext.class)); | ||
final Predicate<Triple> tripleFilter; | ||
if (ldpPreferences.prefersServerManaged()) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is sad, but I think post-filtering is much easier than trying to add a way to push the filter upstream... plus, we already have a predicate for filtering triples, but not one for filtering JCR properties.
ab6c0d7
to
b31fb64
Compare
REPOSITORY_NAMESPACE, JCR_NAMESPACE); | ||
REPOSITORY_NAMESPACE, JCR_NAMESPACE, | ||
MIX_NAMESPACE, JCR_NT_NAMESPACE, MODE_NAMESPACE, | ||
LDP_NAMESPACE); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Talking with @azaroth42, we believe these namespaces are always considered server-managed (and, at a practical level, should never be used by a client providing a rdf:type
)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay, but are we cool with people using them in other contexts, e.g.:
someThing somePredicate LDP_NAMESPACE#someObject
or are we saying that any RDF that uses any of these namespaces in any way is verboten.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We're just preventing their use in user-provided types, and preventing them from displaying when server-managed properties or a minimal response format is requested (but they're free to add them) .. which I think is about right for all the LDP defined predicates right now.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The rationale is to make it easy for client systems to get back what they put in, without all of the overhead added by the server managed properties. It became kinda crazy when you put in three triples and got back thirty.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, I get the desire to not display them on the way out (when that's what the client wants). I was just checking on what we're constraining on the way in. It sounds good to me. +1
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Only for rdf:type
, which we can argue LDP lets us do.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, and even it didn't, I find it very hard to think of a use case for allowing that kind of monkey business. I'd rather anyone who thinks they need to do this bring it up in a public forum so we can figure out what they're trying to do and help them.
319285c
to
6cc2ad4
Compare
65d325a
to
c541025
Compare
…ntend to operate against This allows clients who only have a partial representation of a resource to use PUT operations to replace only the triples they are aware of, or provide hints to the server about what triples they intend to operate on (for e.g. PATCH) e.g.: PUT /a Prefer: handling=lenient; omit="http://fedora.info/definitions/v4/repository#ServerManaged" ... only non-managed server properties ... or PUT /a Prefer: handling=lenient; received="minimal" ... only the minimal representation ...
4fddadb
to
2009fd6
Compare
2009fd6
to
77f7769
Compare
Add a Preference for ServerManaged (and allow clients to exclude Server Managed properties on update)
https://www.pivotaltracker.com/story/show/80874156
https://www.pivotaltracker.com/story/show/80874184