You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by Alejandro Forero Cuervo <az...@bachue.com> on 2004/12/21 23:04:18 UTC

Storing lots of content in properties

Hello.

I'm  making  a wiki  application  which  stores everything  in  a
Subversion  repository  (calling   libsvn  directly).   Thus,  my
application  gets access  to  all the  functionality provided  by
Subversion and also  allows certain users to  checkout the entire
website  and  edit  it  directly  rather  than  through  the  web
interface.

I'm trying to implement each  of the standard features associated
with wiki  systems using the appropriate  Subversion features.  I
am using properties for many things.

I  recently decided  it  was  time to  implement  a "Talk"  page.
Basically, for  each file in my  repository, I want to  create an
associated file  in which users  can discuss the contents  of the
original file.  However, I would like some input on what would be
the correct way to implement this.

I'm thinking of storing the  entire content for the discuss files
as a property (say "svnwiki:discuss")  of their original file.  I
like this metaphor better than other options I have considered.

However, I'm not entirely sure Subversion is designed to properly
handle properties  having long  values (probably longer  than the
files'  contents, in  some  cases).   I'm I  likely  to run  into
problems if I use properties to store this information?  Also, is
there a way to  create a diff of the contents  of a property over
different revisions?

Thank you for your input.

Alejo.
http://bachue.com/alejo

Ps: Another  option  would  be   to  pick  some  standard  naming
mechanism  for the  discuss files.   For example,  for each  file
named  /somefile/,  I  could  name  its  discuss  page  something
like  /x-somefile/.  This  could lead  to some  name clashes  and
doesn't  convince  me.   Also,  unlike the  other  mechanism,  it
would allow  discussion pages to  have discussion pages  (such as
/x-x-x-x-somefile/).

Psps: If you  are curious, you  can read more about  and download
svnwiki at:

    http://cgi.afc.no-ip.info/svnwiki.cgi/default/svnwiki

---=(  Comunidad de Usuarios de Software Libre en Colombia  )=---
---=(  http://bachue.com/colibri )=--=( colibri@bachue.com  )=---

Re: Storing lots of content in properties

Posted by Alejandro Forero Cuervo <ba...@bachue.com>.
> Why not just keep two parallel trees, one mirroring the other?  One
> tree is the content, the other is the discuss files?
> 
> Or: pick one special name, say "x-discuss", as a subdir in each
> directory, and store the discuss files in there, with the same names
> as their corresponding files in the parent directory.

I suppose I'll follow the second option.  It probably minimizes the
chances of path collisions while keeping related files close in the
tree.

Thanks for the suggestions! :)

Alejo.
http://bachue.com/alejo

---=(  Comunidad de Usuarios de Software Libre en Colombia  )=---
---=(  http://bachue.com/colibri )=--=( colibri@bachue.com  )=---

Re: Storing lots of content in properties

Posted by kf...@collab.net.
Alejandro Forero Cuervo <az...@bachue.com> writes:
> However, I'm not entirely sure Subversion is designed to properly
> handle properties  having long  values (probably longer  than the
> files'  contents, in  some  cases).   I'm I  likely  to run  into
> problems if I use properties to store this information?  Also, is
> there a way to  create a diff of the contents  of a property over
> different revisions?

You are right to worry.  Subversion properties are not stored very
efficiently, and you probably don't want them to be large -- certainly
not larger than the file's contents.

By the way, could you turn off the right-justification option in your
mailer?  It makes your mail very hard to read (for me at least, I
suspect also for others).  Thanks.

> Ps: Another  option  would  be   to  pick  some  standard  naming
> mechanism  for the  discuss files.   For example,  for each  file
> named  /somefile/,  I  could  name  its  discuss  page  something
> like  /x-somefile/.  This  could lead  to some  name clashes  and
> doesn't  convince  me.   Also,  unlike the  other  mechanism,  it
> would allow  discussion pages to  have discussion pages  (such as
> /x-x-x-x-somefile/).

Why not just keep two parallel trees, one mirroring the other?  One
tree is the content, the other is the discuss files?

Or: pick one special name, say "x-discuss", as a subdir in each
directory, and store the discuss files in there, with the same names
as their corresponding files in the parent directory.

-Karl

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

Re: Storing lots of content in properties

Posted by Bryan Donlan <bd...@gmail.com>.
On Tue, 21 Dec 2004 18:04:18 -0500, Alejandro Forero Cuervo
<az...@bachue.com> wrote:
> 
> Hello.
> 
> I'm  making  a wiki  application  which  stores everything  in  a
> Subversion  repository  (calling   libsvn  directly).   Thus,  my
> application  gets access  to  all the  functionality provided  by
> Subversion and also  allows certain users to  checkout the entire
> website  and  edit  it  directly  rather  than  through  the  web
> interface.
> 
> I'm trying to implement each  of the standard features associated
> with wiki  systems using the appropriate  Subversion features.  I
> am using properties for many things.
> 
> I  recently decided  it  was  time to  implement  a "Talk"  page.
> Basically, for  each file in my  repository, I want to  create an
> associated file  in which users  can discuss the contents  of the
> original file.  However, I would like some input on what would be
> the correct way to implement this.
> 
> I'm thinking of storing the  entire content for the discuss files
> as a property (say "svnwiki:discuss")  of their original file.  I
> like this metaphor better than other options I have considered.
> 
> However, I'm not entirely sure Subversion is designed to properly
> handle properties  having long  values (probably longer  than the
> files'  contents, in  some  cases).   I'm I  likely  to run  into
> problems if I use properties to store this information?  Also, is
> there a way to  create a diff of the contents  of a property over
> different revisions?
> 
> Thank you for your input.
> 
> Alejo.
> http://bachue.com/alejo
> 
> Ps: Another  option  would  be   to  pick  some  standard  naming
> mechanism  for the  discuss files.   For example,  for each  file
> named  /somefile/,  I  could  name  its  discuss  page  something
> like  /x-somefile/.  This  could lead  to some  name clashes  and
> doesn't  convince  me.   Also,  unlike the  other  mechanism,  it
> would allow  discussion pages to  have discussion pages  (such as
> /x-x-x-x-somefile/).
> 
> Psps: If you  are curious, you  can read more about  and download
> svnwiki at:
> 
>     http://cgi.afc.no-ip.info/svnwiki.cgi/default/svnwiki

I think properties don't use deltas, but I could be wrong. Anyway,
personally, I'd just make talk pages a naming convention at the wiki
level. It's simple to implement, and you get all the history features,
etc, for free.

-- 
bd

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