Skip to content

AWS re:Invent 2025 - Debug Lambda functions deployed in cloud like never before (CNS367)

This video introduces groundbreaking new features for debugging AWS Lambda functions, aiming to significantly improve the developer experience and productivity in serverless application development. Discover AWS Lambda's groundbreaking remote debugging capability, allowing developers to debug functions deployed in AWS cloud from local IDE for the first time. Learn how to set breakpoints, step through code line-by-line, inspect variables, and analyze call stacks in live Lambda functions.

Here are the key takeaways:

Traditional Debugging Challenges (0:45)

Debugging Lambda functions has traditionally been a time-consuming process involving repetitive logging, deployment, invocation, and log checking, which disrupts flow and impacts productivity. Key challenges include:

  • Setup friction (3:36): Setting up a local development environment for Lambda can take 30-40 minutes due to tool installation, code copying, credential configuration, and dependency setup.
  • Local testing limitations (4:09): Testing multi-service serverless applications locally is difficult, often requiring deployment to the cloud, leading to slower iterations.
  • Cloud-only issues (4:49): Some issues, such as VPC configurations, IAM permissions, and service-specific behaviors, only manifest in the cloud environment and cannot be fully replicated locally.

Transformative New Features (5:18)

To address these challenges, AWS has introduced three new features:

1. Seamless Console to IDE Transition (5:44)

This feature allows developers to transfer code and configuration from the AWS console to their local VS Code IDE with one click, reducing setup time from 30-40 minutes to under 30 seconds (8:32).

2. Local Stack Integration (9:41)

This new integration with LocalStack, a local cloud emulator in the VS Code IDE, enables 75-80% faster iterations for local testing (12:46). It allows developers to test multi-service workflows locally against emulated AWS services without deploying to the cloud.

3. Remote Debugging for Cloud Functions (14:12)

This unique feature allows developers to debug functions running in their AWS account directly from their local VS Code IDE. It significantly reduces debugging time by 80-85% (17:43), enabling the setting of breakpoints, stepping through code, and inspecting variables in live Lambda functions to quickly resolve cloud-specific issues like VPC and IAM problems.

Overall Impact and Best Practices (6:05)

These capabilities collectively accelerate serverless development cycles by 40%.

Security Considerations

  • Remote debugging should primarily be used in development or testing environments, not production
  • IAM policies can be used to prevent debugging in production accounts (33:13)

Fast Iteration

  • While remote debugging allows inspection, code changes require a new deployment
  • Tools like sam sync can automatically deploy code changes to the cloud for rapid iteration (34:27)

Technical Implementation

  • The remote debugging process temporarily modifies the function (e.g., attaching a layer, extending timeout, publishing a temporary version) to avoid disruptions to other traffic (35:03)
  • Options are available to optimize this, such as skipping version publishing for faster debugging in dedicated environments
  • Developers can also trigger remote debugging sessions using actual event sources like SQS queues or API Gateways (36:22)

Future and Community Feedback (38:01)

AWS has made the Lambda roadmap public on GitHub, inviting developers to provide feedback, suggest ideas, and vote on existing features to help shape future development.