Learn how to make the most out of the Dropbox Community here 💙!
Forum Discussion
GabrielSMF
6 years agoNew member | Level 2
OutOfMemoryError uploading large file from API V2 - Java
Hi all,
I'm trying to upload a large file (24gb) from Java using the Droopbox API V2, but I have a Out Of Memory Error.
I'm using the next line to do the upload:
cli.files().uploadBuilder(file_...
Greg-DB
Dropbox Staff
6 years agoThe upload method you're using only officially supports files up to 150 MB. If you need to upload larger files, such as the 24 GB file you mentioned, you'll need to use upload sessions, like you said. You can find an example of doing so in the official Dropbox API v2 Java SDK here:
You can find the documentation for the upload session methods here:
- https://dropbox.github.io/dropbox-sdk-java/api-docs/v3.1.x/com/dropbox/core/v2/files/DbxUserFilesRequests.html#uploadSessionStart--
- https://dropbox.github.io/dropbox-sdk-java/api-docs/v3.1.x/com/dropbox/core/v2/files/DbxUserFilesRequests.html#uploadSessionAppendV2-com.dropbox.core.v2.files.UploadSessionCursor-
- https://dropbox.github.io/dropbox-sdk-java/api-docs/v3.1.x/com/dropbox/core/v2/files/DbxUserFilesRequests.html#uploadSessionFinish-com.dropbox.core.v2.files.UploadSessionCursor-com.dropbox.core.v2.files.CommitInfo-
About Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.5,975 PostsLatest Activity: 5 days ago
If you need more help you can view your support options (expected response time for an email or ticket is 24 hours), or contact us on X or Facebook.
For more info on available support options for your Dropbox plan, see this article.
If you found the answer to your question in this Community thread, please 'like' the post to say thanks and to let us know it was useful!