users@jersey.java.net

[Jersey] Re: Jersey client concurrency question

From: cowwoc <cowwoc_at_bbs.darktech.org>
Date: Tue, 11 Feb 2014 18:21:43 -0500

Are you using JerseyTest at all? Or an external test server?

Gili

On 11/02/2014 6:05 PM, Jeff wrote:
> I'm fairly new to Jersey and am trying to create a simple test using
> the Jersey client (v2.5.1) to send concurrent requests to the server.
>
> I'm using TestNG to drive the test with a threadpoolsize of 30 and an
> invocationcount of 1000. The test is a single test method that makes
> a RESTful POST request and sends a JSON file that is around 106,000 bytes.
>
> When I run it, it sends about 150 requests, then seems to stall out
> for 3 to 10 seconds, then it will send another batch and stall again.
>
> I've tried sharing a single JerseyClient instance across all threads
> as well as creating one JerseyClient instance per thread. I suspect
> server issues handling the requests, but I can't see any errors on the
> server side and memory/cpu utilization on the server is minimal.
>
> Are there any concurrency considerations/settings I should look at on
> the client side?
>
> Is there a way to narrow down where it might be getting hung up?
>
> Thanks in advance!
>
> --
> Jeff Vincent
> See my LinkedIn profile at:
> http://www.linkedin.com/in/rjeffreyvincent