mirror of https://github.com/apache/lucene.git
SOLR-9053: Fix attribution, apply the code refactor part from mdrob's patch
(cherry picked from commit b6f8c65
)
This commit is contained in:
parent
13832b4f85
commit
b6b6d246ae
|
@ -207,7 +207,7 @@ Other Changes
|
||||||
|
|
||||||
* SOLR-9047: zkcli should allow alternative locations for log4j configuration (Gregory Chanan)
|
* SOLR-9047: zkcli should allow alternative locations for log4j configuration (Gregory Chanan)
|
||||||
|
|
||||||
* SOLR-9053: Upgrade commons-fileupload to 1.3.1, fixing a potential vulnerability (Jeff Field, janhoy)
|
* SOLR-9053: Upgrade commons-fileupload to 1.3.1, fixing a potential vulnerability (Jeff Field, Mike Drob via janhoy)
|
||||||
|
|
||||||
* SOLR-9066 Make CountMetric return long instead of double (Kevin Risden)
|
* SOLR-9066 Make CountMetric return long instead of double (Kevin Risden)
|
||||||
|
|
||||||
|
|
|
@ -57,7 +57,6 @@ import org.apache.solr.core.SolrConfig;
|
||||||
import org.apache.solr.core.SolrCore;
|
import org.apache.solr.core.SolrCore;
|
||||||
import org.apache.solr.request.SolrQueryRequest;
|
import org.apache.solr.request.SolrQueryRequest;
|
||||||
import org.apache.solr.request.SolrQueryRequestBase;
|
import org.apache.solr.request.SolrQueryRequestBase;
|
||||||
import org.apache.solr.util.RTimer;
|
|
||||||
import org.apache.solr.util.RTimerTree;
|
import org.apache.solr.util.RTimerTree;
|
||||||
|
|
||||||
import static org.apache.solr.common.params.CommonParams.PATH;
|
import static org.apache.solr.common.params.CommonParams.PATH;
|
||||||
|
@ -564,21 +563,18 @@ public class SolrRequestParsers
|
||||||
upload.setSizeMax( ((long) uploadLimitKB) * 1024L );
|
upload.setSizeMax( ((long) uploadLimitKB) * 1024L );
|
||||||
|
|
||||||
// Parse the request
|
// Parse the request
|
||||||
List items = upload.parseRequest(req);
|
List<FileItem> items = upload.parseRequest(req);
|
||||||
Iterator iter = items.iterator();
|
for (FileItem item : items) {
|
||||||
while (iter.hasNext()) {
|
// If it's a form field, put it in our parameter map
|
||||||
FileItem item = (FileItem) iter.next();
|
if (item.isFormField()) {
|
||||||
|
MultiMapSolrParams.addParam(
|
||||||
// If it's a form field, put it in our parameter map
|
item.getFieldName().trim(),
|
||||||
if (item.isFormField()) {
|
item.getString(), params.getMap() );
|
||||||
MultiMapSolrParams.addParam(
|
}
|
||||||
item.getFieldName().trim(),
|
// Add the stream
|
||||||
item.getString(), params.getMap() );
|
else {
|
||||||
}
|
streams.add( new FileItemContentStream( item ) );
|
||||||
// Add the stream
|
}
|
||||||
else {
|
|
||||||
streams.add( new FileItemContentStream( item ) );
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
return params;
|
return params;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue