Question about HSQLDB database synchronization

S

sss.zhou

I want to write a java server application. 10G maybe a very large
size for my data, hence I wanted to using HSQLDB as my database. But
my application should be a double hot standby system.
Two same servers should be running on the separate machine at the same
time. So the main problem is data synchronization. If I have enough
time for switch the server, the solution may be easy, but the
requirement is that one server is crashed the other should replace it
for working in several seconds.

The first sign is my head is that I can do it by myself. I could do
it in the following steps:

Project 1: doing it all by my self;
1. In the working server, every INSERT, UPDATE, DELTET and
CREATE SQL sentences, I had written it into a txt file, to avoid the
file became to large, every day generate a file, such as:
..... SQL_20070824.sql, SQL_20070825.SQL ....
2. using linux sync command to sync these files from WORKING
server to BACKUP server, at every day 0:01 the BACKUP server import
the SQL into itself;
3. When the Working server crashed, the BACKUP server imported
the current day SQL immediately (at most cases, one day's data can
import in several seconds.), so the BACKUP server become the WORKING
Server;

After some days, I thought that these working must have been done
by some practiced database or software. So I did some research for
HSQLDB, I found this pages: http://hsqldb.sourceforge.net/web/hsqlDocsFrame.html,
but it didn't introduce some two database synchronization, It was just
data recovery in one database.
So is there a way for HSQLDB to deal with data synchronization? Or
some other soft can solve this problem? Or other free database can (I
know oracle can, but it is too expensive.)?

BTW, I had also using Hibernate in my application, can this solve
my data synchronization problem?
 
T

Thomas Kellerer

I want to write a java server application. 10G maybe a very large
size for my data, hence I wanted to using HSQLDB as my database. But
my application should be a double hot standby system.

With that size you should go for a "real" database. HSQLDB is not really suited
for that job.

PostgreSQL is a very good database, and can easily cope with that volume.

There are several solutions to make Postgres a high availability system.

http://pgpool.projects.postgresql.org/
http://pgcluster.projects.postgresql.org/
http://www.slony.info/

As far as I know Slony is bundled with the installers.


MySQL would be another choice to handle the data volumen. It is not as feature
rich as PostgreSQL but offers replication out of the box (although I don't know
if this is true with the non-commercial license)


Finally there are tools like Sequoia which claim to make any group of DBMS a HA
environment.

http://sequoia.continuent.org/

Thomas
 
S

sss.zhou

(e-mail address removed) wrote on 24.08.2007 15:11:


With that size you should go for a "real" database. HSQLDB is not really suited
for that job.

First thanks for you replying.
The other reason I choice HSQLDB because it can run as all in memory
and In-process model, the response time of my application is very
important, some requests must be response within 50ms.

The HSQLDB is a light-level database(If my opinion is wrong, corrected
me) and I just want a light level database.

I will also do some research for PostgreSQL with you helpful guide.
 
T

Thomas Kellerer

First thanks for you replying.
The other reason I choice HSQLDB because it can run as all in memory
and In-process model, the response time of my application is very
important, some requests must be response within 50ms.
And how do you plan to keep 10GB of data /in-memory/?

Thomas
 
S

sss.zhou

(e-mail address removed) wrote on 24.08.2007 17:31:> First thanks for you replying.

And how do you plan to keep 10GB of data /in-memory/?

Thomas

10GB data contained 80% log data and these data needn't be loaded to
memory and every server has 8GB memory and I can using 6GB for my
server application and it is enough for 2GB data.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,995
Messages
2,570,230
Members
46,817
Latest member
DicWeils

Latest Threads

Top