javax.faces.FacesException

javax.servlet.ServletException: org.apache.tomcat.util.http.fileupload.FileUploadBase$InvalidContentTypeException: the request doesn't contain a multipart/form-data or multipart/mixed stream, content type header is application/x-www-form-urlencoded;charset=UTF-8

Samebug tips0

We couldn't find tips for this exception.

Don't give up yet. Paste your full stack trace to get a solution.

Solutions on the web10

Stack trace

  • javax.faces.FacesException: javax.servlet.ServletException: org.apache.tomcat.util.http.fileupload.FileUploadBase$InvalidContentTypeException: the request doesn't contain a multipart/form-data or multipart/mixed stream, content type header is application/x-www-form-urlencoded;charset=UTF-8 at org.primefaces.component.fileupload.NativeFileUploadDecoder.decode(NativeFileUploadDecoder.java:44) at org.primefaces.component.fileupload.FileUploadRenderer.decode(FileUploadRenderer.java:44) at javax.faces.component.UIComponentBase.decode(UIComponentBase.java:831) at javax.faces.component.UIInput.decode(UIInput.java:771) at javax.faces.component.UIComponentBase.processDecodes(UIComponentBase.java:1226) at javax.faces.component.UIInput.processDecodes(UIInput.java:676) at org.primefaces.component.api.UIData.process(UIData.java:336) at org.primefaces.component.api.UIData.processChildren(UIData.java:323) at org.primefaces.component.api.UIData.processPhase(UIData.java:285) at org.primefaces.component.api.UIData.processDecodes(UIData.java:245) at javax.faces.component.UIForm.processDecodes(UIForm.java:225) at javax.faces.component.UIComponentBase.processDecodes(UIComponentBase.java:1221) at javax.faces.component.UIComponentBase.processDecodes(UIComponentBase.java:1221) at org.primefaces.component.layout.Layout.processDecodes(Layout.java:226) at javax.faces.component.UIComponentBase.processDecodes(UIComponentBase.java:1221) at javax.faces.component.UIComponentBase.processDecodes(UIComponentBase.java:1221) at javax.faces.component.UIViewRoot.processDecodes(UIViewRoot.java:929) at com.sun.faces.lifecycle.ApplyRequestValuesPhase.execute(ApplyRequestValuesPhase.java:78) at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101) at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:198) at javax.faces.webapp.FacesServlet.service(FacesServlet.java:646) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:291) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:239) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:219) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:106) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:501) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:142) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79) at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:610) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:88) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:516) at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1086) at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:659) at org.apache.coyote.http11.Http11NioProtocol$Http11ConnectionHandler.process(Http11NioProtocol.java:223) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1558) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:1515) at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Unknown Source) Caused by: javax.servlet.ServletException: org.apache.tomcat.util.http.fileupload.FileUploadBase$InvalidContentTypeException: the request doesn't contain a multipart/form-data or multipart/mixed stream, content type header is application/x-www-form-urlencoded;charset=UTF-8 at org.apache.catalina.connector.Request.parseParts(Request.java:2789) at org.apache.catalina.connector.Request.getParts(Request.java:2636) at org.apache.catalina.connector.Request.getPart(Request.java:2813) at org.apache.catalina.connector.RequestFacade.getPart(RequestFacade.java:1089) at org.primefaces.component.fileupload.NativeFileUploadDecoder.decodeSimple(NativeFileUploadDecoder.java:50) at org.primefaces.component.fileupload.NativeFileUploadDecoder.decode(NativeFileUploadDecoder.java:34) ... 42 more

Write tip

You have a different solution? A short tip here would help you and many other users who saw this issue last week.

Users with the same issue

Unknown visitor
Unknown visitorOnce,
Unknown visitor
Unknown visitorOnce,
Unknown visitor
Unknown visitorOnce,
Unknown visitor
Unknown visitorOnce,
Unknown visitor
Unknown visitorOnce,
3 more bugmates