Skip to content

armgit / solr

Public Imported from GitHub
0

Apache Solr open-source search software

SOLR-4223: "maxFormContentSize" in jetty.xml is not picked up by jetty 8 so set it via solr webapp context file

Shalin Shekhar Mangar6a0f11ebedb3
diff --git a/solr/CHANGES.txt b/solr/CHANGES.txt
index f4b04da227d..3b8093b0caa 100644
--- a/solr/CHANGES.txt
+++ b/solr/CHANGES.txt
@@ -381,6 +381,9 @@ Bug Fixes
* SOLR-4133: Cannot "set" field to null with partial updates when using the
standard RequestWriter. (Will Butler, shalin)
+* SOLR-4223: "maxFormContentSize" in jetty.xml is not picked up by jetty 8
+ so set it via solr webapp context file. (shalin)
+
Other Changes
----------------------
diff --git a/solr/example/contexts/solr.xml b/solr/example/contexts/solr.xml
index 50978a365ff..250a49b4fea 100644
--- a/solr/example/contexts/solr.xml
+++ b/solr/example/contexts/solr.xml
@@ -5,4 +5,6 @@
<Set name="war"><SystemProperty name="jetty.home"/>/webapps/solr.war</Set>
<Set name="defaultsDescriptor"><SystemProperty name="jetty.home"/>/etc/webdefault.xml</Set>
<Set name="tempDirectory"><Property name="jetty.home" default="."/>/solr-webapp</Set>
+ <!-- Increase the maximum POST size to 1 MB to be able to handle large shard requests -->
+ <Set name="maxFormContentSize">1000000</Set>
</Configure>
diff --git a/solr/example/etc/jetty.xml b/solr/example/etc/jetty.xml
index ab84668121a..d158e42e976 100644
--- a/solr/example/etc/jetty.xml
+++ b/solr/example/etc/jetty.xml
@@ -13,11 +13,16 @@
<Configure id="Server" class="org.eclipse.jetty.server.Server">
<!-- Increase the maximum POST size to 1 MB to be able to handle large shard requests -->
+ <!-- allthough documented as the correct way to set the max POST size for
+ all webapps in a single server, this doesn't actaully work.
+ So instead it is set on the WebAppContext.
+ -->
+ <!--
<Call name="setAttribute">
<Arg>org.eclipse.jetty.server.Request.maxFormContentSize</Arg>
- <Arg>200000</Arg>
+ <Arg>1000000</Arg>
</Call>
-
+ -->
<!-- =========================================================== -->
<!-- Server Thread Pool -->
<!-- =========================================================== -->