Share
Embed
Load Testing Event-Driven Serverless Backends
Slides for the talk given for ServerlessDays ANZ 2023 in Melbourne, Australia.
Renaldi Gondosubroto
April 10, 2023
Transcript
23 slides
-
AGENDA Introduction Motivation Planning for Load Testing Implementation for Load
Testing Demo Key Takeaways ServerlessDays ANZ 2023 -
A BIT ABOUT ME 3 Load Testing Event-Driven Serverless Backends
Renaldi Gondosubroto Software Developer for Seek Limited @Renaldig @renaldigondosubroto ServerlessDays ANZ 2023 -
MOTIVATION Load Testing Event-Driven Serverless Backends 4 More workloads shifted
to serverless after the pandemic Determining the optimal loads of a system Identifying bottlenecks and potential issues early on ServerlessDays ANZ 2023 -
PLANNING FOR LOAD TESTING Load Testing Event-Driven Serverless Backends 5
1 Define the test goals 2 Identify the system(s) that will be under test 3 Design the test plan 4 Create the testing environment 5 Configure the testing tools 6 Execute the test 7 Analyze the results that are obtained 8 Optimize and Repeat ServerlessDays ANZ 2023 -
QUESTIONS TO ASK Load Testing Event-Driven Serverless Backends 6 How
much load can my application withstand? Can my application handle X load? Does my application’s scaling work properly? How is my application’s behaviour when having a constant high load? Is my application working? ServerlessDays ANZ 2023 -
TESTING LIFECYCLE Load Testing Event-Driven Serverless Backends 7 Init Setup
VU Code Teardown ServerlessDays ANZ 2023 -
DEFINING THRESHOLDS AND METRICS Load Testing Event-Driven Serverless Backends 8
Metrics Understanding metrics such as average response time, error rate, concurrent users Thresholds Setting thresholds such as a proportion that is allowed to return an error, having an endpoint return in a certain period ServerlessDays ANZ 2023 -
UNDERSTANDING WRITING PERFORMANCE TESTS Load Testing Event-Driven Serverless Backends 9
HTTP request against system that is being tested Load configuration for controlling the duration of the tests and virtual users (VUs) Provided performance goal or service level objective ServerlessDays ANZ 2023 -
Load Testing Event-Driven Serverless Backends 13 WORKING IN CODEBUILD AWS
IAM GitHub Actions CICD Workflow GitHub Repo Git Push Amazon S3 AWS CodeDeploy Auto Scaling Group ServerlessDays ANZ 2023 -
Load Testing Event-Driven Serverless Backends 14 APPLICATION PROCESS FLOW GET
/vendors GetVendors Function Vendors Table CloudWatch SNS Email Notification ServerlessDays ANZ 2023 -
CREATING A BUILDSPEC YAML FILE Load Testing Event-Driven Serverless Backends
15 ServerlessDays ANZ 2023 -
PUTTING EVENTBRIDGE INTO THE MIX Load Testing Event-Driven Serverless Backends
17 Create schedule for running at given times Automated load testing without the need of manual execution Ensure configuration is well-prepared for this ServerlessDays ANZ 2023 -
PUTTING EVENTBRIDGE INTO THE MIX CONT. 18 Load Testing Event-Driven
Serverless Backends AWS CodeBuild AWS CodeCommit AWS EventBridge ServerlessDays ANZ 2023 -
COMMON PITFALLS AND WHAT TO DO Load Testing Event-Driven Serverless
Backends 20 Not simulating real world conditions Improperly configuring the test environment Not having the proper scaling Not monitoring the system during the test Not adequately testing the system holistically ServerlessDays ANZ 2023 -
WHERE TO FROM HERE? Load Testing Event-Driven Serverless Backends 21
Increased use of automation More use of cloud-based load testing solutions More use of ML and AI to identify potential issues and bottlenecks ServerlessDays ANZ 2023 -
KEY TAKEAWAYS Load Testing Event-Driven Serverless Backends 22 ROI •
Cost saving within teams in working with deployments • Visualize savings made with AWS Cost Explorer • Engage in conversations around impact on scaling CUSTOMIZABILITY • Vary based on different workloads • Coordinate testing needs alongside AWS representatives EASY TO IMPLEMENT • Many similar load testing tools (e.g. Artillery) • Optimize for differing patterns and load tests ServerlessDays ANZ 2023