Questions tagged [aws-sdk]

1

votes
0

answer
76

Views

AWS SDK LexRuntimeService Error: JSON ParserException

This is for AWS LexRuntimeService SDK for PHP. This is the full error I continue to get whenever Lex responds to the SDK with any ElicitIntent response: ParserException: Error parsing JSON: Syntax error in .../Aws/Api/Parser/PayloadParserTrait.php on line 20 ElicitSlot does not cause this exception...
Jay A. Little
0

votes
0

answer
3

Views

How to use GetCurrentMetricData from Amazon Connect

I am trying to write a lambda that will call getCurrentMetricData API/function from Amazon Connect. I have tried everything I can think of but I am getting the same error that connect.getCurrentMetricData is not a function. This is what I have so far: getHandler function: var service = require('./am...
DoArNa
1

votes
0

answer
712

Views

AmazonS3Exception: Bad Request 400 when trying to use S3AFilesystem

I have java code which tries to initialize a remote filesystem from S3 using coniguration (this was previously on HDFS and I try to move this to s3 without modifying the code too much). This is the config: fs.s3a.aws.credentials.provider=com.amazonaws.auth.DefaultAWSCredentialsProviderChain fs.defau...
1

votes
1

answer
106

Views

AWS DAX java authentication issue

I am attempting to write a flexible authentication mechanism between using DAX and DynamoDB for performance testing. I have been able to get it to work fine with DynamoDB accross all regions, but it only works correctly in us-west-1 in DAX. if (this.useDax) { try { AWSCredentials credentials = new P...
Flint Dominic
1

votes
0

answer
217

Views

AWS: Dynamo DB first request has high write latency

I am using AWS Java SDK to create an adapter to connect, save and query to Dynamo DB. I am getting irregularity in latency as shown below:- Case 1 -> For the first write request (after deployment on ec2) it takes around 50-100ms and then subsequent calls take 8-10ms. Case 2 ->Also if the ec2 is let...
user93726
1

votes
1

answer
110

Views

Cannot Archive Data from AWS Kinesis to Glacier

I am working on a Data processing application hosted as a web service on an EC2, each second a small data file (less than 10KB) in .csv format is generated. Problem Statement: Archive all the data files generated to Amazon Glacier. My Approach : As data files are very small. I store the files in AW...
1

votes
0

answer
118

Views

Connection Refused error in Amazon AWS EC2 api call

'org.apache.http.conn.HttpHostConnectException: Connection to http://myurl.amazonaws.com Connection refused.' Here I am using a web service uploaded in Amazon AWS EC2 server, which is used to upload a video. But on the start it throws an error of Connection refused. Api call is from Android App(meth...
Nikhil
1

votes
0

answer
269

Views

java.lang.NoSuchMethodError with AWS SDK

I'm attempting to upload images to Amazon S3 bucket using the following code: AmazonS3 s3Client = AmazonS3ClientBuilder.standard() .withRegion('us-east-1') .withCredentials(credentialsProvider) .build(); However, Eclipse throws the following exception: Exception in thread 'main' java.lang.NoSuchMeth...
S.O.S
1

votes
0

answer
45

Views

aws-sdk, How to send JSONArray to DynamoDB updateItem() method?

I am unable to send JsonArray to SetExpressionAttributeValues() of UpdateItemRequest to be able to pass to DynamoDBClient.updateItem() method Following is the JsonArray ,which i want to pass to SetExpressionAttributeValues() Method of updateItemRequest. [{'ID':'T1','Result':1},{'ID':'T2','Result':0}...
sumitl
1

votes
0

answer
14

Views

Request from BOTO failing after making request from AWS CPP sdk

my application is making request to AWS dynamodb using AWS CPP Sdk, and after that other request is sent from BOTO to dynamodb, but it fails with below error: ssl.SSLError: _ssl.c:319: Invalid SSL protocol variant specified. how can i resolve it. Appreciate the help
kailash19
1

votes
0

answer
202

Views

OPTIONS request returning 403 on a presigned S3 url

I have an s3 bucket. The bucket has CORS enabled. When I access a resource via GET from the bucket via the browser with javascript the resource works and the options request is successful. When I presign a request via the AWS API I get a 403 returned on the options request for the presigned link. Th...
Stewart
1

votes
0

answer
65

Views

Assume/switch role in aws toolkit for eclipse 2.0

I am using aws toolkit for eclipse 2.0. using the options ( window -> preference -> aws toolkit) I have configured IAM/login user api access key id and secret access key. According to our aws configuration, this IAM user has to assume role to view/access any resources in our environment. I am doing...
user12
1

votes
0

answer
106

Views

Multer-s3 dynamic s3 instance

I'm trying to upload files to my s3 bucket, using multer and multer-s3 for Nodejs. The problem that I have now is that I want to set up my s3 instance dynamically because the s3 account and the bucket depend on my user settings. I have the following code: My uploader var uploader = multer({ storage:...
Brayan Serrano
1

votes
0

answer
255

Views

Getting socket timeout exceptions while receiving message from SQS queue

Need help with this socket timeout exception that I keep getting intermittently in my application while trying to read messages from AWS SQS queues. Process: I keep calling SQS queue receive message request with default wait message time of 20 seconds. (AmazonSQSClient.receiveMessage) If no message...
face
1

votes
0

answer
29

Views

How to write the presignup lands triggers for authorization and authentication using node js

I m very new to aws lamda trigger and cognito user pool. I am trying to achieve the following things: I have two type of user (individual and organization). When I select individual it will store the value in dynamodb. And when I select organization it will store the data in different dynamo dB. I...
Chitrarekha
1

votes
0

answer
161

Views

Web-socket Handshake Error AWS IOT

I am getting this WebSocket Handshake Error when I try to connect to AWS IOT using aws-iot-python-sdk. I am using WebSocket + MQTT version to publish and receive data. Very weird thing is that it was working fine just few hours ago, not a single line of change in code, just starting throwing error,...
Rabin Gaire
1

votes
0

answer
136

Views

Can I get the first X bytes from AWS S3 using Go SDK 2

I would like to get the first X Bytes from a very large CSV file. I basically just want to get the first two rows so I get the column names and an example of the data in each. However, I know that this isn't going to be possible so I would like to just download enough bytes to reasonably have enough...
Mark Hayward
1

votes
0

answer
159

Views

Subscribe to Topics using AWS-IOT with .NET

I have spent many hours looking for a way to subscribe to a topic using the AWSSDK.IoT library. I can publish easily enough, but can't figure out the subscription part. I am using the AmazonIotDataClient (AWSSDK.IotData), but have also tried the AmazonIotClient (AWSSDK.Iot). I am not having any lu...
Spenduku
1

votes
1

answer
141

Views

AWS SSM error : UnexpectedParameter: Unexpected key 'CloudWatchOutputConfig'

I am using AWS Lambda to Run Command in SSM. This is the code: const AWS = require('aws-sdk') const ssm = new AWS.SSM() exports.handler = (event, context, callback) => { ssm.sendCommand({ DocumentName: 'AWS-RunShellScript', CloudWatchOutputConfig : { CloudWatchOutputEnabled: true, CloudWatchLogGroup...
swapp1990
1

votes
0

answer
28

Views

Continuous Integration and Delivery in AWS

I am figuring out the best approach to perform the following steps in an automated way: A code is committed in GITLabs then a Trigger implemented in AWS gets notified and A script in AWS instance pulls the new code from GITLabs and deploys I want this to be implemented to the instances launched thro...
Salil Lambay
1

votes
2

answer
181

Views

CognitoAuthentication Extension for .NET with Unity (StartWithSrpAuthAsync()) issue

After importing the AWS-SDK for .NET dll's including the AWS.Extension.CognitoAuthentication into Unity 2018.2, I am having a problem with the StartWithSrpAuthAsync function taken from AuthenticateWithSrpAsync provided by https://aws.amazon.com/blogs/developer/cognitoauthentication-extension-library...
Kevin Amditis
1

votes
1

answer
72

Views

Signature4 signing for elastic search in aws

I'm using the aws managed elasticsearch/ I'm using the high-level java client for elastic search. Is there a way to use aws signature4 signing for the requests made with the high level client?
Nishant Revur
1

votes
2

answer
139

Views

AWS IoT certificates per device or per group of devices?

I do have a question about the best practice for AWS IoT devices, should I create a certificate per device or should I use one certificate for multiple devices or per device type? I'm trying to find the best practice but I still not getting any information about it.
Rogelio Blanco
1

votes
0

answer
20

Views

How to upload assets to AWS presignedurl from ClientSide javascrript

I am approching presignedUrl method to upload a large file . I call an API from my angular code to server side which gives me presignedUrl , then I need to upload an URL . I have some question on this 1) Is there need to AWS SDK on my Angular side ? I assume I dont need it , I just sent PUT reque...
Ashutosh Jha
1

votes
2

answer
969

Views

AWS S3 Sync --force-glacier-transfer

Few days back i was experimenting with S3 & Glacier and my data was archived so restoring it back i had to use their expedited service (which costs a lot). I want to move all of my content from one bucket to another bucket in same region same account. When i try to sync the data it gives following e...
ieatbytes
1

votes
1

answer
141

Views

DyanmoDB query to fetch item using non partition key

I have requirement to fetch the item from dynamodb based on the order id(not the partition key). If the order id is 123456 as mentioned the in the above example I should get this item. Can somebody please let me know if it is possible to achieve this. If yes, how? DynamoDB Table @DynamoDBTable(table...
prevmware
1

votes
0

answer
31

Views

Modify datapoints value in cloudwatch alarm with cloudformation

The number of datapoints that must be breaching to trigger the alarm can be configured and its documented in the PutMetricAlarm API reference but it's missing from the CloudFormation docs. I tried to do it in Java with Cloudformation but it returns an error that property is unknown. Is there any was...
João Pereira
1

votes
1

answer
156

Views

How to handle manual invoked AWS lambda using serverless framework

I am manually invoking my lambda function since the 30s HTTP gateway timeout is too short for my purpose. The function was working when using HTTP, but when I manually invoke the function, the request.Body is empty. Here is the handler on my lambda code: func handler(request events.APIGatewayProxyRe...
PotatoPeanut
1

votes
1

answer
36

Views

AWS DataPipeline EvaluateExpression using Java SDK

Using the AWS DataPipeline API, I'm trying to programmatically evaluate an Expression like the following: sometext-#{format(@scheduledStartTime, 'YYYYMMddHHmmss') To evaluate the expression, I'm using a PipelineObject that looks something like the following: Id:@MyPipelineObject_2018-08-26T01:00:00...
ExceptionRaiser
1

votes
0

answer
148

Views

Check if an S3 key exists without throwing exception

In Lambda/.Net Core 2.1, I need to check if an S3 key exists: try { using (var response = await _client.GetObjectAsync(getRequest)) using (var streamReader = new StreamReader(response.ResponseStream)) using (var sr = new JsonTextReader(streamReader)) { existingMods = _jsonSerializer.Deserialize(sr);...
user1044169
1

votes
0

answer
86

Views

Get return value of AWS getSignedUrl function within a seperate function with callback

I have a function to get a signedurl for s3 in a seperate javascript file(s3.js). Now I need to call that function in my route, placed in another file. getSignedUrl works and I was able to log the result correctly. But it doesn't pass result to the caller function. get signed url function (s3.js f...
Achira Shamal
1

votes
0

answer
199

Views

EMR Cluster creation using Java

I am trying to create an EMR Cluster using Java. I have created the jar file and put that into a lambda function. I'm calling the lambda from AWS Step functions. I created the maven package including the AWS JAVA SDK dependencies and also imported all the packages import java.io.IOException; import...
NK7983
1

votes
1

answer
200

Views

AWS SageMaker - Request has Invalid image format

I'm testing Amazon SageMaker service with NodeJS + AWS SDK and after create a new model and endpoint based on this example (everything works well in the notebook, including the request to the endpoint), I'm trying to create requests from my Express application, but I'm getting the following error: E...
Pablo D
1

votes
0

answer
75

Views

How to use AWS AES-256 in AWS Lambda C#

Beginner here. How can I access an encrypted bucket. I read the documentation and it doesnt clearly state how will I create an encrypted bucket besides the default encryption option and bucket policy. I cant use a KMS key for the encryption I checked this AWS Server-Side Encryption C# but I dont kno...
John
1

votes
1

answer
90

Views

AWS Cognito iOS: How to replace / upgrade from AWS MobileHubHelper generated code?

I am developing an iOS application with user authentication via a AWS Cognito user pool (with email/password authentication). The initial Xcode project and source code was generated by the AWS MobileHub code generator (that is no longer available). It contained the AWSMobileHubHelper framework, an...
thomers
1

votes
0

answer
297

Views

com.amazonaws.SdkClientException: Unable to calculate MD5 hash: /home/bharath/Documents/demo/demo.txt (No such file or directory)

By taking the reference of this Question link below How to solve 'Client is immutable when created with the builder'? I do have a similar code structure wherein which am getting an error saying Unable to calculate MD5 hash public class LambdaFunctionS3 implements RequestHandler { @Override public S...
unknown
1

votes
1

answer
171

Views

Encoding Error Using AWS S3 Select with the AWS SDK for Ruby

I am trying to do the following: download the output of an Athena query from S3 (file.csv) gzip the output and upload to a different S3 location (file.csv.gz) use S3 Select from within the Ruby SDK to query the contents of file.csv.gz I always get the following error, always 'near byte 8192', even w...
Sam in Oakland
1

votes
0

answer
101

Views

Find Cloudwatch log group for a given resource

I'm creating a logs aggregator lambda to send Cloudwatch logs to a private log analysis service. Given the number of resources used by my employer, it was decided to create a subscription lambda that handles log group subscription to the aggregator. The solution works fine, but it requires to manual...
yorodm
1

votes
1

answer
145

Views

How to setup aws-sdk to get file content from a public file in s3 bucket?

I am trying to setup aws-sdk package to fetch file content in my s3 bucket, but every time I get this error missing credentials. I made the file as public in s3-bucket and also I had set the cors in bucket. I am not getting, How to get json object in json file from s3-bucket using aws-sdk?? and also...
Shashidhar.nk
1

votes
1

answer
39

Views

How to get user pool name from its id

When I log in to the user pool using username and password from my web application, I get id token. By parsing it, I can extract the Cognito group, username, user pool id, etc. by using python library. But Now I want to get the user pool name from these attributes. How can I get it? I need to find i...
Sazzad

View additional questions