All Products
Search
Document Center

Alibaba Cloud SDK:Upgrade Alibaba Cloud SDK V1.0 to V2.0

Last Updated:Jun 08, 2026

If you are running Alibaba Cloud SDK V1.0, upgrade to V2.0 to get a thread-safe client model, broader language support, and access to the latest API features.

Should I upgrade?

Choose based on your project situation:

  • Simple project, no issues — Stay on V1.0. An upgrade is not necessary if V1.0 meets your needs.

  • Complex project calling multiple cloud services — Upgrade to V2.0. V2.0 provides a thread-safe client model that eliminates concurrency issues common in multi-service V1.0 integrations.

  • New project — Use V2.0 directly.

Compatibility

V2.0 is not backward-compatible with V1.0. The two versions use different package naming conventions and can coexist in the same project, which lets you migrate one service at a time.

Version

Package naming convention

Example (ECS)

Example (VPC)

V2.0

${Service name}${API version number}

com.aliyun:ecs20140526

com.aliyun:vpc20160428

V1.0

aliyun-${Language}-sdk-${Service name}

com.aliyun:aliyun-java-sdk-ecs

com.aliyun:aliyun-java-sdk-vpc

The following Maven configuration shows how to run V1.0 and V2.0 side by side. Both the ECS V2.0 SDK and the V1.0 core and ECS packages are declared as dependencies, so you can migrate one service at a time.

<dependencies>
  <!--  V2.0 SDK  -->
  <dependency>
    <groupId>com.aliyun</groupId>
    <artifactId>ecs20140526</artifactId>
    <version>3.1.12</version>
  </dependency>
  <!--  V1.0 SDK  -->
  <dependency>
    <groupId>com.aliyun</groupId>
    <artifactId>aliyun-java-sdk-core</artifactId>
    <version>4.6.3</version>
  </dependency>
  <dependency>
    <groupId>com.aliyun</groupId>
    <artifactId>aliyun-java-sdk-ecs</artifactId>
    <version>4.24.59</version>
  </dependency>
</dependencies>

Environment requirements

V2.0 supports more programming languages than V1.0, but has higher environment requirements. Check your runtime before upgrading:

Language

V1.0 requirement

V2.0 requirement

Java

Java 6.0 or later

Java 8.0 or later

Node.js

JavaScript supported

TypeScript only

  • Java: V2.0 requires Java 8.0 or later. V1.0 requires Java 6.0 or later.

  • Node.js: V2.0 supports TypeScript only. Make sure your project is TypeScript-compatible before upgrading.

For language-specific setup and API references, see the development documentation for your language.