Update of /project/elephant/cvsroot/elephant/doc In directory common-lisp.net:/tmp/cvs-serv32717/doc
Modified Files: Tag: SQL-BACK-END sql-backend.texinfo Log Message: Dan Knapp's patch applied, and other changes in preparation for 0.3 release.
Date: Wed Nov 23 04:42:14 2005 Author: rread
Index: elephant/doc/sql-backend.texinfo diff -u elephant/doc/sql-backend.texinfo:1.1.2.1 elephant/doc/sql-backend.texinfo:1.1.2.2 --- elephant/doc/sql-backend.texinfo:1.1.2.1 Tue Oct 18 22:35:48 2005 +++ elephant/doc/sql-backend.texinfo Wed Nov 23 04:42:14 2005 @@ -31,12 +31,12 @@ http://www.sleepycat.com/download/licensinginfo.shtml#redistribute unless one releases the entire web application as open source.
-The PostGres DBMS has no such restriction. Elephant itself is released +Neither the PostGres DBMS nor SQLite 3 has any such restriction. Elephant itself is released under the GPL. It is somewhat debatable if the GPL allows one to construct to construct a non-open-source web application but the preponderance of opinion appears to be that it does. Thefore using Elephant and the other GPLed software that it depends upon allows one to host a a non open-source -web application. This might be a reason to use Elephant on PostGres rather +web application. This might be a reason to use Elephant on PostGres of SQLite rather than Elephant on BerkeleyDB.
Other reasons to use a relational database system might include: @@ -59,6 +59,9 @@ is employed, the byte-string is base64 encoded, and placed in a single table which is managed by Elephant.
+As of Elephant 0.3, Elephant has been tested to work with both Postgres, and +SQLite 3, thanks do Dan Knapp. + @node Extention Status @comment node-name, next, previous, up @section Extention Status @@ -108,12 +111,17 @@ @lisp (asdf:operate 'asdf:load-op :elephant) @end lisp -to load elephant, one must execute either or both of: +to load elephant, one must at least one of: @lisp (asdf:operate 'asdf:load-op :ele-clsql) (asdf:operate 'asdf:load-op :ele-bdb) @end lisp
+To use SQLLite3, you must execute: +@lisp +(asdf:operate 'asdf:load-op :ele-sqlite3) +@end lisp + depending on whether or not you wish to use the clsql backend or the BerkeleyDB backend, or both.
@@ -133,7 +141,7 @@
Without modifcation, Elephant uses this as it's lib path: @lisp -/usr/local/share/common-lisp/elephant-0.2/ +/usr/local/share/common-lisp/elephant-0.3/ @end lisp
So you could put a symbolic link to libpq.so there, where libmemutil.so and @@ -155,7 +163,7 @@ ELE-TESTS> *testdb-path* "/home/read/projects/elephant/elephant/tests/testdb/" ELE-TESTS> *testpg-path* -("localhost.localdomain" "test" "postgres" "") +(:postgresql "localhost.localdomain" "test" "postgres" "") ELE-TESTS> @end lisp
@@ -191,7 +199,7 @@
@lisp (defvar *testpg-path* -'("localhost.localdomain" "test" "postgres" "")) +'(:postgreql "localhost.localdomain" "test" "postgres" "")) @end lisp
meaning that connections must be allowed to the database test, user ``postgres'', @@ -254,7 +262,29 @@ At present the system has only been tested under PostGres. Some code parametrization would be required to work with other databases.
+Setting up SQLite3 is even easier. Install SQLite3 (I had to use +the source rather than the binary install, in order to get the dynamic +libraries constructed.) + +An example use of SQLLite3 would be: +@lisp +(asdf:operate 'asdf:load-op :elephant) +(asdf:operate 'asdf:load-op :ele-clsql) +(asdf:operate 'asdf:load-op :ele-sqlite3) +(in-package "ELEPHANT-TESTS") +(setq *test-path-primary* '(:sqlite3 "testdb")) +(do-all-tests-spec *test-path-primary*) +@end lisp + +The file RUNTESTS.lisp, although possibly not exactly what you want, +contains useful example code. + +You can of course migrate between the three currently supported repository +strategies in any combination: BDB, Postgresql, and SQLite3.
+In all probability, other relational datbases would be very easy to +support but have not yet been tested. The basic pattern of +the ``path'' specifiers is (cons clsqal-database-type-symbol (normal-clsql-connection-specifier)).
@node Repository Migration @comment node-name, next, previous, up