API Gateway

The API Gateway security risk you need to pay attention to

When you deploy an API to API Gateway, throttling is enabled by default in the stage configurations. By default, every method inherits its throttling settings from the stage. Having built-in throttling enabled by default is great. However, the default method limits – 10k req/s with a burst of 5000 concurrent requests – matches your account …

The API Gateway security risk you need to pay attention to Read More »

All you need to know about caching for serverless applications

Caching is still important for serverless architectures. Just because AWS Lambda auto-scales by traffic, it doesn’t mean we can forget about caching. In this post, let’s break down by caching is still relevant for serverless and where we can apply caching in a serverless architecture. Caching is still VERY relevant. Yes, Lambda auto-scales by traffic. …

All you need to know about caching for serverless applications Read More »

How to include SNS and Kinesis in your e2e tests

Update 17/09/2019: based on feedback, I added a few more alternatives that do not require you to deploy additional Lambda functions to the e2e-test stage. Scroll to the end to find out more. Being event-driven is a key characteristic of a serverless architecture. Often our Lambda functions would publish events to SNS topics or Kinesis …

How to include SNS and Kinesis in your e2e tests Read More »

How to connect SNS to Kinesis for cross-account delivery via API Gateway

At DAZN (where I no longer work), the teams work with a number of third-party providers. They often have to synchronize data between different AWS accounts. SNS to SQS is the primary mechanism for these cross-account deliveries because: it was an established pattern within the organization DAZN engineers and third-party engineers are both familiar with …

How to connect SNS to Kinesis for cross-account delivery via API Gateway Read More »

How to create IP-protected endpoints with API Gateway and Lambda

If you haven’t been paying close attention you might have missed the API Gateway announcement for resource policies. It later played a key role in supporting API Gateway private endpoints – a way to put your API inside a private VPC. To configure resource policies with the Serverless framework, you need to upgrade to v1.28.0 or …

How to create IP-protected endpoints with API Gateway and Lambda Read More »

how to do fan-out and fan-in with AWS Lambda

In the last post, we look at how you can implement pub-sub with AWS Lambda. We compared several event sources you can use, SNS, Kinesis streams and DynamoDB streams, and the tradeoffs available to you. Let’s look at another messaging pattern today, push-pull, which is often referred to as fan-out/fan-in. It’s really two separate patterns …

how to do fan-out and fan-in with AWS Lambda Read More »

AWS Lambda – monolithic functions won’t help you with cold starts

After my post on monolithic functions vs single-purposed functions, a few people asked me about the effect monolithic functions have on cold starts, so I thought I’d share my thoughts here. The question goes something like this: Monolithic functions are invoked more frequently so they are less likely to be in cold state, while single-purposed …

AWS Lambda – monolithic functions won’t help you with cold starts Read More »

I’m afraid you’re thinking about AWS Lambda cold starts all wrong

When I discuss AWS Lambda cold starts with folks in the context of API Gateway, I often get responses along the line of: Meh, it’s only the first request right? So what if one request is slow, the next million requests would be fast. Unfortunately that is an oversimplification of what happens. Cold start happens once for …

I’m afraid you’re thinking about AWS Lambda cold starts all wrong Read More »

AWS Lambda – use the invocation context to better handle slow HTTP responses

With API Gateway and Lambda, you’re forced to use relatively short timeouts on the server-side: API Gateway have a 30s max timeout on all integration points Serverless framework uses a default of 6s for AWS Lambda functions However, as you have limited influence over a Lambda function’s cold start time and have no control over the amount of …

AWS Lambda – use the invocation context to better handle slow HTTP responses Read More »

By continuing to use the site, you agree to the use of cookies. more information

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.

Close