List:MySQL and Java« Previous MessageNext Message »
From:Shankar Unni Date:February 7 2003 10:50pm
Subject:RE: JDBC Interface for Embedded Server ?
View as plain text  
Nigel Wetters writes:

> slarty2 probably had the right idea when he suggested that
> to be any faster, a lot of the driver should be written 
> in C, whereas my efforts were a very thin layer of C with 
> a thick layer of java.

The main key is to stay out of the JNI *interface* as much as possible.
JNI is fairly inefficient - the stepping between C and Java is a fairly
heavyweight operation.

If it's possible to structure the driver such that lightweight calls
(e.g. ResultSet.next(), ResultSet.get*(), etc.,) are all in pure Java,
and you only go to C for the actual execute() or other calls that need
to talk to the DB, you might be in good shape.

It'll be interesting to see what performance improvement you get..
--
Shankar.

Thread
Re: JDBC Interface for Embedded Server ?Nigel Wetters6 Feb
  • RE: JDBC Interface for Embedded Server ?Shankar Unni7 Feb
    • Re: JDBC Interface for Embedded Server ?Mark Matthews9 Feb
    • Blobs and SQL LocatorJonathan Baxter9 Feb
      • Re: Blobs and SQL LocatorMark Matthews11 Feb
        • Re: Blobs and SQL LocatorJonathan Baxter11 Feb
  • RE: JDBC Interface for Embedded Server ?Peter Schäfer8 Feb