How do you separate deployments from releases when you don't manage the entire tech stack? In this webinar Brian Rinaldi, Developer Relations Engineer at LaunchDarkly and Welly Siauw, Principal Partner Solutions Architect at AWS, shared how developers can integrate feature flags into the release of a serverless web application to get granular control over releases.
We've captured highlights from the presentation below, but be sure to check out the video for Brian's full demo of how to set up LaunchDarkly in AWS Serverless.
What is AWS Serverless?
Welly Siauw, Principal Partner Solutions Architect at AWS, kicked things off by explaining the concept of serverless. For context, studies in recent years have shown that leaders say a lot of developer time is being spent on operations and maintenance rather than innovation. While there are a number of causes behind this challenge, serverless technology addresses one: with AWS Serverless, developers can offload the undifferentiated heavy lifting on infrastructure—the work of maintaining the security and availability of their infrastructure—and focus on application code instead. Developers can use services that enable them to run code, manage data, and integrate applications without managing servers at all.
What is AWS Lambda?
AWS Lambda is a compute service that enables you to run application functions without provisioning or managing servers. As part of a serverless strategy, AWS Lambda offers agility (scaling up or down dynamically in response to demand) and cost-effectiveness (paying only for compute time used). By offloading security responsibilities to AWS you also free up more developer time for innovation.
Development and deployment of Lambda functions are similar to regular applications, with various tools and frameworks available for development, testing, and deployment. Welly also explained different deployment strategies for releasing new versions of Lambda functions, such as canary deployments and versioning with aliases.
To take full advantage of Lambda functions, combining them with feature flags can help ensure operational consistency and reduce dependencies when releasing new features.
What is feature management?
Brian Rinaldi, Developer Relations Engineer at LaunchDarkly, took over to give an overview of feature flags and feature management, before diving into how to combine these with AWS Lambda.
"The key thing to think about is that feature flags help you separate the concept of deploying and release," Brian explained. "I could deploy a piece of code to production, but it might not actually be running in production because it's wrapped in a flag. This helps remove risk from deploys and minimizes the risk of releases because if a feature isn't working properly once it's released, we can actually turn that off remotely without doing any kind of rollbacks or redeploys. This separation of deploy and release can really change the way you build and operate."
Targeted rollouts and canary launches enable safer testing in production. More mature operational practices also become attainable, by simplifying complex tasks like migrations and making teams more open to upgrades or adopting new tools that enhance application performance. Features like kill switches and immediate feature flag updates ensure that any issues can be quickly addressed, and progressive rollouts and testing in production enable confidence in the functionality of launched features.
Feature management + Lambda functions
For feature management to work well, it has to be integrated into all layers of your application, which requires coordination of your front end, back end, and operations. That's where serverless computing comes into play. By integrating into services like Lambda or working with DynamoDB, you can improve the overall success of your feature flag adoption across your application.
"You can use the same feature flag across all the different pieces of your application," Brian explained. "That one flag that turns the feature on in the UI could also turn on the code that runs that feature in the back end of your application. Because you have the same SDKs that are all talking to the same LaunchDarkly instance, you can reuse that flag."
For a full demo of how AWS Lambda works with LaunchDarkly to unlock the full potential of feature management with serverless, and to see how to get started, you can catch the full webinar here.