Object Upload Overview
If you have any questions during development, post them on the Issues page of GitHub. For details about parameters and usage of each API, see the .
In OBS, objects are basic data units that users can perform operations on. OBS Android SDK provides abundant APIs for object upload in the following methods:
- Performing a Streaming Upload
- Performing a File-Based Upload
- Performing a Multipart Upload
- Performing an Appendable Upload
- Performing a Resumable Upload
- Performing a Browser-Based Upload
The SDK supports the upload of objects whose size ranges from 0 KB to 5 GB. For streaming upload, appendable upload, and file-based upload, data to be uploaded cannot be larger than 5 GB. If the file is larger than 5 GB, multipart upload (whose part size is smaller than 5 GB) is suitable. Browser-based upload allows files to be uploaded through a browser.
If you grant anonymous users the read permission for an object during the upload, anonymous users can access the object through a URL after the upload is complete. The object URL is in the format of https://bucket name.domain name/directory levels/object name. If the object resides in the root directory of a bucket, its URL does not contain directory levels.
In the following codes, "bucketname" indicates the name of the bucket to which the object is to be uploaded. "objectname" is the name of the target object that is expected to be generated in the bucket after the upload. The directory levels can be specified, for example, src/src1/src2/test.txt. If no directory level is specified, the object is uploaded to the root directory of the bucket.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.