Increasing Jetty ThreadPool size in Karaf

2019-07-23 05:16发布

Trying to increase the number of threads in embedded jetty running in karaf .Im changing the jetty.xml with the following properties as described in the POST .

<Configure class="org.eclipse.jetty.server.Server">   
  <Call name="addConnector">
    <Arg>
      <New class="org.eclipse.jetty.util.thread.QueuedThreadPool">
        <Set name="minThreads">10</Set>
        <Set name="maxThreads">1000</Set>
      </New>
    </Arg> 
  </Call>
</Configure>

And also having org.ops4j.pax.web.cfg file in karaf ,with below properties :

   org.ops4j.pax.web.config.file=${karaf.home}/jetty.xml

so to refer the external configurations (Jetty). But Im not able to increase/decrease the default thread size of the server . So What am I missing ?

1条回答
放荡不羁爱自由
2楼-- · 2019-07-23 05:50

With the latest Pax-Web 4.2.0 it's possible to configure those settings via configuration admin. The following three new settings can be used:

org.ops4j.pax.web.server.maxThreads
org.ops4j.pax.web.server.minThreads
org.ops4j.pax.web.server.idleTimeout
查看更多
登录 后发表回答