4 Replies Latest reply on Aug 1, 2017 3:21 AM by nayeem007

    Limit queue size / connection number on Wildfly 8.1

    tigerblue

      Hi.

      We are using Wildfly 8.1 for a client/server application (webservices, servlets).

      Some of the requests on the server can be rather time and resource consuming.

      Therefor we want to limit the maximum number of requests to be served. After that number requests should be denied.

       

      On JBoss5 this was simple with setting maxThreads and especially acceptCount in server.xml.

       

      So the simple question would be: What is equivalent to the JBoss5 option "acceptCount" in Wildfly 8.1?

       

      More complicated / detailed question:

       

      For Wildfly 8.1 and standalone.xml I found the configuration for:

      • the (default) worker with option "task-max-threads"
      • the connection-limit filter in undertow with options "max-concurrent-requests" and "queue-size"

       

      What I didn't find:

      • the option "task-limit" that an xnio worker provides doesn't seem to be enabled on the worker configuration in Wildfly
      • How the above two configuration locations interact

       

      Currently I have set a rather low "queue-size" (ie 40) and "max-concurrent-requests" on the connection-limit filter.

       

      I test this with 300 parallel requests/threads from JMeter which call a very time consuming servlet method (25 second sleep).

       

      The observed behavior: 250 connections are refused (error code 513) - which is ok.

      After that every request seems to be handled in a queue and waiting indefinitely. Ie 6 * 25s.

       

      Which queue might that be?

      Is there any way to influence this on the worker level?