Questions tagged [amazon-lambda]

This tag is for questions about Amazon Web Services' "Lambda".

AWS Lambda lets you run code on the Amazon cloud without provisioning or managing servers. Lambda takes care of everything required to run and scale your uploaded code with high availability. You can set up your code to automatically trigger from other AWS services or call it directly from any web or mobile app, and pay only for the compute time used.

154 questions
4
votes
2 answers

AWS Route53 & Lambda: Redirecting Naked HTTP requests to HTTPS WWW for a serverless application

Problem I have a site running on a 'serverless' AWS Lambda function. Route53 routes requests to the API Gateway which connects to the Lambda function. The problem with this is that you can't setup traditional server redirects. Example As an…
4
votes
1 answer

what is "period" column represent in AWS cloudwatch metric graph?

I created the number metric graph for lambda function like latency, the total number of invocation etc. I also created a custom metric filter which will give me errors and warnings count in logs for time range we specify. Everything is working and…
4
votes
1 answer

AWS lambda fails to access internet, despite having proper IGW, NAT and routing table entries?

I am experimenting with AWS Lambda, with a small piece of code that would fetch some files from S3. Unfortunately I cannot even access internet resources when I put my Lambda function into a VPC, although I believe the VPC is configured properly. I…
4
votes
1 answer

AWS cloudwatch not triggering lambda function

I am trying to create a scheduling system for my EC2 instances using lambda functions to start/shutdown the instances and Cloudwatch to trigger and schedule them. The problem is Cloudwatch, not triggering the lambda functions when the functions are…
4
votes
2 answers

Creating a CloudWatch Scheduled Event with arbitrary data in the `detail` field

I'd like to run a Lambda task on a fixed schedule, with some configuration passed into it by the CloudWatch Scheduled Event that triggers the task. Looking at the documentation here, I can see that Cloudwatch Scheduled Events look like this: { …
Chris
  • 347
  • 3
  • 6
  • 13
4
votes
1 answer

Binary body passthrough from API Gateway to Lambda

I think I've closely followed the documentation and tutorials I've found so far, but I still get this to work. I just can't convince AWS not to touch the binary data I'm posting in the body. In my app, I'm setting both the Content-Type and Accept…
Ates Goral
  • 57
  • 1
  • 9
4
votes
0 answers

What are the advantages of using AWS Elastic Transcoder (for WAV to AAC) vs Lambda and ffmpeg?

I did a price comparison between using Elastic Transcoder vs Lambda for WAV-to-AAC conversion. I have to say, AWS ET is significantly pricier than Lambda. A 9-minute audio file transcoded using ET: $0.04 The same file transcoded on a 1536MB Lambda…
ffxsam
  • 433
  • 2
  • 4
  • 9
3
votes
2 answers

AWS restore_db_cluster_from_snapshot yet no instances

I'm writing an AWS lambda function to take my most recent snapshot of our production database and restore it as a new DB. This worked fine as a RDS instance but we recently switched our main DB to Aurora and its a cluster not an instance. I looked…
3
votes
1 answer

A CloudFormation stack hangs on creation or deletion when custom resource lambda is broken

I have noticed that if a template contains custom resource lambda, which is broken (there is a runtime error, or it doesn't properly send a response body), then the CloudFormation stack hangs on the creation phase on this particular resource. When…
3
votes
1 answer

Can't deploy same lambda in multiple regions from s3 bucket

We are deploying a lambda using CloudFormation SAM templates. We would like to package the lambda into an S3 bucket, then deploy the AWS::Serverless::Function in multiple regions. However, lambda code must reside in the same region as where it's…
mdarwin
  • 121
  • 10
3
votes
2 answers

AWS Lambda automatically use latest layer

We have a server-less stack that relies on multiple AWS Lambdas to perform tasks. To help make code re-usable we have multiple Lambda Layers shared across the Lambdas. Our issue is, when we make a change to a layer, it creates a new version of the…
react-dev
  • 213
  • 2
  • 5
2
votes
1 answer

Update Amazon RDS Certificate SSL Issue with MySQL Lambda

Like many people I have updated my Amazon RDS Certificate to CA_2019 from CA_2015. At first everything seemed fine but later on checking I noticed the mysql lambda function which i wrote to query the database is not working anymore.. Lambda is using…
2
votes
1 answer

AWS: Connecting Lambda to a Secret doesn't work

I am trying to connect a Lambda to a secret as per AWS docs. I set the following resource-based policy on the secret, and verified that it has indeed been set: { "Version": "2012-10-17", "Statement": [{ "Effect": "Allow", …
2
votes
1 answer

How to measure GB-seconds for AWS EC2

We are researching on the possibilities of moving our app from EC2 based implementation to AWS lambda. We are trying to project how much money we will be saving if we do so. The lambda pricing says it gives 400000 GB-seconds free per month and a…
2
votes
1 answer

AWS CloudFront - redirect root domain requests

First time poster on serverfault, apologies if this is in the wrong place. I have a website that I am trying to set up on AWS CloudFront. It is currently configured to serve static web content from S3, this is then picked up and served via…
1
2
3
10 11