[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Simple Object Relational Database? Ruby db40

Casimir

6/3/2008 6:59:00 PM

I have built a *simple* object store that runs on the local filesystem.

Object serialization (marshaling) and restoring details are pseudo
automagical, serialized objects saved as binary object strings in text-
files. A label is generated for indexing and metainformation.

You can save, search for words in label fields, and restore objects.

I implemented it by making all storable objects inherit from the storable-
superclass. Least effort -principle. Far from a database.

Serialized objects are all stored in the same directory. After a few more
thousand files I suppose directory size limits performance. And what
about the relationships between the objects?

I want to learn more.

What laws dictate performance? How should filesystem<->objects -mapping
work? In effect, what kind of hierarchy and naming should, in your
opinion, be used?

I realize its not that simple but where should I look for answers after I
find the questions?

Casimir
2 Answers

David Masover

6/3/2008 8:00:00 PM

0

On Tuesday 03 June 2008 13:59:20 Casimir wrote:
> Serialized objects are all stored in the same directory. After a few more
> thousand files I suppose directory size limits performance.

A good filesystem makes this a moot point, unless you are deliberately looping
through all of them. Even ext3 can be tuned for very large directories.

Use the filesystem structure that makes life easiest for you, and then figure
out what filesystem performs best under it.

ara.t.howard

6/3/2008 8:13:00 PM

0


On Jun 3, 2008, at 12:59 PM, Casimir wrote:

> I realize its not that simple but where should I look for answers
> after I
> find the questions?

are you aware of fsdb? it sounds remarkably like your project and is
quite mature...

a @ http://codeforp...
--
we can deny everything, except that we have the possibility of being
better. simply reflect on that.
h.h. the 14th dalai lama