You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Daniel Shahaf <d....@daniel.shahaf.name> on 2011/09/14 00:38:36 UTC

Re: svn commit: r1170324 - /subversion/trunk/subversion/include/svn_editor.h

(about svn_editor_set_props())

hwright@apache.org wrote on Tue, Sep 13, 2011 at 19:54:14 -0000:
> Author: hwright
> Date: Tue Sep 13 19:54:14 2011
> New Revision: 1170324
> 
> URL: http://svn.apache.org/viewvc?rev=1170324&view=rev
> Log:
> * subversion/include/svn_editor.h
>   (svn_editor_set_props): Add a couple of notes.
> 
> Modified:
>     subversion/trunk/subversion/include/svn_editor.h
> 
...
>   * Set or change properties on the existing node at @a relpath.
>   * ### TODO @todo Does this send *all* properties, always?

I'd answer "As written, yes" since the props parameter is an apr_hash_t
(and the docstring doesn't make special arrangements for representation
of propdels within that).

> + * ### HKW: The purist in me says "yes", but the pragmatist says "no".
> + * ### Writing a backward compat shim is going to be next to impossible,
> + * ### since we've no way to know about existing props while receiving
> + * ### props from the delta editor.
> + * ###

For example, 'svn propset pn pv URL' does not know the remaining
properties of URL.

That said: isn't this discussion similar to the discussion from last
week about whether svn_editor_set_text() should be taking a full
contents stream or a delta stream?  Does the resolution of that
discusion apply here?

>   * ### TODO @todo What is REVISION for?
> + * ### HKW: This is puzzling to me as well...
> + * ###
>   * ### what about "entry props"? will these still be handled via
>   * ### the general prop function?
>   *
> 

Re: svn commit: r1170324 - /subversion/trunk/subversion/include/svn_editor.h

Posted by Hyrum K Wright <hy...@wandisco.com>.
On Tue, Sep 13, 2011 at 5:38 PM, Daniel Shahaf <d....@daniel.shahaf.name> wrote:
> (about svn_editor_set_props())
>
> hwright@apache.org wrote on Tue, Sep 13, 2011 at 19:54:14 -0000:
>> Author: hwright
>> Date: Tue Sep 13 19:54:14 2011
>> New Revision: 1170324
>>
>> URL: http://svn.apache.org/viewvc?rev=1170324&view=rev
>> Log:
>> * subversion/include/svn_editor.h
>>   (svn_editor_set_props): Add a couple of notes.
>>
>> Modified:
>>     subversion/trunk/subversion/include/svn_editor.h
>>
> ...
>>   * Set or change properties on the existing node at @a relpath.
>>   * ### TODO @todo Does this send *all* properties, always?
>
> I'd answer "As written, yes" since the props parameter is an apr_hash_t
> (and the docstring doesn't make special arrangements for representation
> of propdels within that).
>
>> + * ### HKW: The purist in me says "yes", but the pragmatist says "no".
>> + * ### Writing a backward compat shim is going to be next to impossible,
>> + * ### since we've no way to know about existing props while receiving
>> + * ### props from the delta editor.
>> + * ###
>
> For example, 'svn propset pn pv URL' does not know the remaining
> properties of URL.
>
> That said: isn't this discussion similar to the discussion from last
> week about whether svn_editor_set_text() should be taking a full
> contents stream or a delta stream?  Does the resolution of that
> discusion apply here?

I think it does: provide a callback to the shim so it can get the
existing properties on a node.  I arrived at this conclusion when
thinking about the problem last night, and then discovered your and
Greg's suggestions this morning.  Guess I'm on the right track!  (Or,
we're all wrong together...)

-Hyrum


-- 

uberSVN: Apache Subversion Made Easy
http://www.uberSVN.com/

Re: svn commit: r1170324 - /subversion/trunk/subversion/include/svn_editor.h

Posted by Hyrum K Wright <hy...@wandisco.com>.
On Tue, Sep 13, 2011 at 5:38 PM, Daniel Shahaf <d....@daniel.shahaf.name> wrote:
> (about svn_editor_set_props())
>
> hwright@apache.org wrote on Tue, Sep 13, 2011 at 19:54:14 -0000:
>> Author: hwright
>> Date: Tue Sep 13 19:54:14 2011
>> New Revision: 1170324
>>
>> URL: http://svn.apache.org/viewvc?rev=1170324&view=rev
>> Log:
>> * subversion/include/svn_editor.h
>>   (svn_editor_set_props): Add a couple of notes.
>>
>> Modified:
>>     subversion/trunk/subversion/include/svn_editor.h
>>
> ...
>>   * Set or change properties on the existing node at @a relpath.
>>   * ### TODO @todo Does this send *all* properties, always?
>
> I'd answer "As written, yes" since the props parameter is an apr_hash_t
> (and the docstring doesn't make special arrangements for representation
> of propdels within that).
>
>> + * ### HKW: The purist in me says "yes", but the pragmatist says "no".
>> + * ### Writing a backward compat shim is going to be next to impossible,
>> + * ### since we've no way to know about existing props while receiving
>> + * ### props from the delta editor.
>> + * ###
>
> For example, 'svn propset pn pv URL' does not know the remaining
> properties of URL.
>
> That said: isn't this discussion similar to the discussion from last
> week about whether svn_editor_set_text() should be taking a full
> contents stream or a delta stream?  Does the resolution of that
> discusion apply here?

I think it does: provide a callback to the shim so it can get the
existing properties on a node.  I arrived at this conclusion when
thinking about the problem last night, and then discovered your and
Greg's suggestions this morning.  Guess I'm on the right track!  (Or,
we're all wrong together...)

-Hyrum


-- 

uberSVN: Apache Subversion Made Easy
http://www.uberSVN.com/