JBoss Community

Re: Client JBOSS Communication takes long time on threaded remote calls

created by Hardik Shah in Performance Tuning - View the full discussion

Thank you for your response.

 

My client program and jboss resides on the same server, so there should not be any network latency issue.

Below is just to provide the idea about how i execute and calculate my test result.

 

Client Program:

 

LongAttribute nanoTime = new LongAttribute();

nanoTime.setID(54);

nanoTime.setLongValue(System.nanoTime()); //setting the timestamp value on client side.

requestPacket.addAttribute(nanoTime);

 

responsePacket = SessionBeanRemote.onlineService(requestPacket);

 

Server Side:

 

ArrayList<IRatingAttribute> Attribute = requestPacket.getAttribute(CommunicationConstant.RequestPacketAttributes.QUEUE_WAIT.getAttributeId());

 

double waitInQueue = 0;

String sessionID = null;

 

if(Attribute != null && Attribute.size()>0){

          waitInQueue = Math.ceil(((System.nanoTime() - ((LongAttribute)Attribute.get(0)).getLongValue()) / 1000000d));

}

 

if(Logger.isWarnEnabled()) Logger.logWarn(MODULE,"Wait In Que : " + waitInQueue);


Reply to this message by going to Community

Start a new discussion in Performance Tuning at Community