This server will be upgraded at 3pm Sydney time on December 3rd (December 2nd, 8pm PST) and will be down for up to 30 minutes.

Multiple Attachments Upload Client

I tried to create a utility that could upload multiple files in a batch as we have a lot of files that need to go into Confluence. I can see from various discussions that a lot of other users require this as well and it would be nice to have this possible through the remote API.

This is a java swing client that can upload multiple file attachments into Confluence using the Apache Commons HttpClient. It is a bit of a hack and involves logging in to Confluence and establishing an HTTP session then making the right kind of multi-part HTTP POSTS.

You may also want to check out the Confluence File Uploader which does a similar job!
There are currently no attachments on this page.

Labels

client client Delete
plugin plugin Delete
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.
  1. Mar 22, 2005

    Madhusudan GR says:

    This would be really neat. Please let me know when you are done with this. We ha...

    This would be really neat. Please let me know when you are done with this. We have many documents that we would like to upload at one time to the Confluence page. Its tiresome to do it now.

  2. May 09, 2005

    Bharat Philiph-Patel says:

    A co-worker of mine (Jeff P - who fixed the extra bytes issue) and I have made s...

    A co-worker of mine (Jeff P - who fixed the extra bytes issue) and I have made some changes (made the UI pretty) to the file and make some UI advancements. Please download the file, unzip to a separate directory, and run the attached batch file. That will launch the UI!

    The attached file is cUploadv1.0.zip

    Thanks
    Bharat

    1. May 10, 2005

      Peter Thomas says:

      This is awesome, thanks Jeff & Bharat! Can't wait to see the updated code, ...

      This is awesome, thanks Jeff & Bharat!

      Can't wait to see the updated code, I looked for the source in the zip file maybe I missed it - would it be possible for you to attach that also?

      Regards,

      Peter.

  3. May 11, 2005

    Jeff Pierce says:

    The change to get the upload working was to remove the extra CRLF that sendEndOf...

    The change to get the upload working was to remove the extra CRLF that sendEndOfHeader in org.apache.commons.httpclient.methods.multipart.Part class was adding. I have not had a chance to followup with the HttpClient folks to see if this is a possible bug. It could be a bug on the WebWorks side on the receiving end. I believe that is what Confluence uses. I did a short dig into the HTTP spec but didn't come away with an answer.

    Another change made was to use the ContentTypeFilePart for each file upload. This class sets the correct MIME type on the file and Confluence handles it better. This is from the org.apache.commons.httpclient.contrib.methods.multipart package.

  4. Jun 27, 2005

    Amrit Lalli says:

    We were trying to use this tool, and when we tried to upload it had a 404 error ...

    We were trying to use this tool, and when we tried to upload it had a 404 error (page not found).

    When we tried it with a url that was a port 8080 page (localhost:8080), it barfed.

    • I noticed it was last edited on May 11th, 2005. Does anyone know if this tool still works with the last confluence 1.4 release?
    • I noticed that the source code wasnt provided. Would you be able to provide it?
    • Does this tool handle urls with ports added to them (localhost:8080/confluence) ?

    Please let me know. Thanks

  5. Feb 09, 2006

    ballico_stretch says:

    What paths do you install these file?  Failed at: /lib/commons-logging.j...

    What paths do you install these file?

     Failed at:

    /lib/commons-logging.jarfile

    /lib/commons-httpclient-3.0-rc1.jarfile

    /lib/commons-logging.jar

    /pluggins/attachments/java/FileUploadClient.java

    thanks,

    Stretch 

     

    1. Feb 09, 2006

      Bob Swift says:

      Use the Confluence File uploader instead. See top of page for link.

      Use the Confluence File uploader instead. See top of page for link.