Login | Register
My pages Projects Community openCollabNet

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Catacomb] Re: DBMS abstraction



On Fri, Sep 06, 2002 at 09:18:02AM -0700, catacomb-request@webdav.org wrote:
>...
> Date: Fri, 06 Sep 2002 08:32:04 -0700
> From: Chris Knight <cknight@mail.arc.nasa.gov>
>...
> * is there a test suite I can use to make sure my changes don't break 
> things?

Check out: http://www.webdav.org/neon/litmus/

> * I'm a bit rusty on the use of "const", and the dbms_mysql.c gives a 
> warning regarding this...Dunno if that's really much of an issue or not.
> * The dbms struct carries it's own memory pool, should that be a child 
> of another pool?  Given that each query will be generating a fair number 
> of string allocations, should each query have it's own child pool? I'm 
> unclear as to when memory pools are cleaned up, so guidance (or URL's) 
> would be appreciated.

Some ideas on how to best use pools (and mod_dav(_fs) don't follow this
pattern, unfortunately...), see:

  http://svn.collab.net/repos/svn/trunk/HACKING

and search for "APR pool usage conventions". Subversion has some covers for
pool construction/destruction, but the pattern of create/clear/destroy
should be obvious.

I would *highly* recommend using this pattern. Over time, mod_dav itself
will be transitioned to follow the same pattern. It is really the best and
only way to properly and effectively use pools without killing your server
(sometimes in typical cases, but you can also avoid the pathological cases
by following that pattern)

> * coding style/variable naming comments are always appreciated, I can 
> work with whatever style you like. (I often set my tab stops at 4, but 
> I'll try to make sure it looks ok with 8.)

Seeing that you're writing an Apache module, and mod_dav itself follows this
pattern, I would recommend the following:

    http://www.apache.org/dev/styleguide.html

Note that tab *stops* are set at 4 spaces, but tabs are *never* used. Always
use spaces only.

> I plan on being at the interop event Tuesday afternoon and Wednesday, 
> hope to see you there!

I'll be there Monday and probably Wednesday.

Cheers,
-g

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