HomeCloud ComputingCloudTweaks | Utilizing AWS AppConfig Extensions

CloudTweaks | Utilizing AWS AppConfig Extensions


Utilizing function flags and different runtime configuration sorts is a fast-evolving expertise phase. Adjusting your software program habits with a minor configuration replace as a substitute of deploying code lets groups transfer sooner and extra safely. Moreover, releasing a function utilizing a function flag permits engineering groups to activate options to a restricted set of customers after which measure the affect. The potential can immediately flip off and roll again if one thing goes improper, considerably limiting the change’s affect. At Amazon, we name the apply of utilizing function flags and runtime configuration, Steady Configuration.

AWS AppConfig began in 2017 as an inner software for Amazon. It shortly turned a top-used service for inner groups that wished a secure and measured solution to handle their function flags and operational flags. In 2019, AWS launched AppConfig for exterior prospects. This providing had the entire discovered classes and finest practices for using runtime configuration and have flags constructed into the product. Now we’re asserting AppConfig Extensions, which permits prospects to increase the ability of dynamic configuration and have flags in new and progressive methods. After studying this put up, you’ll perceive what AppConfig Extensions are, what issues they clear up, and what extension sorts you possibly can construct.

What are AppConfig Extensions?

Because the inner launch of AppConfig in 2017, and the exterior launch in 2019, we’ve added many options that prospects have requested. These embrace integrations with Lambda, AWS CodePipeline, and Amazon CloudWatch, in addition to releasing an opinionated format for function flags in 2021. We’ve innovated on behalf of our prospects, and we regularly obtain many requests for brand new performance. One statement we’ve had on these requests is that there are features to them that make them impractical to construct in a generic manner. One other statement was seeing how some prospects have constructed options on high of our service in ways in which had been particular to their very own workflows. Nevertheless, as a substitute of getting the AppConfig crew construct all new options as requested, we determined to empower others to construct on high of AppConfig. We knew that permitting different engineers, each inner and exterior, to make the most of a framework to increase AppConfig could be a pressure multiplier, plus give the liberty to assist integrations into customer-specific programs and processes.

AppConfig Extensions are add-ons to AppConfig that improve the ability and security of the primary AppConfig service. Managing configuration usually follows a lifecycle much like growing code: create/replace, validate/check, deploy, and monitor. The AppConfig Extension framework exposes hooks, known as motion factors, at every of those lifecycle milestones. When an motion level is triggered, no matter actions (e.g. calling a Lambda perform) are outlined within the set of AppConfig Extensions relevant at that lifecycle step might be invoked.

The framework permits for simpler integration of different companies (AWS and in any other case) to assist prospects enhance their velocity and security. Over the approaching months and years, we anticipate the variety of extensions to develop considerably, offering bespoke options created by AWS and our prospects.

Self-authored AppConfig Extensions

To supply a way of the performance that AppConfig Extensions can present, we’ll illustrate some examples equivalent to the lifecycle steps talked about above, beginning with the primary section: the creation of configuration information. Let’s say, for instance, that you simply wished so as to add a timestamp inside your hosted configuration information’s JSON every time it will get up to date. With an extension, you would hook into the PRE_CREATE_HOSTED_CONFIGURATION_VERSION motion level and write a easy AWS Lambda to insert the timestamp. Chances are you’ll subsequent resolve that you simply wish to export a duplicate of every model of your hosted configuration information right into a supply repository like Github, no matter its information format. You may create one other extension that additionally hooks into the PRE_CREATE_HOSTED_CONFIGURATION_VERSION motion level to export the hosted information into your repo each time the info adjustments. Whereas each extensions could possibly be related to a specific Configuration Profile, you would as a substitute affiliate this extension to an Software which can trigger it to mechanically apply to all hosted Configuration Profiles in your Software, even these created at a later date. Persevering with down the lifecycle steps, you may must merge information from one other supply, resembling a legacy configuration database, into your configuration information earlier than it deploys. Your extension would comprise an motion that triggers at PRE_START_DEPLOYMENT and calls a Lambda to retrieve the info and merge it into the to-be-deployed model of configuration information. As a remaining instance, you would set off check automation to run after you’ve deployed new configuration information by hooking into the ON_DEPLOYMENT_COMPLETE motion level that publishes a message to an SNS subject.

Out there Motion Factors

As famous above, an extension can hook into AppConfig Extension motion factors. Presently, AppConfig exposes the next motion factors:

Motion level Description
PRE_CREATE_HOSTED_CONFIGURATION_VERSION happens when an AppConfig hosted configuration is created or up to date, however simply earlier than it’s saved
PRE_START_DEPLOYMENT happens simply earlier than a deployment begins
ON_DEPLOYMENT_START happens when an AppConfig deployment begins
ON_DEPLOYMENT_STEP happens throughout a deployment, and increments relying on the deployment technique step proportion
ON_DEPLOYMENT_BAKING happens after the deployment completes, however bake time (if specified) begins
ON_DEPLOYMENT_COMPLETE happens after the deployment and bake time is full
ON_DEPLOYMENT_ROLLED_BACK happens if a deployment roll again initiates

AWS-authored AppConfig Extensions

Along with the AppConfig extensions you create, we have now a handful of extensions which might be already out there so that you can use. The AppConfig Notification Extensions enable prospects to be notified for the ON_DEPLOYMENT_START, ON_DEPLOYMENT_COMPLETE, and ON_DEPLOYMENT_ROLLEDBACK motion factors. Clients can have these notifications despatched to Amazon EventBridge, Amazon Easy Notification Service (Amazon SNS), or Amazon Easy Queue Service (Amazon SQS). We even have an AppConfig Characteristic Flags Helper extension, which performs a job in our Characteristic Flags function and is mechanically related to Characteristic Flag Configuration Profiles, in addition to a Jira Integration extension that creates and manages Jira Points related to your function flags.

Trying forward

This preliminary launch of AppConfig Extensions lays the muse for the platforming of configuration information and have flags. Nevertheless, that is simply the beginning. Sooner or later, we anticipate to launch many AWS-owned extensions and a few third-party extensions. Furthermore, we’re trying ahead to speaking to prospects concerning the extensions they’ve authored, and persevering with to innovate with our prospects in how they’re using function flags and runtime configuration.

Get began with AWS AppConfig Extensions.

By Steve Rice and Jonathan (JT) Thompson

Jonathan Thompson

Jonathan (JT) Thompson is a Principal Engineer at AWS. He has labored with many groups throughout AWS to construct and prolong their companies, with a very deep concentrate on API Gateway, Lambda, and, most just lately, AWS AppConfig.

Steve Rice

Steve is the Principal Product Supervisor for AWS AppConfig. He’s loves constructing merchandise that enhance individuals’s lives, and is keen about function flags and dynamic configuration, and serving to builders get their code to customers as shortly and safely as potential.

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Most Popular

Recent Comments