Questions tagged [aws-java-sdk]

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, DynamoDB, and more.

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, DynamoDB, and more.

Links

548 questions
3
votes
0 answers

Service: AmazonSQS; Status Code: 403; Error Code: SignatureDoesNotMatch; SQS

i am running my simple class on ec2 to create or send messages on SQS. But this giving me Service: AmazonSQS; Status Code: 403; Error Code: SignatureDoesNotMatch; i'm attaching my code and the error below:- private AWSSimpleQueueServiceUtil() { …
3
votes
1 answer

AWSLambdaClient invoke giving exception: com.amazonaws.SdkClientException: Unable to execute HTTP request: The target server failed to respond

I have an existing aws lambda function and I am trying to invoke it using AWSLambdaClient (library: aws-java-sdk-lambda). I get the response if the runtime for lambda is less than 5 mins. But if the lambda runtime is more than 5 mins I get the…
Bandhan Nawal
  • 31
  • 1
  • 3
3
votes
3 answers

AWS S3 Java SDK - ListVersionsRequest Get Only Latest Versions

Is there any way to specify to only include the latest version of each object in the ListVersionsRequest? I need the version value, so a simple AmazonS3Client.listObjects(...) will not suffice because S3ObjectSummary has no version information. I am…
hoobaka
  • 135
  • 1
  • 1
  • 9
3
votes
0 answers

How to forward the stream from AWS lambda stream output

I can find lots of information on writing directly to the output stream from an AWS Lambda function written in Java, but I can't find any information on how to get that stream in the Java AWS Lambda SDK so that I can bind the resulting inputstream…
Richtopia
  • 360
  • 2
  • 12
3
votes
1 answer

AWSSecurityTokenServiceException: Acced denied. User is not authorized to perform sts:AssumeRole

I'm new to aws. I want to generate temporary credentials for aws call. And for that I use example from Making Requests Using IAM User Temporary Credentials - AWS SDK for Java Where I pass String clientRegion = ""; String roleARN =…
Nikolas
  • 2,322
  • 9
  • 33
  • 55
3
votes
0 answers

Stream file from remote service to S3 bucket

I have a microservice which needs to take a remote file, and upload it to a S3 bucket. The remote file is presented as a download link, and requires basic authentication. Using the latest AWS 2.0 SDK I'm trying to stream the file so it doesn't have…
Chris
  • 3,437
  • 6
  • 40
  • 73
3
votes
0 answers

AWS CloudSearch sort by score and text field

I'm using Amazon's AWS CloudSearch service, and I'm trying to figure out the sort function. I know how to sort by _score, text fields alphabetically, and a combination of _score and int fields, but I want to sort by _score and a text field. I have…
3
votes
1 answer

AWS S3 Bucket policy public. How to make object private?

I've a bucket with GetObject available to everyone on full bucket(*). I want to make a few objects private(through Object level operation ACL), i.e. only the bucket owner should have read access to the object. I've gone through all available…
user3275863
  • 65
  • 1
  • 6
3
votes
1 answer

AWS Lambda and S3 integration using AWS Java Sdk

I am trying to develop a AWS lambda function which is triggered when a file shows up in a specific s3 bucket. I am trying to follow the examples from AWS Lambda documentation, using aws-java-sdk-lambda 1.11.192, aws-java-sdk-s3 1.11.192. But,…
3
votes
1 answer

AWS S3 Java SDK upload fails with "Connection pool shutdown" in Groovy

I am using the Amazon Java SDK (that latest is version 1.11.147 as of this writing) with Groovy (Groovy Version: 2.4.11 JVM: 1.8.0_112 Vendor: Oracle Corporation OS: Mac OS X) to upload files to S3. Using the instructions from Amazon's documentation…
3
votes
1 answer

Dynamodb AWS Java scan withLimit is not working

I am trying to use the DynamoDBScanExpression withLimit of 1 using Java aws-sdk version 1.11.140 Even if I use .withLimit(1) i.e. List result = mapper.scan(new DynamoDBScanExpression().withLimit(1)); returns me list of all entries…
Yash
  • 85
  • 1
  • 10
3
votes
1 answer

AWSMarketplaceMeteringClientBuilder.withRegion() is not visible

I am using AWS SDK for Java to use in AWS Metering service. When I tried to use AWSMarketplaceMeteringClientBuilder to create a AWSMarketplaceMeteringClient, I found that if I use withRegion(Region region) method, I get following compile time…
Rajib Biswas
  • 772
  • 10
  • 27
3
votes
2 answers

AmazonS3Builder produces valid AmazonS3 object but a null is ultimately returned

I'm using the AWS Java SDK v1 and I'm trying to create an AmazonS3 instance using the builder. I'm following the guide in the AWS documentation here and passing explicit credentials using a BasicAWSCredentials object. When the builder builds, I get…
Ananth Rao
  • 1,232
  • 1
  • 9
  • 19
3
votes
1 answer

How do I use the requestShutdown and shutdown to do graceful shutdown in the case of KCL Java library for AWS Kinesis

I am trying to use the new feature of KCL library in Java for AWS Kinesis to do a graceful shutdown by registering with shutdown hook to stop all the record processors and then the worker gracefully. The new library provides a new interface which…
3
votes
1 answer

Feeding SQS Queues available in two different AWS Accounts

For putting messages to SQS Queues and getting a connection, we need to have a key for the account/user. I want to feed messages to two queues which are available in two different AWS Accounts. How can I achieve that? As far as my understanding is,…
Bhaskar
  • 337
  • 6
  • 21