http 参数 MAX_COUNT wildfly 的默认值是多少?

pre*_*rem 4 jboss wildfly-8

我们已将 jboss 升级到 wildfly,在旧版本中,我们面临一些问题,例如帖子中传递的最大参数数

在旧版本的 jboss 中,我们收到此错误消息

2015-02-10 20:04:34,582 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[default-host].[/sf].[action]] (http--
    127.0.0.1-8080-38) Servlet.service() for servlet action threw exception: java.lang.IllegalStateException: More than the 
    maximum number of request parameters (GET plus POST) for a single request ([5,000]) were detected. Any parameters beyond
     this limit have been ignored. To change this limit, set the maxParameterCount attribute on the Connector.
    at org.apache.tomcat.util.http.Parameters.addParameter(Parameters.java:199) [jbossweb-7.0.13.Final.jar:]
    at org.apache.tomcat.util.http.Parameters.processParameters(Parameters.java:382) [jbossweb-7.0.13.Final.jar:]
    at org.apache.tomcat.util.http.Parameters.processParameters(Parameters.java:229) [jbossweb-7.0.13.Final.jar:]
    at org.apache.catalina.connector.Request.parseParameters(Request.java:2874) [jbossweb-7.0.13.Final.jar:]
    at org.apache.catalina.connector.Request.getParameterNames(Request.java:1333) [jbossweb-7.0.13.Final.jar:]
    at org.apache.catalina.connector.RequestFacade.getParameterNames(RequestFacade.java:379) [jbossweb-7.0.13.Final.jar:]
    at org.apache.struts.util.RequestUtils.populate(RequestUtils.java:1225) [struts.jar:1.1]
Run Code Online (Sandbox Code Playgroud)

现在为了验证这个问题,我们想知道 http 参数 MAX_COUNT 的默认值是多少。

在谷歌搜索中,我发现这个讨论没有提供太多信息,关于它是如何修复的 http://lists.jboss.org/pipermail/undertow-dev/2013-April/000287.html

pre*_*rem 8

max parameter count的默认值为“ 1000 ”,如果要修改它

在wildfly 中,我们必须在http-listener 中使用“max-parameters”属性。

<http-listener name="default" socket-binding="http" max-parameters="10000"/>
Run Code Online (Sandbox Code Playgroud)

有关文档,请参阅此处

在 7.x 版本中,您可以通过以下更改进行修复

org.apache.tomcat.util.http.Parameters.MAX_COUNT=10000
Run Code Online (Sandbox Code Playgroud)

对于此处讨论的旧版 jboss 最大参数计数