2006年5月21日星期日

derby vs hsqldb vs BerkeleyDB

derby vs hsqldb vs BerkeleyDB
i tried derby, hsqldb, Berkeley DB today,. latest version today.
hsqldb:
it's "light". i found the benchmark on the site showing it's the
most fast one. but i think it is because it's in memory feature.
but keep database in memory is a "fool" idea to me: if keep the
data in memory, why still i need a database? a data structure
in a programming language is better.
and when the jvm shutdown not properly the data all LOST!
and i havn't found a Good persistance data structure in hsqldb.
sql script and CSV are found.
so i don't think it's ready to use. unless you can let the data lost
after the application stops.
derby is better.
it has some kind of database file structure.
and no lose of data is found when the jvm stop suddently.
and after a created a index on a lot of data, the "select" speed
became very quick.
and the server mode can accepts multi-clients.
but seems not very stable.
org.apache.derby.client.am.DisconnectException: Execution failed due to a distribution protocol error that caused deallocation of the conversation. A PROTOCOL Data Stream Syntax Error was detected. Reason: 0x2114
BerkeleyDB has some kind of new conception on persistance.
the Java Edition, the persistance directly the java object.
but it's seem to be some kind of O/R Mapping tool, and new
style of code must be applied, it is to say, if you use JE
of BerkeleyDB, you must write your code in BerkeleyDB's way.
you wers stick to it.
XML db is available which i not willing to have a taste yet.
and the BerkeleyDB seems not a pure java db. it more kind to C.
so if i choice a light embedded java database today, i should use derby.
welcome to comments.

-----

没有评论:

博客归档

neoedmund's shared items

我的简介

ZIP Code File