You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Ben Collins-Sussman <su...@collab.net> on 2002/07/29 22:30:14 UTC

svn:custom: gone?

Gstein, I'm confused about the state of our DAV layer.  

Once upon a time, we used to marshall svn: and svn:custom: props from
server to client.  It seems we're not doing that anymore.   Notice
this line from the body response to a PROPFIND of <allprops/>:

<D:response xmlns:S="svn:" 
            xmlns:C="svn:custom:" 
            xmlns:lp3="svn:" 
            xmlns:lp1="DAV:"
            xmlns:lp2="http://apache.org/dav/props/">

If you grep through the whole response, the "C:" namespace isn't used
at all anymore!  User-defined props like 'svn:ignore' are marshalled
as <S:ignore>, and server-defined props are marshalled as
<lp3:baseline-relative-path>. 

Of course, this is useless to my RA->get_dir() routine.  It sees both
of these properties as existing in the same 'svn:' namespace.  (Why
the heck are we defining the 'svn:' namespace *twice* now?)  

ra_dav->get_dir() is simply trying to figure out if the resource has
any user-defined props, and now it can't tell them apart from
svn-specific liveprops anymore.  :-(

Can you address any of these issues?  Tell me what happened?  Give me
a suggested remedy?  


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: svn:custom: gone?

Posted by Greg Stein <gs...@lyra.org>.
On Tue, Jul 30, 2002 at 04:20:03PM -0500, Ben Collins-Sussman wrote:
> Greg Stein <gs...@lyra.org> writes:
> 
> > 1) svn-defined properties (not in repository; "entry" props)
> 
> Actually, any 'svn:' property that is interpreted by either client or
> repository.  This include svn:eol-style, svn:mime-type,
> svn:executable, and all the svn:entry: props.  They're all stored in
> the repository as well.

Oh heck. We have the same problem with entry props, now that I think about
it. What if we define a new entry property and a server generates the thing?
Old clients will interpret it as a stored-in-repository property.

Thus, we'd have ...xmlns/repos and ...xmlns/entry

(or 'entry' could be 'ephemeral' or 'live' or somesuch)

Properties set at the command-line that start with svn: will always go into
the .../repos namespace. Manufactured properties (svn's "live" props) would
go into ../entry or whatever.

Cheers,
-g

-- 
Greg Stein, http://www.lyra.org/

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: svn:custom: gone?

Posted by Ben Collins-Sussman <su...@collab.net>.
Greg Stein <gs...@lyra.org> writes:

> 1) svn-defined properties (not in repository; "entry" props)

Actually, any 'svn:' property that is interpreted by either client or
repository.  This include svn:eol-style, svn:mime-type,
svn:executable, and all the svn:entry: props.  They're all stored in
the repository as well.

> 2) user-defined properties (svn propset ...)

Any properties stored in the repository that don't begin with svn:.
'svn propset' can be used to set either category 1 or 2.  

> 3) dav-defined properties (mod_dav_svn and libsvn_ra_dav)

Properties strictly generated and consumed by the network layer.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: svn:custom: gone?

Posted by Greg Stein <gs...@lyra.org>.
On Tue, Jul 30, 2002 at 06:18:44AM -0500, Ben Collins-Sussman wrote:
>...
> > > ra_dav->get_dir() is simply trying to figure out if the resource has
> > > any user-defined props, and now it can't tell them apart from
> > > svn-specific liveprops anymore.  :-(
>...
> The confusion here is that you and I have different definition of
> "user" properties.  Your definition seems to be:  "any property name
> set by the user that doesn't start with svn:".  My definition is "any
> property stored in the repository."
> 
> ra->get_dir() is trying to answer the question: "does this resource
> have props attached to it in the repository?"  So it needs to notice
> properties named "foo" and "svn:eol-style", but it needs to *ignore*
> properties like "svn:baseline-relative-path".  There's doesn't seem to
> be a way to do that.


FYI (dev list):

The Chicago guys and I had a phone conversation this morning, and we covered
this topic. Specifically, we are going to marshal properties over the wire
as one of three types of properties (discrimated by the XML namespace URI):

1) svn-defined properties (not in repository; "entry" props)
2) user-defined properties (svn propset ...)
3) dav-defined properties (mod_dav_svn and libsvn_ra_dav)

So svn:baseline-relative-path will move into type (3). We are also going to
change the URIs that we use within the XML documents/fragments.
Specifically, we're going to switch to http URLs (rather than "svn:" and
similar). The URI community has had discussions on whether "foo:" is a legal
URI, and we still have the issue that "svn" would need to be registered as a
scheme (where "registration" means an Internet-Draft and/or RFC). We can
simply avoid the whole question by using URLs when marshalling content
to/from XML.

To change the URIs, we're going to update the client to recognize both. Let
that client filter out into the user base, and then upgrade the server
sometime in the future to generate the new URIs.

Cheers,
-g

-- 
Greg Stein, http://www.lyra.org/

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: svn:custom: gone?

Posted by Ben Collins-Sussman <su...@collab.net>.
Greg Stein <gs...@lyra.org> writes:
> 
> The svn:custom: prefix is used for *user* properties.

Gotcha.

> > ra_dav->get_dir() is simply trying to figure out if the resource has
> > any user-defined props, and now it can't tell them apart from
> > svn-specific liveprops anymore.  :-(
> 
> I don't understand this part.

The confusion here is that you and I have different definition of
"user" properties.  Your definition seems to be:  "any property name
set by the user that doesn't start with svn:".  My definition is "any
property stored in the repository."

ra->get_dir() is trying to answer the question: "does this resource
have props attached to it in the repository?"  So it needs to notice
properties named "foo" and "svn:eol-style", but it needs to *ignore*
properties like "svn:baseline-relative-path".  There's doesn't seem to
be a way to do that.




---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: svn:custom: gone?

Posted by Greg Stein <gs...@lyra.org>.
On Mon, Jul 29, 2002 at 05:30:14PM -0500, Ben Collins-Sussman wrote:
>...
> <D:response xmlns:S="svn:" 
>             xmlns:C="svn:custom:" 
>             xmlns:lp3="svn:" 
>             xmlns:lp1="DAV:"
>             xmlns:lp2="http://apache.org/dav/props/">
> 
> If you grep through the whole response, the "C:" namespace isn't used
> at all anymore!  User-defined props like 'svn:ignore' are marshalled
> as <S:ignore>, and server-defined props are marshalled as
> <lp3:baseline-relative-path>.

$ svn pset my-prop hi-ben foo.c
$ svn commit -m "blah"
...
$ svn co http://whatever/

The svn:custom: prefix is used for *user* properties.

> Of course, this is useless to my RA->get_dir() routine.  It sees both
> of these properties as existing in the same 'svn:' namespace.  (Why
> the heck are we defining the 'svn:' namespace *twice* now?)

We aren't defining the *namespace* twice. We're defining two *prefixes*,
which is perfectly legit. Different parts of the system allocate prefixes,
so we end up with a couple. mod_dav supports tighter compression, but it
would change some of our constant text (which uses S:baz) to need a variable
part, based on the prefix assigned by the dav_xmlns code.

> ra_dav->get_dir() is simply trying to figure out if the resource has
> any user-defined props, and now it can't tell them apart from
> svn-specific liveprops anymore.  :-(

I don't understand this part.

Cheers,
-g

-- 
Greg Stein, http://www.lyra.org/

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org