users@glassfish.java.net

RE: JMS performance issue - need help

From: Alex Sherwin <alex.sherwin_at_acadiasoft.com>
Date: Wed, 27 Aug 2008 10:47:52 -0400

Where are you getting the timestamp? Maybe you could try timing the code with System.currentTimeMillis() or System.nanoTime() immediately before/after the lookups...




Alex Sherwin
alex.sherwin_at_acadiasoft.com

-----Original Message-----
From: glassfish_at_javadesktop.org [mailto:glassfish_at_javadesktop.org]
Sent: Wednesday, August 27, 2008 8:18 AM
To: users_at_glassfish.dev.java.net
Subject: JMS performance issue - need help

I have a below code, to run this approximately it is taking more than 2 seconds. Please can some one advise what I am doing incorrect here? thanks

try {
cf = (ConnectionFactory) ic.lookup("jms/ConnectionFactory");
pQueue = (Queue) ic.lookup("jms/PhysicalQueueName");

} catch (NamingException e) {
System.err.println("JNDI API lookup failed: " + e.toString());
e.printStackTrace();
System.exit(1);
}

Here is the time stamp for before this code run and after..
Before: 2008-08-27 07:47:50.735
After : 2008-08-27 07:47:52.916

Some times it is taking more than 3 seconds. And this is happening for my each request.
My App server running on local machine.
[Message sent by forum member 'banther' (banther)]

http://forums.java.net/jive/thread.jspa?messageID=295622

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
For additional commands, e-mail: users-help_at_glassfish.dev.java.net