db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dag.Wan...@Sun.COM (Dag H. Wanvik)
Subject Re: simpler api to the Derby store
Date Wed, 16 Jul 2008 13:32:48 GMT
Knut Anders Hatlen <Knut.Hatlen@Sun.COM> writes:

> Not an answer to your question, but I performed a small experiment to
> get a feel of how large the overhead imposed by the SQL and JDBC layers
> was for these simple queries. I used the single-record select test in
> org.apache.derbyTesting.perf.clients.Runner, which just performs primary
> key lookups and fetches about 100 bytes of data. When I accessed the
> same table and index directly through the store API (using same
> isolation level, holdability etc), I got about 15% more accesses per
> unit of time than when I accessed them through JDBC.

Interesting experiment. I am not too surprised by the 15% overhead, I
think many people think JDBC using prepared statements is slower than
it actually is in embedded mode, since for many it conjures up images
of networking latency, extra serializing and deserializing. So in some
sense Derby embedded may have an "image problem" since we rely on JDBC

In any case, it might be educational for some of us when we look into
this question if you would be willing to share the experiment code
with the community?  Then maybe others can get a jump start to do more
experiments? Perhaps a JIRA for experiments may be useful and/or the

View raw message