jackrabbit-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Felix Meschberger <fmesc...@gmail.com>
Subject Re: [Jackrabbit Wiki] Update of "Jsop" by MichaelDürig
Date Sun, 06 Nov 2011 19:11:00 GMT
Hi,

Am 02.11.2011 um 17:22 schrieb Michael Dürig:

> 
> 
> On 2.11.11 16:07, Felix Meschberger wrote:
>> Hi,
>> 
>> Thanks Thomas and Michael for documenting your JSOP use.
>> 
>> I have one comment:
>> 
>>> + DIFFS    ::= (ADD | SET | REMOVE | MOVE)*
>>> + ADD      ::= "+" STRING ":" (OBJECT | ATOM)
>>> + SET      ::= "^" STRING ":" ATOM
>>> + REMOVE   ::= "-" STRING
>> 
>> I see there is ADD support for properties but no REMOVE support. I think ADD support
is not needed, because SET does it all. This not only makes the syntax cleaner but also its
use.
>> 
>> If we keep ADD support for properties, we would -- for symmetry reasons -- have to
add REMOVE support for properties. But this is not possible (since properties and nodes can
have the same name). But then REMOVE support for properties would not help anything, since
setting a property to  null is the same.
>> 
>> I look at this from the perspective of converting a JSOP document (or string or text
or file or HTTP request) into a series of JCR API calls. In such a scenario, I would have
easy support for SET and REMOVE but would have two issues for supporting ADD:
>> (1) I would have to inspect the argument to ADD to find out whether it is an addNode
or setProperty call
>> (2) I would have to handle SET and ADD-for-property with the same setProperty call
> 
> The intended use is not only for HTTP calls but rather also for HTTP replies. In the
case of a HTTP reply carrying a change log, how would you distinguish setProperty from adProperty?
I.e. generate the correct JCR observation events from that change log?

Right. I wonder, why this would be of interest ? (and yes I know that there is a PROPERTY_ADDED
and a PROPERTY_CHANGED event type in observation, but ...)

Regards
Felix
> 
> Michael


Mime
View raw message