The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

    ObjStore::HV::Database - a generic hash-oriented database

SYNOPSIS

  package MyDatabase;
  use base 'ObjStore::HV::Database';

  my $db = MyDatabase->new("/path/to/my/database", 'update', 0666);

DESCRIPTION

Often you want to treat a database as a hash of related information. Roots could be used, but there are a number of reasons to use this class instead of roots:

  • PERFORMANCE

    You have no control over the implementation of roots. Performance is unknown and cannot be improved or degraded. (The "do it yourself" principle.)

  • FLEXIBILITY

    If you want to move the top-level hash down to a deeper level, you cannot easily do this with roots. (Principle of consistany.)

  • NON-STANDARD

    The standard way to create hash-oriented databases is with ObjStore::HV::Database. (Proof by paradox.)

SEE ALSO

ObjStore::ServerDB