Java Stored Procedure: Response Time? 
Author Message
 Java Stored Procedure: Response Time?

Hi,

the result of a first test on our (big and very fast and not yet in
production - so almost no CPU load) AS/400 system was that the overhead for
starting a Java Stored Procedure was more than 3 seconds. The procedure did
only return a constant return value and used no other libraries / Java
packages.

It looks like the JVM is started first for each call of the stored
procedure. What would be a typical response time for a Java Stored Procedure
on DB2 for other platforms?

Of course, i will check what optimizations are possible. But i followed the
Redbook for Advanced Database Programming very closely. Maybe there is a
problem in the generation of the native program, which has to be solved
first. I run the AS/400 optimizer (CRTJVAPGM) and there was no effect for
the response time.

The same question was already posted in the AS/400 newsgroup but i did not
yet see any answers (since thursday).

It would be very helpful to know if DB2 can pre-start the JVM to improve the
response time for Java Stored Procedures.

Many thanks in advance,
Michael Justin



Wed, 30 Apr 2003 03:00:00 GMT
 Java Stored Procedure: Response Time?

Michael,

The answer (as far as I remember) is yes, the JVM, and the loading of
the stored procedure can be done in advance.

I don't remember the parameter, but it *WAS* discussed at the DB2 tech
conference a couple of weeks ago...

I'll email a friend and get what I can from him (he's a Stored Procedure
Builder guy from Silicon Labs) and forward it to you.  Is

Mairhtin O'Feannag
San Francisco, Ca.



Quote:
> Hi,

> the result of a first test on our (big and very fast and not yet in
> production - so almost no CPU load) AS/400 system was that the
overhead for
> starting a Java Stored Procedure was more than 3 seconds. The
procedure did
> only return a constant return value and used no other libraries / Java
> packages.

> It looks like the JVM is started first for each call of the stored
> procedure. What would be a typical response time for a Java Stored
Procedure
> on DB2 for other platforms?

> Of course, i will check what optimizations are possible. But i
followed the
> Redbook for Advanced Database Programming very closely. Maybe there is
a
> problem in the generation of the native program, which has to be
solved
> first. I run the AS/400 optimizer (CRTJVAPGM) and there was no effect
for
> the response time.

> The same question was already posted in the AS/400 newsgroup but i did
not
> yet see any answers (since thursday).

> It would be very helpful to know if DB2 can pre-start the JVM to
improve the
> response time for Java Stored Procedures.

> Many thanks in advance,
> Michael Justin

Sent via Deja.com http://www.deja.com/
Before you buy.


Fri, 02 May 2003 03:00:00 GMT
 Java Stored Procedure: Response Time?
Michael...

This is the reply I got :

By default, the DB2 variable KEEPDARI is set to YES, so the JVM should
stay
loaded.
To verify:
- Start Control Center
- Select the instance folder (ex., HOSTNAME -> DB2), and with the right
mouse button
  select the "Configure" menuitem.
- Click the Applications tab of the ensuing notebook.  Scroll in the
table
for keepdari.
  The value should be 1 (Yes).

If you need to change it, you can do so from the Control Center.  But
you
must Stop and
restart the database to have the change take effect.



Quote:
> Hi,

> the result of a first test on our (big and very fast and not yet in
> production - so almost no CPU load) AS/400 system was that the
overhead for
> starting a Java Stored Procedure was more than 3 seconds. The
procedure did
> only return a constant return value and used no other libraries / Java
> packages.

> It looks like the JVM is started first for each call of the stored
> procedure. What would be a typical response time for a Java Stored
Procedure
> on DB2 for other platforms?

> Of course, i will check what optimizations are possible. But i
followed the
> Redbook for Advanced Database Programming very closely. Maybe there is
a
> problem in the generation of the native program, which has to be
solved
> first. I run the AS/400 optimizer (CRTJVAPGM) and there was no effect
for
> the response time.

> The same question was already posted in the AS/400 newsgroup but i did
not
> yet see any answers (since thursday).

> It would be very helpful to know if DB2 can pre-start the JVM to
improve the
> response time for Java Stored Procedures.

> Many thanks in advance,
> Michael Justin

Sent via Deja.com http://www.deja.com/
Before you buy.


Fri, 02 May 2003 03:00:00 GMT
 
 [ 3 post ] 

 Relevant Pages 

1. Calling a Java Stored Procedure from another Java Stored Stored Procedure

2. Gettting SQL0751N trying to call java stored procedure from a java stored procedure

3. Run Time exception in Java Stored Procedure

4. Calling Java Stored Procedure from SQL Stored Procedure

5. Calling Java code on disc from a Java Stored Procedure

6. application response is disabled with long running queries and stored procedures

7. vb freeze and have no response after calling sybase stored procedure

8. How to keep a reasonable response time when a time-consuming SQL statement running

9. Response time increase over time

10. Optimizing Cognos Cube build time and response time

11. External Procedure or Java Stored Procedure

12. Debugging Java Stored Procs in Stored Procedure Builder


 
Powered by phpBB® Forum Software