Multi upload in Android SDK.

Comments

4 comments

  • Avatar
    Richard Gieg

    Uploading multiple images is not directly supported by our SDK at the moment. Supporting such a workflow can be done by using multithreading, initiating an upload request for every thread separately.


    Note that in the event of a failure an exception will occur. These can be debugged based on the error message that is sent along with the exception.

    1
    Comment actions Permalink
  • Avatar
    Ederson Mendes

    Ok, I was really thinking about using multithread.

     

    Another question: I don't really understand how the upload is made, I mean, when I call "cloudinary.uploader().upload(file, options);" he does the uploads asyncronally, ok? But I don't control this upload at all, so how can I get a exception in case of failure? In what moment this exception is throwed?

    0
    Comment actions Permalink
  • Avatar
    Richard Gieg

    When calling the upload method, it will return the result as soon as it has completed. If an exception occurs while the method is running, it can be caught by your code. Please see the following page for some examples of handling exceptions when calling the Cloudinary Java SDK methods:

    https://github.com/cloudinary/cloudinary_java/blob/master/cloudinary-android-test/src/main/java/com/cloudinary/test/UploaderTest.java

    1
    Comment actions Permalink
  • Avatar
    Ederson Mendes

    Thanks for reply.

    0
    Comment actions Permalink

Please sign in to leave a comment.