List Info

Thread: mod_dav_svn refactoring proposal




mod_dav_svn refactoring proposal
user name
2006-07-27 22:59:30
I'm taking a look at mod_dav_svn, and realizing that a
*lot* of the code
is focussed on either:

 (a) implementing various mod_dav vtables
 (b) sending a particular kind of custom report


I have an inclination to refactor the source into the
following layout:

subversion/
  mod_dav_svn/
    reports/
      update.c
      log.c
      dated-rev.c
      get-locations.c
      file-revs.c
      get-locks.c
      replay.c
    dav_hooks/
      repository.c
      propdb.c
      liveprop.c
      vsn.c
      locks.c
    <other stuff>

i.e. one file per report, one file per dav_hooks category
vtable.

+1s? -1s? passing comments?

Thanks,
Max.


mod_dav_svn refactoring proposal
user name
2006-07-28 06:41:26
Max Bowsher wrote:
> I'm taking a look at mod_dav_svn, and realizing that a
*lot* of the code
> is focussed on either:
> 
>  (a) implementing various mod_dav vtables
>  (b) sending a particular kind of custom report
> 
> 
> I have an inclination to refactor the source into the
following layout:

Does this inclination stem from a particular problem you ran
into while
trying to modify mod_dav_svn, or are you just in Tidy-up
Mode?

-- 
C. Michael Pilato <cmpilatocollab.net>
CollabNet   <>   www.collab.net   <>  
Distributed Development On Demand
mod_dav_svn refactoring proposal
user name
2006-07-28 08:13:50
On Thu, Jul 27, 2006 at 11:59:30PM +0100, Max Bowsher wrote:
> i.e. one file per report, one file per dav_hooks
category vtable.
> 
> +1s? -1s? passing comments?
> 

Anything you can do to make mod_dav_svn easier to understand
would
be great.  I've always found it rally hard to work out
what's going
on myself.

Regards,
Malcolm

------------------------------------------------------------
---------
To unsubscribe, e-mail: dev-unsubscribesubversion.tigris.org
For additional commands, e-mail: dev-helpsubversion.tigris.org

mod_dav_svn refactoring proposal
user name
2006-07-28 10:09:24
C. Michael Pilato wrote:
> Max Bowsher wrote:
>> I'm taking a look at mod_dav_svn, and realizing
that a *lot* of the code
>> is focussed on either:
>>
>>  (a) implementing various mod_dav vtables
>>  (b) sending a particular kind of custom report
>>
>>
>> I have an inclination to refactor the source into
the following layout:
> 
> Does this inclination stem from a particular problem
you ran into while
> trying to modify mod_dav_svn, or are you just in
Tidy-up Mode?

I've found that some of mod_dav_svn's .c files incorporate
code that has
little to do with the name of the file - i.e. prime
candidates for
splitting chunks of code out into new files.

Rather than pick names for the new files on an ad-hoc basis,
the above
schema would help in selecting new names.

Also, many of the files relate to an mod_dav concept, yet
are named not
after that concept, but after an abbreviation, expansion, or
loosely
related word.

Overall, I'd like the file layout to reflect an overall
logical
structure, so that a newcomer to the code can quickly
understand it, and
then proceed to fill in their knowledge about specific
subtopics, rather
than needing study the entire body of code to understand the
structure
of how the different source files plug together.

Max.

mod_dav_svn refactoring proposal
user name
2006-07-28 10:13:37
Max Bowsher wrote:
> C. Michael Pilato wrote:
> 
>>Max Bowsher wrote:
>>>I have an inclination to refactor the source
into the following layout:
>>
>>Does this inclination stem from a particular problem
you ran into while
>>trying to modify mod_dav_svn, or are you just in
Tidy-up Mode?
> 
> 
> I've found that some of mod_dav_svn's .c files
incorporate code that has
[...]
> of how the different source files plug together.

Translation:  you're in Tidy-up Mode.  

(+1 on improving the structure, though.)

-- 
C. Michael Pilato <cmpilatocollab.net>
CollabNet   <>   www.collab.net   <>  
Distributed Development On Demand
mod_dav_svn refactoring proposal
user name
2006-07-31 10:04:06
On Fri, 28 Jul 2006 15:39:24 +0530, Max Bowsher
<maxb1ukf.net> wrote:

> Max Bowsher wrote:
>
> Overall, I'd like the file layout to reflect an
overall logical
> structure, so that a newcomer to the code can quickly
understand it, and
> then proceed to fill in their knowledge about specific
subtopics, rather
> than needing study the entire body of code to
understand the structure
> of how the different source files plug together.

FWIW, +1.

Regards,
Madan.

------------------------------------------------------------
---------
To unsubscribe, e-mail: dev-unsubscribesubversion.tigris.org
For additional commands, e-mail: dev-helpsubversion.tigris.org

[1-6]

about | contact  Other archives ( Real Estate discussion Medical topics )