BDB vs Oracle
695909Apr 13 2009 — edited Apr 22 2009Hello!
I'm new to BDB technology and trying to use it through C++ API. I tried a simple test: create a database with unique u_int64_t key and 64 bit data, then open the DB with AUTOCOMMIT and single-threadedly put there 10K and more of new records. This works MUCH (order of magnitude) slower than an alternative PL/SQL code on Oracle 11G (same Vista machine), which inserts the records into DB with a unique index on number value and with commit after EVERY SINGLE record insert (for me this looks to be identical to BDB AUTOCOMMIT).
BDB only gets close to Oracle when AUTOCOMMIT is turned off and using no transactions (but in this case it doesn't write to disk every put). At the same time if you make commit in Oracle only after inserting all records, it gets twice more faster!
So, the question is: is BDB really a poorer choice than Oracle RDBMS in terms of write performance, especially with ACID requirements??? Or maybe I need some special configuration of environment and memory management?
BTW, when I tried to set-up a large cache in BDB (50M), windows still showed that my test application consumed like 600K of memory... And CPU utilization was about 1-3%, so, probably, there're also problems with I/O... At the same time, Oracle used >300M of memory and 50-70% CPU during test.