Discussions

General J2EE: File Upload. Best Practices

  1. File Upload. Best Practices (5 messages)

    Hi,

    What is the best way of doing file uploads to a webserver?
    For example IIS, iPlanet or Apache.

    I know there are many possibilities for example PUT, POST and WebDav. But which one is best for uploading files without having to create a servlet or some other custom code on the webserver?

    Creating a custom servlet seems stupid to me since there is built in functionality in most servers for uploading of files.

    The files that are uploaded can be 1Gb or more.

    Regards,
    MZ

    Threaded Messages (5)

  2. File Upload. Best Practices[ Go to top ]

    Why not FTP? The user can login through the browser...

    ftp://username@servername
  3. File Upload. Best Practices[ Go to top ]

    FTP can not be used for at least two reasons.

    - FTP is insecure. Should be HTTPS.
    - FTP requires more knowledge.
  4. File Upload. Best Practices[ Go to top ]

    PUT is best I guess...
  5. File Upload. Best Practices[ Go to top ]

    Yeah in your case, FTP is not an option.

    I use Jakarta Struts for uploads. It makes uploading easy , by abstracting the muli-part request parsing (FormFile object). Struts has a upload example that comes with it.

    Good Luck with whatever you decide...
  6. File Upload. Best Practices[ Go to top ]

    "The Commons FileUpload package makes it easy to add robust, high-performance, file upload capability to your servlets and web applications." - http://jakarta.apache.org/commons/fileupload/