Subject Re: [Firebird-Java] Profiling...
Author Roman Rokytskyy
> I notice when doing many inserts, that the majority of time spent in
> my application is in org.firebirdsql.gds.XdrInputStream.read and
> org.firebirdsql.gds.XdrInputStream.readInt. Even more time is spent
> here than in org.firebirdsql.gds.XdrOutputSTream.write( ... ), which
> seems odd since these are all insert executions with prepared statements.

I cannot tell this with 100% guarantee, but in my test cases it was ok.
Reason is that for each execution wire protocol implementation must read the
response, so called status vector.

But if you wish, you can create a standalone test, I can have a look.

> I am using PreparedStatement#execute. Should I be using
> PreparedStatement#executeUpdate instead? I thought the later would be
> even slower since it needed to lookup the update count.

PreparedStatement#execute is the right approach.

> Those from #execute take even longer than my openOrCreateBlob calls.
> Anything I can do to minimize these reads?

I cannot tell you for sure. You can also try version from HEAD. I have spent
quite some time optimizing the wire protocol there, maybe it is better than
JayBird 1.5.x.

Roman