AWS Mobile Blog

AWS Mobile SDK for Android – Maven Support

by Mudeem Siddiqui | on | Permalink | Comments |  Share

If you are a Maven user, adding the AWS Mobile SDK for Android in your Android project is now as simple as adding few lines to your pom.xml. You no longer need to download the entire AWS Mobile SDK for Android zip file and include the JAR files in your project manually. You can specify the services you want to use in your app in your project’s pom.xml file, and Maven will handle the rest.

If you are new to Maven, it is a tool that you can use to build your project and handle dependencies. You can learn more about Maven here.

Here is an example of how you can add Amazon Cognito Identity, Amazon S3, and Amazon Mobile Analytics in your project:

<dependencies>    
    <dependency>
        <groupid>com.amazonaws</groupid>
        <artifactid>aws-android-sdk-core</artifactid>
        <version>2.1.3</version>
    </dependency>
    <dependency>
        <groupid>com.amazonaws</groupid>
        <artifactid>aws-android-sdk-s3</artifactid>
        <version>2.1.3</version>
    </dependency>
    <dependency>
        <groupid>com.amazonaws</groupid>
        <artifactid>aws-android-sdk-mobileanalytics</artifactid>
        <version>2.1.3</version>
    </dependency>
</dependencies> 

As shown above, the groupId for the AWS Mobile SDK for Android is "com.amazonaws". We will be supporting AWS Mobile SDK for Android versions 2.1.3 and onward. Note: this means that you won’t be able to get older versions via Maven.

The AWS Mobile SDK for Android artifactId’s are as follows:

Service/Feature

artifactID

AWS Mobile SDK Core includes Amazon Cognito Identity and AWS Simple Token Service (STS)

aws-android-sdk-core

Auto Scaling

aws-android-sdk-autoscaling

Amazon Cloud Watch

aws-android-sdk-cloudwatch

Amazon Cognito Sync

aws-android-sdk-cognito

Amazon DynamoDB

aws-android-sdk-ddb

Amazon DynamoDB Object Mapper

aws-android-sdk-ddb-mapper

Amazon EC2

aws-android-sdk-ec2

Elastic Load Balancing

aws-android-sdk-elb

Amazon Kinesis

aws-android-sdk-kinesis

Amazon Mobile Analytics

aws-android-sdk-mobileanalytics

Amazon S3

aws-android-sdk-s3

Amazon Simple DB

aws-android-sdk-sdb

Amazon SES

aws-android-sdk-ses

Amazon SNS

aws-android-sdk-sns

Amazon SQS

aws-android-sdk-sqs

 

Useful Links