commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject Problem using commons-fileupload.jar
Date Thu, 08 Jun 2006 08:57:40 GMT


I'm using fileupload, and have this exception :

org.apache.commons.fileupload.FileUploadException: Processing of multipart/form-data request
failed. Stream ended unexpectedly

This is very strange since it works well on my own computer and this exception is catched
when I run my program on an other server.

I don't know wether this information can help, but the server I used (where there is an error)
use a IIS authentification (between client and server
Tomcat 5).

Could you help me ?

Here is my code very simple code :

protected void doPost(HttpServletRequest arg0, HttpServletResponse arg1) throws ServletException,

            this.processRequest(arg0, arg1);

private void processRequest(HttpServletRequest request, HttpServletResponse response) throws
ServletException, IOException

            this.out = response.getWriter();
            boolean isMultipart = FileUpload.isMultipartContent(request);
            if (!isMultipart)
                  this.writeOutput("non MultiPart Message");
            DiskFileUpload fileUpload = new DiskFileUpload();
                  List items = fileUpload.parseRequest(request);
            catch (FileUploadException e)
            catch (NullPointerException e)

The exception seems to be catched at this line : List items = fileUpload.parseRequest(request);

     CONFIDENTIALITE : Ce message et les éventuelles pièces attachées sont
     confidentiels. Si vous n'êtes pas dans la liste des destinataires,
     veuillez informer l'expéditeur immédiatement et ne pas divulguer le
     contenu à une tierce personne, ne pas l'utiliser pour quelque raison
     que ce soit, ne pas stocker ou copier l'information qu'il contient sur
     un quelconque support.

     CONFIDENTIALITY : This  e-mail  and  any attachments are confidential
     and may be privileged. If  you are not a named recipient, please
     notify the sender immediately and do not disclose the contents to
     another person, use it for any purpose or store or copy the
     information in any medium..

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message