aspose file tools*
The moose likes Web Services and the fly likes Web service response time Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Java » Web Services
Bookmark "Web service response time " Watch "Web service response time " New topic
Author

Web service response time

jo mora
Greenhorn

Joined: Oct 10, 2013
Posts: 2
How can I compute the repsonse time of an extarnel Web service and then use this information in a java application?

thanks.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39575
    
  27
The most basic approach would be to call System.currentTimeMillis() before and after the call to the WS - the difference is the round trip time for the call.


Ping & DNS - updated with new look and Ping home screen widget
surlac surlacovich
Ranch Hand

Joined: Mar 12, 2013
Posts: 296

jo mora wrote:How can I compute the repsonse time of an extarnel Web service...

If the service is synchronous:



Otherwise you need to poll status and calculate estimatedTime when web-service is finished.
jo mora
Greenhorn

Joined: Oct 10, 2013
Posts: 2
Ulf Dittmer wrote:The most basic approach would be to call System.currentTimeMillis() before and after the call to the WS - the difference is the round trip time for the call.


Please can I have an idea about how the call of a WS is done with the java language?
Thanks.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39575
    
  27
That is an entirely different question; please start a new topic for that.

Start by reading the documentation of whichever WS library you're using; or are you saying that you're not using any right now? In that case, start reading the introductory articles on the http://www.coderanch.com/how-to/java/WebServicesFaq.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Web service response time
 
Similar Threads
Everything except....
what is build.xml ?
incrementing log details issue when calling webservice
Communication of servlets in different JVM's
Technologies which have a good scope