Building Java Reference Documentation for Earlier SDK versions

AWS SDK for Java Developer Guide:

The AWS SDK for Java provides a Java API for Amazon Web Services. Using the SDK, you can easily build Java applications that work with Amazon S3, Amazon EC2, Amazon SimpleDB, and more.

We regularly add support for new services to the AWS SDK for Java. For a list of the supported services and their API versions that are included with each release of the SDK. For more info Java Online Classes

Eclipse IDE Support

If you develop code using the Eclipse IDE, you can use the AWS Toolkit for Eclipse to add the AWS SDK for Java to an existing Eclipse project or to create a new AWS SDK for Java project.

The toolkit also supports creating and uploading Lambda functions, launching and monitoring Amazon EC2 instances, managing IAM users and security groups, a AWS CloudFormation template editor, and more.

Developing AWS Applications for Android

If you’re an Android developer, Amazon Web Services publishes an SDK made specifically for Android development: the AWS Mobile SDK for Android.

Viewing the SDK’s Revision History

To view the release history of the AWS SDK for Java, including changes and supported services per SDK version. Learn more skills from Java Online Training

Building Java Reference Documentation for Earlier SDK versions

The AWS SDK for Java API Reference represents the most recent version of the SDK. If you’re using an earlier SDK version, you might want to access the SDK reference documentation that matches the version you’re using.

The easiest way to build the documentation is using Apache’s Maven build tool. Download and install Maven first if you don’t already have it on your system, then use the following instructions to build the reference documentation.

To build reference documentation for an earlier SDK version

  1. Locate and select the SDK version that you’re using on the releases page of the SDK repository on GitHub.
  2. Choose either the zip (most platforms, including Windows) or tar.gz (Linux, macOS, or Unix) link to download the SDK to your computer.
  3. Unpack the archive to a local directory.
  4. On the command line, navigate to the directory where you unpacked the archive, and type the following.
mvn javadoc:javadoc

After building is complete, you’ll find the generated HTML documentation in the aws-java-sdk/target/site/apidocs/ directory.

Enabling Metrics for the AWS SDK for Java

The AWS SDK for Java can generate metrics for visualization and monitoring with CloudWatch that measure:

  • your application’s performance when accessing AWS
  • the performance of your JVMs when used with AWS
  • runtime environment details such as heap memory, number of threads, and opened file descriptors

Note

The AWS SDK Metrics for Enterprise Support is another option for gathering metrics about your application. SDK Metrics is an AWS service that publishes data to Amazon CloudWatch and enables you to share metric data with AWS Support for easier troubleshooting. Get more programming skills from Java Online Course

How to Enable AWS SDK for Java Metric Generation

AWS SDK for Java metrics are disabled by default. To enable it for your local development environment, include a system property that points to your AWS security credential file when starting up the JVM. For example:

Dcom.amazonaws.sdk.enableDefaultMetrics=credentialFile=/path/aws.properties

You need to specify the path to your credential file so that the SDK can upload the gathered datapoints to CloudWatch for later analysis.

Note

If you are accessing AWS from an Amazon EC2 instance using the Amazon EC2 instance metadata service, you don’t need to specify a credential file. In this case, you need only specify:

Dcom.amazonaws.sdk.enableDefaultMetrics

All metrics captured by the SDK for Java are under the namespace AWSSDK/Java, and are uploaded to the CloudWatch default region (us-east-1). To change the region, specify it by using the cloudwatchRegion attribute in the system property. For example, to set the CloudWatch region to us-west-2, use:

Dcom.amazonaws.sdk.enableDefaultMetrics=credentialFile=/path/aws.properties,cloudwatchRegion=us-west-2

Once you enable the feature, every time there is a service request to AWS from the AWS SDK for Java, metric data points will be generated, queued for statistical summary, and uploaded asynchronously to CloudWatch about once every minute. Once metrics have been uploaded, you can visualize them using the AWS Management Console and set alarms on potential problems such as memory leakage, file descriptor leakage, and so on.

Available Metric Types

The default set of metrics is divided into three major categories:

AWS Request Metrics

Covers areas such as the latency of the HTTP request/response, number of requests, exceptions, and retries.

AWS Service Metrics

Include AWS service-specific data, such as the throughput and byte count for S3 uploads and downloads.

Machine Metrics

Cover the runtime environment, including heap memory, number of threads, and open file descriptors.

To get in-depth knowledge, enroll for a live free demo on Java Certification Course

Leave a comment

Design a site like this with WordPress.com
Get started