File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Tomcat and the fly likes Web Services on Startup or Publishing issue Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Tomcat
Bookmark "Web Services on Startup or Publishing issue" Watch "Web Services on Startup or Publishing issue" New topic

Web Services on Startup or Publishing issue

Michael Hari

Joined: Apr 07, 2011
Posts: 5
Hi all,

So coming from the Android world and consuming web services, I now have to build them myself.

I'm using Apache Axis to do a bottom up approach from Java Class to Java Bean to WSDL (whatever.... honestly).

I deploy the Web Service onto Tomcat and it runs fine. But now I have to do scalability testing and I'm using Jmeter to accomplish this.

When I first start tomcat OR republish the webservice the following issues happen: (I restart tomcat before every test)

Invoking a method on my Web Service with 50 and 100 concurrent users gets a response back.

But when I test it with 500 and 1000 concurrent users, the first 20 (for 500 users) and first 200-300 (for 1000 users) requests get declined. But here's the thing, I invoke the same method again w/o restarting or republishing my webservice, and I get a response for every request. There is some kind of "warm-up" that tomcat is doing for my webservice the first time its launched.

I've already changed some stuff in server.xml on tomcat:

But the issue still remains. To be perfectly honest, if there were 500+ users invoking a method the first time I start tomcat, and 20-500 get denied, its fine. They can retry again and it works. But I'm curious if this is a normal issue or is there something I can define in these .xml and .wsdd files that can prevent this?

Googling has produced deployOnStart="true" in the server.xml on tomcat and other stuff... but its not working. Anyone have a helpful hint?


I agree. Here's the link:
subject: Web Services on Startup or Publishing issue
jQuery in Action, 3rd edition