This topic is written for the OSS Java SDK 3.8.0.

Compatibility

  • For SDKs V3. ×. ×:
    • API: compatible
    • Namespace: compatible
  • For SDKs V2. ×. ×:
    • API: compatible
    • Namespace: compatible
  • For SDKs V1.0. ×:
    • API: compatible
    • Namespace: incompatible. The Tablestore code in version 1.0.x is removed from version 2.0.0. The package names com.aliyun.openservices. * and com.aliyun.openservices.oss. * are replaced with com.aliyun.oss. *.

SDK source code and API documents

For the SDK source code, visit GitHub. For more information, visit Aliyun OSS SDK for Java 3.8.0 API.

Sample code

The OSS Java SDK provides a variety of sample code for you to reference or use. The following table describes the sample code provided.

Sample file Content
GetStartedSample.java Quick start
CreateFolderSample.java Create a folder for simple upload
AppendObjectSample.java Append upload
UploadSample.java Resumable upload
MultipartUploadSample.java Multipart upload
GetProgressSample.java Upload progress bars
CallbackSample.java Upload callback
CRCSample.java CRC for object upload
SimpleGetObjectSample.java Download objects
DownloadSample.java Resumable download
ObjectMetaSample.java Manage object metadata
ListObjectsSample.java List objects
UploadPartCopySample.java Copy objects
DeleteObjectsSample.java Delete objects
BucketOperationsSample.java Configure authorized access, lifecycle rules, access logging, hotlink protection, and CORS for a bucket.
ImageSample.java Image processing
PostObjectSample.java Use PostObject in a specified bucket. The implementation is independent of the Java SDK.
ConcurrentGetObjectSample.java Download multiple objects at the same time. We recommend that you use Resumable download.
TrafficLimitSample.java Configure Single-connection bandwidth throttling
SetRequestPaymentSample.java Configure Enable pay-by-requester mode