Re: Looking for some design inspiration
Date: 4 Aug 2006 14:29:50 -0700
Message-ID: <1154726990.343131.270980_at_s13g2000cwa.googlegroups.com>
We also implement a number of our own collection classes, but these are
usually to help avoid using too much heap in the virtual machine... for
example a ScalableHashMap in which the table size can be large
(millions) but only a portion of the table needs to be in the Java heap
at any instant in time.
You can find more details about Facets persistent Java and a free
download on our website at http://facetsodb.org.
Bob
exits funnel wrote:
> Hello,
>
> I apologize in advance if this is off-topic but it seems like the sort
> of problem database implementors must have spent a great deal of time
> thinking about.
>
> I'm working on a project for which I've written what is essentially a
> custom collection class - an instance of which is roughly analogous to a
> relational table. The elements of the collection then are rows and the
> collection is divided into logical pages of a fixed (at compile time)
> number of rows. Each page is backed by a number of array instances none
> of which span pages. Up to this point, the collections have existed
> entirely in memory but now the requirement has been added to support
> swapping to disk effectively limiting the amount of RAM allocated to the
> sum of all collections at any given time. I've played around a bit with
> reading/writing blocks of pages to/from disk and this bit seems not to
> difficult a task but I'm in need of some inspiration for the management
> machinery. I imagine a single system wide disk file and writing blocks
> consisting of various pages from different instances of the collection
> but I'm not sure how to track the blocks so that when I need to swap in
> a given page, I can find it efficiently. I'm confident that left to my
> own devices I can craft something which works, but I'm much less
> confident that I can craft something which will perform satisfactorily.
> Can anyone suggest some useful patterns? Or possibly some discussion of
> the solution to a similar problem? I should mention that the
> implementation language is java so java references would be ideal though
> I'd also welcome any pointers to C/C++ references which address the
> topic. Even general ramblings will be appreciated. Thanks in advance
> for any thoughts.
>
> -exits
Received on Fri Aug 04 2006 - 23:29:50 CEST