Skip to content

Latest commit

 

History

History
127 lines (93 loc) · 5.24 KB

File metadata and controls

127 lines (93 loc) · 5.24 KB

AWS SDK Grails Plugin

Build Status

Introduction

The AWS SDK Plugin allows your Grails application to use the Amazon Web Services infrastructure services.

The aim is to provide a lightweight amazonWebService Grails service wrapper around the official AWS SDK for Java.

The AWS SDK for Java provides a Java API for AWS infrastructure services, making it even easier for developers to build applications that tap into the cost-effective, scalable, and reliable AWS cloud.

The Grails plugin handles :

  • convenient Grails configuration/management of all AWS API clients for each AWS region,
  • easy access to all AWS API java clients through the amazonWebService Grails service wrapper.

Installation

Declare the plugin dependency in the BuildConfig.groovvy file, as shown here:

grails.project.dependency.resolution = {
		inherits("global") { }
		log "info"
		repositories {
				//your repositories
		}
		dependencies {
				// Workaround to resolve dependency issue with aws-java-sdk and http-builder (dependent on httpcore:4.0)
                build 'org.apache.httpcomponents:httpcore:4.1'
                build 'org.apache.httpcomponents:httpclient:4.1'
                runtime 'org.apache.httpcomponents:httpcore:4.1'
                runtime 'org.apache.httpcomponents:httpclient:4.1'
		}
		plugins {
				//here go your plugin dependencies
				runtime ':aws-sdk:1.3.33'
		}
}

Config

Create an AWS account Amazon Web Services, in order to get your own credentials accessKey and secretKey.

Add your AWS credentials parameters to your grails-app/conf/Config.groovy:

grails.plugin.awssdk.accessKey = {ACCESS_KEY}
grails.plugin.awssdk.secretKey = {SECRET_KEY}

Documentation

Project documentation is located here:

AWS SDK for Java documentation is located here:

Supported AWS Services

AWS clients supported by AWS SDK for Java:

  • Amazon CloudFormation
  • Amazon CloudFront
  • Amazon CloudSearch
  • Amazon CloudWatch
  • Amazon DynamoDB
  • Amazon Elastic Compute Cloud (EC2)
  • Amazon Elastic MapReduce
  • Amazon Elastic Transcoder
  • Amazon ElastiCache
  • Amazon Glacier
  • Amazon Relational Database Service (RDS)
  • Amazon Redshift
  • Amazon Route 53
  • Amazon Simple Storage Service (S3)
  • Amazon Simple Email Service (SES)
  • Amazon SimpleDB
  • Amazon Simple Notification Service (SNS)
  • Amazon Simple Queue Service (SQS)
  • Amazon Simple Workflow (SWF)
  • Auto Scaling
  • AWS Elastic Beanstalk
  • AWS Identity & Access Management (IAM)
  • AWS Import/Export
  • AWS OpsWorks
  • AWS Storage Gateway
  • Elastic Load Balancing

Latest releases

  • 2013-03-05 V1.3.33 : AWS SDK for Java updated to V1.3.33 + Unit tests added + refactor/bug fixes (thanks to Martin Gotink)
  • 2013-02-21 V1.3.32 : AWS SDK for Java updated to V1.3.32 + Amazon OpsWorks and Redshift support added + bug fix
  • 2013-02-05 V1.3.30 : AWS SDK for Java updated to V1.3.30 + Amazon Elastic Transcoder support added
  • 2012-12-20 V1.3.26 : AWS SDK for Java updated to V1.3.26 + S3 Resources scripts (to use with CDN Resources plugin)
  • 2012-11-12 V1.3.24 : AWS SDK for Java updated to V1.3.24 (adds support for long polling in SQS)
  • 2012-10-06 V1.3.22 : AWS SDK for Java updated to V1.3.22 + S3 transfer manager support added (for async upload/download and multiple files upload/download)
  • 2012-09-27 V1.3.21 : AWS SDK for Java updated to V1.3.21.1 + Amazon Glacier support added
  • 2012-07-04 V1.3.12 : AWS SDK for Java updated to V1.3.12
  • 2012-07-02 V1.3.11 : initial release

Bugs

To report any bug, please use the project Issues section on GitHub.

Other Grails AWS Plugin

FYI, there is another great Grails AWS plugin with a different approach: its aim is to provide an easy "groovy" access to SES (through a groovy DSL) and S3 (through methods injection), based on JetS3 java lib. If you just need basic SES or S3 features, you might give it a try.

We decided to write our own AWS plugin because it did not meet our requirements:

  1. direct access to ALL AWS SDK for Java features including ALL AWS services, with custom client configuration,
  2. only AWS SDK for Java with a consistent way to access ALL AWS services,
  3. fast release update with 100% compatibility with AWS SDK for Java, as it is just a simple lightweight wrapper around the official java clients,
  4. no need for additional DSL/methods injection, since we found the AWS SDK for Java clients pretty straightforward to use