Next: , Up: Tutorial


2.1 Preliminaries

Elephant is a Common Lisp OODB. It provides a partial solution to the problem of making Lisp data persistent. It does this through two mechanisms: a simple API for storing and retrieving lisp values from a persistent store, and the ability to make CLOS class slot values be persistent.

When someone says "database," most people think of SQL Relation Data Base Management Systems (e.g. Oracle, Postgresql, MySql). Elephant can use either RDBMSs or Berkeley DB (Sleepycat) as a backend repository, but relies on LISP as its data manipulation system. Unlike systems such as Hibernate for Java, the user does not need to construct or worry about a mapping from the object space into the database. Elephant is designed to be a simple and convenient tool for the programmer.

Elephant supports easy migration of data between different repositories and different backends, allowing the user to choose which repository backend they will use at a particular point in time.

Berkeley DB/Sleepycat is a database library that was the initial inspiration for Elephant's design and is well-matched to Elephant's data model. BDB is implemented as a C library, not a client/server model, so access can be very fast. Berkeley DB is also quite mature, robust and has many features, such as transactions and replication. While we hope that you won't need to understand a specific backend to use Elephant, reading the docs will certainly help you when things go wrong. For the Sleepycat backend, they can be found at http://www.sleepycat.com.

Elephant can also use RDBMS backends via the excellent CL-SQL package. It has been tested with Postgres and SQLite3, and can probably easily work with others.