This topic describes how to install Tablestore SDK for Java.

Preparation

To install Tablestore SDK for Java, you must use JDK 6.0 or later versions.

Install SDK

You can install Tablestore SDK for Java by using one of the two following methods:

  • Add dependencies to a Maven project

    To use Tablestore SDK for Java in Maven, you need only to add the corresponding dependencies to the pom.xml file. This example uses Tablestore SDK for Java V5.4.0. Add the following content to <dependencies>:

    <dependency>
        <groupId>com.aliyun.openservices</groupId>
        <artifactId>tablestore</artifactId>
        <version>5.4.0</version>
    </dependency>                 
  • Import JAR packages into Eclipse

    Take Tablestore SDK for Java V5.4.0 as an example. To import JAR packages into Eclipse, perform the following operations:

    1. Download the SDK for Java package.
    2. Decompress the SDK for Java package.
    3. Copy the tablestore-<versionId>.jar file and all files in the lib folder to your project.
    4. Right-click your project name in Eclipse and choose Properties > Java Build Path > Add JARs.
    5. Select all JAR packages you have copied in step 3.

Sample programs

Tablestore SDK for Java provides a variety of sample programs for your reference or use. You can decompress the downloaded SDK package and view the sample programs in the examples folder.