GithubHelp home page GithubHelp logo

aws-java-sample's Introduction

AWS SDK for Java Sample Project

A simple Java application illustrating usage of the AWS SDK for Java.

Requirements

You have a choice of Maven or Gradle

The only requirement of this application is Maven. All other dependencies can be installed by building the maven package:

mvn package

Otherwise with gradle you can run the gradlew wrapper and all dependencies will be installed:

gradlew build

Basic Configuration

You need to set up your AWS security credentials before the sample code is able to connect to AWS. You can do this by creating a file named "credentials" at ~/.aws/ (C:\Users\USER_NAME.aws\ for Windows users) and saving the following lines in the file:

[default]
aws_access_key_id = <your access key id>
aws_secret_access_key = <your secret key>

See the Security Credentials page for more information on getting your keys.

Running the S3 sample

Prerequisites

You will need to go to IAM policies page, search for the String "S3," and "Attach" the "AmazonS3FullAccess" policy to the user whose credentials exist in your ~/.aws/credentials file. Otherwise, you will likely get a AmazonServiceException/Access Denied/403 error.

This sample application connects to Amazon's Simple Storage Service (S3), creates a bucket, and uploads a file to that bucket. The code will generate a bucket name for you, as well as an example file to upload. All you need to do is run it.

Maven:

mvn clean compile exec:java

Gradle:

gradlew clean build run

When you start making your own buckets, the S3 documentation provides a good overview of the restrictions for bucket names.

License

This sample application is distributed under the Apache License, Version 2.0.

aws-java-sample's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

aws-java-sample's Issues

No provision to override httpclient connection timeout value

if request takes too long due to slow connection, request fails.

INFO: Unable to execute HTTP request: Software caused connection abort: recv failed
java.net.SocketException: Software caused connection abort: recv failed
at java.net.SocketInputStream.socketRead0(Native Method)
at java.net.SocketInputStream.socketRead(SocketInputStream.java:116)
at java.net.SocketInputStream.read(SocketInputStream.java:171)
at java.net.SocketInputStream.read(SocketInputStream.java:141)
at sun.security.ssl.InputRecord.readFully(InputRecord.java:465)
at sun.security.ssl.InputRecord.read(InputRecord.java:503)
at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:983)
at sun.security.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1385)
at sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1413)
at sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1397)
at org.apache.http.conn.ssl.SSLSocketFactory.connectSocket(SSLSocketFactory.java:534)
at org.apache.http.conn.ssl.SSLSocketFactory.connectSocket(SSLSocketFactory.java:402)
at com.amazonaws.http.conn.ssl.SdkTLSSocketFactory.connectSocket(SdkTLSSocketFactory.java:112)
at org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:178)
at org.apache.http.impl.conn.ManagedClientConnectionImpl.open(ManagedClientConnectionImpl.java:304)
at org.apache.http.impl.client.DefaultRequestDirector.tryConnect(DefaultRequestDirector.java:610)
at org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:445)
at org.apache.http.impl.client.AbstractHttpClient.doExecute(AbstractHttpClient.java:863)
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:82)
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:57)
at com.amazonaws.http.AmazonHttpClient.executeOneRequest(AmazonHttpClient.java:685)
at com.amazonaws.http.AmazonHttpClient.executeHelper(AmazonHttpClient.java:460)
at com.amazonaws.http.AmazonHttpClient.execute(AmazonHttpClient.java:295)
at com.amazonaws.services.s3.AmazonS3Client.invoke(AmazonS3Client.java:3697)
at com.amazonaws.services.s3.AmazonS3Client.invoke(AmazonS3Client.java:3647)
at com.amazonaws.services.s3.AmazonS3Client.listBuckets(AmazonS3Client.java:674)
at com.amazonaws.services.s3.AmazonS3Client.listBuckets(AmazonS3Client.java:682)
at com.amazonaws.samples.S3Sample.main(S3Sample.java:92)

Caught an AmazonServiceException

When I tried to run this sample, I get this:

Error Message:    Access Denied (Service: Amazon S3; Status Code: 403; Error Code: AccessDenied; Request ID: <>)
HTTP Status Code: 403
AWS Error Code:   AccessDenied
Error Type:       Client
Request ID:       <>

Any help is appreciated.

pom ref to AwsCredentials.properties: include resources paragraph under build paragraph

AwsCredentials.properties is not found given the current java source and pom, so the sample does not run on Mac OS X.

Given that the keys are global and users may not want to include them in each project, the pom.xml should include the external ~/.aws/ properties directory in the runtime classpath.

For example:


<build>
        <resources>
                <resource>
                        <directory>${env.HOME}/.aws/</directory>
                </resource>
        </resources>

After the opening of the build tag and before the start of the exec-maven-plugin.

${env.HOME} resolves to the developers home dir.

Build Error

Very new to programming and AWS SDK Java... Just getting started..

After following all the instructions am getting still the Build Failure still.

[INFO] Scanning for projects...
[INFO]
[INFO] ---------------< com.amazonaws.samples:aws-java-sample >----------------
[INFO] Building aws-java-sample 1.0
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ aws-java-sample ---
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ aws-java-sample ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory C:\Users\userm\Documents\AWS_IOT\aws-java-sample-master${env.HOME}.aws
[INFO]
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) @ aws-java-sample ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 1 source file to C:\Users\userm\Documents\AWS_IOT\aws-java-sample-master\target\classes
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR] Source option 5 is no longer supported. Use 7 or later.
[ERROR] Target option 5 is no longer supported. Use 7 or later.
[INFO] 2 errors
[INFO] -------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.761 s
[INFO] Finished at: 2019-11-24T17:04:57-05:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (default-compile) on project aws-java-sample: Compilation failure: Compilation failure:
[ERROR] Source option 5 is no longer supported. Use 7 or later.
[ERROR] Target option 5 is no longer supported. Use 7 or later.
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException

C:\Users\userm\Documents\AWS_IOT\aws-java-sample-master>pom.xml

C:\Users\userm\Documents\AWS_IOT\aws-java-sample-master>pom.xml

C:\Users\userm\Documents\AWS_IOT\aws-java-sample-master>mvn clean compile exec:java
[INFO] Scanning for projects...
[INFO]
[INFO] ---------------< com.amazonaws.samples:aws-java-sample >----------------
[INFO] Building aws-java-sample 1.0
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ aws-java-sample ---
[INFO] Deleting C:\Users\userm\Documents\AWS_IOT\aws-java-sample-master\target
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ aws-java-sample ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory C:\Users\userm\Documents\AWS_IOT\aws-java-sample-master${env.HOME}.aws
[INFO]
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) @ aws-java-sample ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 1 source file to C:\Users\userm\Documents\AWS_IOT\aws-java-sample-master\target\classes
[INFO]
[INFO] >>> exec-maven-plugin:1.2.1:java (default-cli) > validate @ aws-java-sample >>>
[INFO]
[INFO] <<< exec-maven-plugin:1.2.1:java (default-cli) < validate @ aws-java-sample <<<
[INFO]
[INFO]
[INFO] --- exec-maven-plugin:1.2.1:java (default-cli) @ aws-java-sample ---

Getting Started with Amazon S3

Creating bucket my-first-s3-bucket-e53f604f-8bb8-43c2-941d-cec1e20fc1c9

[WARNING]
java.lang.reflect.InvocationTargetException
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke (Method.java:567)
at org.codehaus.mojo.exec.ExecJavaMojo$1.run (ExecJavaMojo.java:297)
at java.lang.Thread.run (Thread.java:830)
Caused by: java.lang.NoClassDefFoundError: javax/xml/bind/DatatypeConverter
at com.amazonaws.util.Base64.encodeAsString (Base64.java:36)
at com.amazonaws.auth.AbstractAWSSigner.signAndBase64Encode (AbstractAWSSigner.java:70)
at com.amazonaws.auth.AbstractAWSSigner.signAndBase64Encode (AbstractAWSSigner.java:58)
at com.amazonaws.services.s3.internal.S3Signer.sign (S3Signer.java:127)
at com.amazonaws.http.AmazonHttpClient.executeOneRequest (AmazonHttpClient.java:652)
at com.amazonaws.http.AmazonHttpClient.executeHelper (AmazonHttpClient.java:460)
at com.amazonaws.http.AmazonHttpClient.execute (AmazonHttpClient.java:295)
at com.amazonaws.services.s3.AmazonS3Client.invoke (AmazonS3Client.java:3697)
at com.amazonaws.services.s3.AmazonS3Client.createBucket (AmazonS3Client.java:788)
at com.amazonaws.services.s3.AmazonS3Client.createBucket (AmazonS3Client.java:713)
at com.amazonaws.samples.S3Sample.main (S3Sample.java:86)
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke (Method.java:567)
at org.codehaus.mojo.exec.ExecJavaMojo$1.run (ExecJavaMojo.java:297)
at java.lang.Thread.run (Thread.java:830)
Caused by: java.lang.ClassNotFoundException: javax.xml.bind.DatatypeConverter
at java.net.URLClassLoader.findClass (URLClassLoader.java:436)
at java.lang.ClassLoader.loadClass (ClassLoader.java:588)
at java.lang.ClassLoader.loadClass (ClassLoader.java:521)
at com.amazonaws.util.Base64.encodeAsString (Base64.java:36)
at com.amazonaws.auth.AbstractAWSSigner.signAndBase64Encode (AbstractAWSSigner.java:70)
at com.amazonaws.auth.AbstractAWSSigner.signAndBase64Encode (AbstractAWSSigner.java:58)
at com.amazonaws.services.s3.internal.S3Signer.sign (S3Signer.java:127)
at com.amazonaws.http.AmazonHttpClient.executeOneRequest (AmazonHttpClient.java:652)
at com.amazonaws.http.AmazonHttpClient.executeHelper (AmazonHttpClient.java:460)
at com.amazonaws.http.AmazonHttpClient.execute (AmazonHttpClient.java:295)
at com.amazonaws.services.s3.AmazonS3Client.invoke (AmazonS3Client.java:3697)
at com.amazonaws.services.s3.AmazonS3Client.createBucket (AmazonS3Client.java:788)
at com.amazonaws.services.s3.AmazonS3Client.createBucket (AmazonS3Client.java:713)
at com.amazonaws.samples.S3Sample.main (S3Sample.java:86)
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke (Method.java:567)
at org.codehaus.mojo.exec.ExecJavaMojo$1.run (ExecJavaMojo.java:297)
at java.lang.Thread.run (Thread.java:830)
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 3.522 s
[INFO] Finished at: 2019-11-24T17:07:57-05:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2.1:java (default-cli) on project aws-java-sample: An exception occured while executing the Java class. null: InvocationTargetException: javax/xml/bind/DatatypeConverter: javax.xml.bind.DatatypeConverter -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException

Please help !!! Thanks in advance

The AWS Access Key Id you provided does not exist in our records.

It does, and it's properly set up in my ~/.aws/credentials file and it's successfully used by the Javascript SDK and the AWS CLI - and (while it shouldn't make a difference) I changed the region setting in the Java code to be EU-WEST-1 to try that too. Same problem

Given that, what's the problem please?

Maven error and javax.xml.bind.DatatypeConverter with jdk10

If you get the error
maven Source option 5 is no longer supported. Use 6 or later. [ERROR] Target option 1.5 is no longer supported. Use 1.6 or later.

Add the following to the properties
<maven.compiler.source>1.6</maven.compiler.source>
<maven.compiler.target>1.6</maven.compiler.target>

That fixes the problem for jdk8.

For jdk10
The example builds but gives a runtime exception
An exception occured while executing the Java class. null: InvocationTargetException: javax/xml/bind/DatatypeConverter: javax.xml.bind.DatatypeConverter

as javax.xml.bind.DatatypeConverter is removed in JDK9 onwards

class not found exception when compiling

I'm running Win7 64bit and have installed maven and the Java SDK. When running mvn package the AWS packages are downloaded and everything seems fine.

When I run mvn clean compile exec:java, I end up with this:

[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 1 resource
[INFO]
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) @ aws-java-sample


[INFO] Nothing to compile - all classes are up to date
[INFO]
[INFO] >>> exec-maven-plugin:1.2.1:java (default-cli) > validate @ aws-java-samp
le >>>
[INFO]
[INFO] <<< exec-maven-plugin:1.2.1:java (default-cli) < validate @ aws-java-samp
le <<<
[INFO]
[INFO] --- exec-maven-plugin:1.2.1:java (default-cli) @ aws-java-sample ---
[WARNING]
java.lang.ClassNotFoundException: com.amazonaws.samples.S3Sample
at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
at org.codehaus.mojo.exec.ExecJavaMojo$1.run(ExecJavaMojo.java:285)
at java.lang.Thread.run(Thread.java:745)

Also, the credentials text file is copied to the /target/classes/ folder.

What I am doing wrong or missing? Do I need to remove CLASSPATH from my Windows environment variables?

AmazonClientException

I've got some troubles with running this sample.
I've followed instructions on http://aws.amazon.com/ru/developers/getting-started/java/, and after running mvn clean compile exec:java I've got AmazonClientException(Unable to execute HTTP request: peer not authenticated) followed by "Unable to execute HTTP request: peer not authenticated". This things happen when I am trying to create bucket, so I've got "Creating bucket my-first-s3-bucket-865cc23b-7f73-4e09-a9d9-c38382d72e2b" and then an error.
I've looked throw https://forums.aws.amazon.com/message.jspa?messageID=429971, but unfortunately I don't completely understand how to use suggested solution (http://javaskeleton.blogspot.ie/2010/07/avoiding-peer-not-authenticated-with.html) here.

Unable to load AWS credentials from any provider in the chain

I have my application running on EC2. Trying to access dynamoDB from my Java application. But for every operation, I get "Unable to load AWS credentials from any provider in the chain".

  • I have added dynamoDB permissions in the IAM role that gets attached to EC2 instance
  • And also configured EC2 to assume that role in trust relationship.

Code:

            AWSCredentialsProvider provider = new DefaultAWSCredentialsProviderChain();
            AWSCredentials credentials = provider.getCredentials();
            if(credentials != null) {
                LOG.info("Credentials Key: " + credentials.getAWSAccessKeyId());
                LOG.info("Credentials secret: " + credentials.getAWSSecretKey());
            }
        } catch (Exception e) {
            LOG.info("Exception in credentials cause:" + e.getCause() +";message: " + e.getMessage() +";stack: " +e.getStackTrace());
        }

The getCredentials() line itself throws an Exception with message: "Unable to load AWS credentials from any provider in the chain".
If I do not try to get credentials here and pass it to the DynamoDB client:

                .withClientConfiguration(clientConfig)
                .build();```

Then it throws the same exception when I try to do any operation.

I tried setting up the proxy too: 

```ClientConfiguration clientConfig = new ClientConfiguration();
        clientConfig.setProxyHost("yyy");
        clientConfig.setProxyPort(port);
        clientConfig.setNonProxyHosts("xxx");
        clientConfig.setProtocol(Protocol.HTTP);```

and then passing it while creating the client:

```        dynamoDBClient = builder.withEndpointConfiguration(new AwsClientBuilder.EndpointConfiguration(url, region.getName()))
                .withCredentials(credentialProvider())
                .withClientConfiguration(clientConfig)
                .build();

But no success.

Can someone @here guide me what am I missing here?

The authorization mechanism you have provided is not supported. Please use AWS4-HMAC-SHA256.

Below Sample returns subjected error, using latest version of java sdk

package com.amazonaws.samples;

import java.io.IOException;
import java.net.URL;

import com.amazonaws.AmazonClientException;
import com.amazonaws.AmazonServiceException;
import com.amazonaws.HttpMethod;
import com.amazonaws.auth.profile.ProfileCredentialsProvider;
import com.amazonaws.services.s3.AmazonS3;
import com.amazonaws.services.s3.AmazonS3Client;
import com.amazonaws.services.s3.model.GeneratePresignedUrlRequest;

public class GeneratePreSignedUrl {
private static String bucketName = "bucketforwso2";
private static String objectKey = "/HTML-CHEAT-SHEET-768x8555.pdf";

public static void main(String[] args) throws IOException {
	@SuppressWarnings("deprecation")
	AmazonS3 s3client = new AmazonS3Client(new ProfileCredentialsProvider());

	try {
		System.out.println("Generating pre-signed URL.");
		java.util.Date expiration = new java.util.Date();
		long milliSeconds = expiration.getTime();
		milliSeconds += 1000 * 60 * 60; // Add 1 hour.
		expiration.setTime(milliSeconds);

		GeneratePresignedUrlRequest generatePresignedUrlRequest = 
			    new GeneratePresignedUrlRequest(bucketName, objectKey);
		generatePresignedUrlRequest.setMethod(HttpMethod.GET); 
		generatePresignedUrlRequest.setExpiration(expiration);

		URL url = s3client.generatePresignedUrl(generatePresignedUrlRequest); 

		System.out.println("Pre-Signed URL = " + url.toString());
	} catch (AmazonServiceException exception) {
		System.out.println("Caught an AmazonServiceException, " +
				"which means your request made it " +
				"to Amazon S3, but was rejected with an error response " +
		"for some reason.");
		System.out.println("Error Message: " + exception.getMessage());
		System.out.println("HTTP  Code: "    + exception.getStatusCode());
		System.out.println("AWS Error Code:" + exception.getErrorCode());
		System.out.println("Error Type:    " + exception.getErrorType());
		System.out.println("Request ID:    " + exception.getRequestId());
	} catch (AmazonClientException ace) {
		System.out.println("Caught an AmazonClientException, " +
				"which means the client encountered " +
				"an internal error while trying to communicate" +
				" with S3, " +
		"such as not being able to access the network.");
		System.out.println("Error Message: " + ace.getMessage());
	}
}

}

Generating pre-signed URL.
Pre-Signed URL = https://bucketforwso2.s3.amazonaws.com/%2FHTML-CHEAT-SHEET-768x8555.pdf?AWSAccessKeyId=AKIAJH5K4ZJ6ZQB2F4XB&Expires=1514962084&Signature=rY7RjDwJkck8ZCEGWUr4lSm%2Bkuw%3D

InvalidRequest The authorization mechanism you have provided is not supported. Please use AWS4-HMAC-SHA256. 2947D4830B323D3A 4JK5mlUk/a7oOd6WJT5ol5X0prJY+0buLKr9zhnOcoz0mxAk/oc9A/nWHgIC8lggT11xneCtRLU=

Build Failure

I followed these instructions from the Getting Started with the JAVA SDK https://aws.amazon.com/developers/getting-started/java/:

Download the Sample Project
git clone https://github.com/awslabs/aws-java-sample.git

From the aws-java-sample directory, run:
mvn clean compile exec:java

I however get the following build error:


[INFO] Changes detected - recompiling the module!
[INFO] Compiling 1 source file to C:\Users\jamisch\Documents\GitHub\aws-java-sample\target\classes
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR] Source option 5 is no longer supported. Use 6 or later.
[ERROR] Target option 1.5 is no longer supported. Use 1.6 or later.
[INFO] 2 errors
[INFO] -------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  19.220 s
[INFO] Finished at: 2018-11-01T17:36:06-07:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (default-compile) on project aws-java-sample: Co
[ERROR] Source option 5 is no longer supported. Use 6 or later.
[ERROR] Target option 1.5 is no longer supported. Use 1.6 or later.
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.