這是我的servlet配置(web.xml中):
<?xml version="1.0" encoding="ISO-8859-1" ?>
http://java.sun.com/xml/ns/j2ee/web- app_2_4.xsd」 版本= 「2.4」>
<display-name>HelloWorld Application</display-name>
<description>
This is a simple web application with a source code organization
based on the recommendations of the Application Developer's Guide.
</description>
<servlet>
<servlet-name>AnaliseFaturasServlet</servlet-name>
<servlet-class>br.com.dendron.analisefaturas.servlet.AnaliseFaturasServlet</servlet-class>
<load-on-startup>1</load-on-startup>
<multipart-config>
<max-file-size>10485760</max-file-size>
<max-request-size>20971520</max-request-size>
<file-size-threshold>5242880</file-size-threshold>
</multipart-config>
</servlet>
<servlet-mapping>
<servlet-name>AnaliseFaturasServlet</servlet-name>
<url-pattern>/serv</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>AnaliseFaturasServlet</servlet-name>
<url-pattern>/serv/</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>AnaliseFaturasServlet</servlet-name>
<url-pattern>/progress</url-pattern>
</servlet-mapping>
發佈完整的servlet配置。好像你把'multipart-config'標籤放在錯誤的地方 –
事實上,這是對一個非常類似的問題的回答,問題是元素出錯了。該錯誤非常相似,所以@DavidFlorez可能是正確的:https://stackoverflow.com/a/5175139/212224 – Mike