This topic describes the methods for uploading objects using the Object Storage Service (OSS) SDK for Java.
In Object Storage Service (OSS), an object is the basic data unit. The OSS SDK for Java provides the following methods to upload objects:
Simple upload (SDK for Java): You can use the PutObject method to upload a single object. This method supports streaming upload and file upload. The object cannot exceed 5 GB in size.
Form upload (SDK for Java): You can use an HTML form to upload an object to a specified bucket. The object cannot exceed 5 GB in size.
Append upload (SDK for Java): You can use the AppendObject method to append content to an existing appendable object. The object cannot exceed 5 GB in size.
Resumable upload (SDK for Java): You can specify a checkpoint. If an upload fails due to a network error or program crash, the upload can be resumed from the checkpoint. This method supports concurrent upload, resumable upload, and custom part sizes. We recommend that you use this method to upload large files. The object cannot exceed 48.8 TB in size.
Multipart upload: You can divide a large object into multiple parts and upload the parts separately. The object cannot exceed 48.8 TB in size.
Upload an object using a signed URL (SDK for Java): You can use the OSS SDK for Java to generate a signed URL that allows other users to upload an object.
During the upload, you can set object metadata and view the upload progress using the progress bar (SDK for Java) feature. After the upload is complete, you can also perform an upload callback (SDK for Java).