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 2001/07/07 13:12:04 UTC
property policy.
OK, so I've had a night to sleep on this, and I now have a strong
opinion on how to deal with DAV props versus 'regular' props.
First, I believe there is fundamental difference between these
categories. 'Regular' props are the ones the user cares about and
expects to see and change. Regular props are versioned along with
file text. Meanwhile, DAV props are necessary bookkeeping for a
certain network layer. They are *not* versioned, and the user isn't
interested in them -- they're an implementation detail of one
particular RA module.
I realize now that this situation has already come up before. ra_dav
had to store bookkeeping properties on the client-side in order to
function. Our final solution was *not* to treat these props as normal
ones, and instead store them in a secret area of the SVN/
administrative dir (and provide the RA layer special get/set routines
for them.) This prevents the properties from being versioned & stored
in the repository, and prevents the user from knowing they even exist.
This was a solution that everybody was satisfied with. It also
implied a general principle:
RA implementation details should *not* be visible to the user. It
should be impossible (from the user's point of view) to discern how
a working copy is accessing a repository.
I believe now that this principle can be extended to the other half of
the situation we're now in. I say "other half", because now we see
that the DAV layer wants to store bookkeeping props on the subversion
*server*.
It's very easy to say: "hey, libsvn_fs has props, WebDAV has props, so
let's line them up, and use namespaces to sort them out." But this
violates the principle above. Suddenly, one RA module's
implementation details are exposed to the whole world. They're
sitting in the repository -- and now a burden has been placed on
*every* reader of the repository to either filter them out or wrongly
expose them to the user. And we're not just talking about other RA
modules; we're talking about all future applications that will use
libsvn_fs! This is totally unacceptable, IMHO.
But notice that Greg Stein has already solved a similar problem.
mod_dav_svn needs to track temporary URLs that that represent fs
transactions -- and it's doing this by dumping tables to a private dbm
file in the repository dir (using APR dbm routines.)
Therefore, I say that all of the server-generated "DAV:" props be
stored in the same way -- in a private dbm file. It keeps the
repository pristine, and is perfectly consistent with the way we solve
this problem on the client-side.
Feedback? Let me hear some +1's. :-)
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: property policy.
Posted by Karl Fogel <kf...@collab.net>.
+1 here too, Ben.
Not sure I'd go so far as to say that how the network layer works
needs to be *invisible* to the user, but the network layer does need
to avoid interfering with domains that one reasonably expects to be
isolated from networking code. Subversion properties are one such
domain.
-K
Branko Čibej <br...@xbc.nu> writes:
> Ben Collins-Sussman wrote:
>
> >OK, so I've had a night to sleep on this, and I now have a strong
> >opinion on how to deal with DAV props versus 'regular' props.
> >
> >First, I believe there is fundamental difference between these
> >categories. 'Regular' props are the ones the user cares about and
> >expects to see and change. Regular props are versioned along with
> >file text. Meanwhile, DAV props are necessary bookkeeping for a
> >certain network layer. They are *not* versioned, and the user isn't
> >interested in them -- they're an implementation detail of one
> >particular RA module.
> >
> >I realize now that this situation has already come up before. ra_dav
> >had to store bookkeeping properties on the client-side in order to
> >function. Our final solution was *not* to treat these props as normal
> >ones, and instead store them in a secret area of the SVN/
> >administrative dir (and provide the RA layer special get/set routines
> >for them.) This prevents the properties from being versioned & stored
> >in the repository, and prevents the user from knowing they even exist.
> >
> >This was a solution that everybody was satisfied with. It also
> >implied a general principle:
> >
> > RA implementation details should *not* be visible to the user. It
> > should be impossible (from the user's point of view) to discern how
> > a working copy is accessing a repository.
> >
> >I believe now that this principle can be extended to the other half of
> >the situation we're now in. I say "other half", because now we see
> >that the DAV layer wants to store bookkeeping props on the subversion
> > *server*. It's very easy to say: "hey, libsvn_fs has props, WebDAV has
> > props, so
> >let's line them up, and use namespaces to sort them out." But this
> >violates the principle above. Suddenly, one RA module's
> >implementation details are exposed to the whole world. They're
> >sitting in the repository -- and now a burden has been placed on
> >*every* reader of the repository to either filter them out or wrongly
> >expose them to the user. And we're not just talking about other RA
> >modules; we're talking about all future applications that will use
> >libsvn_fs! This is totally unacceptable, IMHO.
> >
> >But notice that Greg Stein has already solved a similar problem.
> >mod_dav_svn needs to track temporary URLs that that represent fs
> >transactions -- and it's doing this by dumping tables to a private dbm
> >file in the repository dir (using APR dbm routines.)
> >
> >Therefore, I say that all of the server-generated "DAV:" props be
> >stored in the same way -- in a private dbm file. It keeps the
> >repository pristine, and is perfectly consistent with the way we solve
> >this problem on the client-side.
> >
> >Feedback? Let me hear some +1's. :-)
> >
> +1, absolutely. I think it's the only sane thing to do.
>
> I have one question, though: Why does mod_dav_svn use another dbm to store the
> props, if we already use Berkeley DB? Wouldn't it be better to just create a
> DB3 environment in .../dav, parallel to .../db?
>
> I have no idea how these DAV-specific props work, but I understand their
> number (and the number of activities) grows proportionally to the number of
> live clients (and/or repository size?), so using a flat dbm file doesn't scale
> well.
>
>
>
> And since we're talking about property policy: in another message you
> mentioned the commit timestamp property. This is clearly a property users have
> to see (it's not ra-layer specific), but I think users shouldn't be able to
> modify it. I think we need a new class of read-only properties. I think these
> will always be properties that are generated by the server. Commit timestamp
> is one, committer ID is another, also (I think) the repository revisioin
> number that a file revision first appears in (we're generating that, aren't
> we?) .
>
>
> Brane
>
> --
> Brane Čibej
> home: <br...@xbc.nu> http://www.xbc.nu/brane/
> work: <br...@hermes.si> http://www.hermes-softlab.com/
> ACM : <br...@acm.org> http://www.acm.org/
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
> For additional commands, e-mail: dev-help@subversion.tigris.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: property policy.
Posted by Ben Collins-Sussman <su...@collab.net>.
Branko =?ISO-8859-2?Q?=C8ibej?= <br...@xbc.nu> writes:
> Without thinking, I wrote:
>
> > And since we're talking about property policy: in another message you
> > mentioned the commit timestamp property. This is clearly a property
> > users have to see (it's not ra-layer specific), but I think users
> > shouldn't be able to modify it. I think we need a new class of
> > read-only properties. I think these will always be properties that are
> > generated by the server. Commit timestamp is one, committer ID is
> > another, also (I think) the repository revisioin number that a file
> > revision first appears in (we're generating that, aren't we?) .
>
> I think I goofed this one. These props are generated on the server
> during a commit, so there's no way a client can set them. Also, once
> committed, they're cast in stone -- we can't change history in the
> repository.
>
> So there's really no issue here. Correct?
Right now, the only auto-generated properties are *revision* props.
When a transaction is created, an "svn:datestamp" property is attached
to the transaction itself. When the transaction is committed, this
property's value is re-set as a revision property.
AFAIK, we have no way (or plans) to allow the client to modify
revision properties. The client can only set node props -- although I
suppose revision props will be implicitly visible via the "annotate"
and "log" subcommands.
Here are reserved "svn:" props that will probably be attached to
revisions:
* datestamp
* username of committer
* log message
I suppose we could allow 'svnadmin' to change revision props -- say,
if the log message needs tweaking after the fact.
-------------
A separate, but related, thread: remember that we also plan to
auto-generate certain regular node-props eventually, such as (?)
* svn:owner
* svn:posix-access-permissions
* svn:mime-type
...and so on. This needs to be discussed more, as it's on our TODO
list for M3.
In particular, I'm worried about UI issues. A long time ago, we
agreed that it would be good to "hide" node properties from CVS users
who are just migrating to Subversion. That's why the status command,
despite that it has the two letter codes side-by-side, always draws
the second code as " " instead of "_" if no properties are present.
Our thought was: "if the user starts using props, then she'll see
`__' status codes. Otherwise, she'll not be aware of them."
I don't care so much about this goal anymore... but I thought I'd
point out that if we start auto-generating these props, users will see
"__" from the beginning.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: property policy.
Posted by Branko Čibej <br...@xbc.nu>.
Without thinking, I wrote:
> And since we're talking about property policy: in another message you
> mentioned the commit timestamp property. This is clearly a property
> users have to see (it's not ra-layer specific), but I think users
> shouldn't be able to modify it. I think we need a new class of
> read-only properties. I think these will always be properties that are
> generated by the server. Commit timestamp is one, committer ID is
> another, also (I think) the repository revisioin number that a file
> revision first appears in (we're generating that, aren't we?) .
I think I goofed this one. These props are generated on the server
during a commit, so there's no way a client can set them. Also, once
committed, they're cast in stone -- we can't change history in the
repository.
So there's really no issue here. Correct?
Brane
--
Brane �ibej
home: <br...@xbc.nu> http://www.xbc.nu/brane/
work: <br...@hermes.si> http://www.hermes-softlab.com/
ACM : <br...@acm.org> http://www.acm.org/
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: property policy.
Posted by Branko Čibej <br...@xbc.nu>.
Ben Collins-Sussman wrote:
>OK, so I've had a night to sleep on this, and I now have a strong
>opinion on how to deal with DAV props versus 'regular' props.
>
>First, I believe there is fundamental difference between these
>categories. 'Regular' props are the ones the user cares about and
>expects to see and change. Regular props are versioned along with
>file text. Meanwhile, DAV props are necessary bookkeeping for a
>certain network layer. They are *not* versioned, and the user isn't
>interested in them -- they're an implementation detail of one
>particular RA module.
>
>I realize now that this situation has already come up before. ra_dav
>had to store bookkeeping properties on the client-side in order to
>function. Our final solution was *not* to treat these props as normal
>ones, and instead store them in a secret area of the SVN/
>administrative dir (and provide the RA layer special get/set routines
>for them.) This prevents the properties from being versioned & stored
>in the repository, and prevents the user from knowing they even exist.
>
>This was a solution that everybody was satisfied with. It also
>implied a general principle:
>
> RA implementation details should *not* be visible to the user. It
> should be impossible (from the user's point of view) to discern how
> a working copy is accessing a repository.
>
>I believe now that this principle can be extended to the other half of
>the situation we're now in. I say "other half", because now we see
>that the DAV layer wants to store bookkeeping props on the subversion
>*server*.
>
>It's very easy to say: "hey, libsvn_fs has props, WebDAV has props, so
>let's line them up, and use namespaces to sort them out." But this
>violates the principle above. Suddenly, one RA module's
>implementation details are exposed to the whole world. They're
>sitting in the repository -- and now a burden has been placed on
>*every* reader of the repository to either filter them out or wrongly
>expose them to the user. And we're not just talking about other RA
>modules; we're talking about all future applications that will use
>libsvn_fs! This is totally unacceptable, IMHO.
>
>But notice that Greg Stein has already solved a similar problem.
>mod_dav_svn needs to track temporary URLs that that represent fs
>transactions -- and it's doing this by dumping tables to a private dbm
>file in the repository dir (using APR dbm routines.)
>
>Therefore, I say that all of the server-generated "DAV:" props be
>stored in the same way -- in a private dbm file. It keeps the
>repository pristine, and is perfectly consistent with the way we solve
>this problem on the client-side.
>
>Feedback? Let me hear some +1's. :-)
>
+1, absolutely. I think it's the only sane thing to do.
I have one question, though: Why does mod_dav_svn use another dbm to
store the props, if we already use Berkeley DB? Wouldn't it be better to
just create a DB3 environment in .../dav, parallel to .../db?
I have no idea how these DAV-specific props work, but I understand their
number (and the number of activities) grows proportionally to the number
of live clients (and/or repository size?), so using a flat dbm file
doesn't scale well.
And since we're talking about property policy: in another message you
mentioned the commit timestamp property. This is clearly a property
users have to see (it's not ra-layer specific), but I think users
shouldn't be able to modify it. I think we need a new class of read-only
properties. I think these will always be properties that are generated
by the server. Commit timestamp is one, committer ID is another, also (I
think) the repository revisioin number that a file revision first
appears in (we're generating that, aren't we?) .
Brane
--
Brane �ibej
home: <br...@xbc.nu> http://www.xbc.nu/brane/
work: <br...@hermes.si> http://www.hermes-softlab.com/
ACM : <br...@acm.org> http://www.acm.org/
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org