Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Safe Lambda Deployments - Albany NY - 2018-11-15
Search
sullis
November 15, 2018
Technology
1
210
Safe Lambda Deployments - Albany NY - 2018-11-15
AWS User Group
Albany NY
November 15, 2018
sullis
November 15, 2018
Tweet
Share
More Decks by sullis
See All by sullis
Amazon S3 - Portland Java User Group 2024-09-17
sullis
0
53
Netty - Montreal Java User Group 2024-05-21
sullis
0
130
Netty Chicago Java User Group 2024-04-17
sullis
0
800
Java 21 - Portland Java User Group 2023-10-24
sullis
0
280
Microbenchmarking with JMH - Portland 2023-03-14
sullis
0
130
Code generation on the Java VM 2022-04-19
sullis
0
110
Mockito 2022-01-25
sullis
0
170
GitHub Actions 2021-12-16
sullis
0
35
Apache Struts and the Equifax data breach 2021-06-03
sullis
0
54
Other Decks in Technology
See All in Technology
Engineer Career Talk
lycorp_recruit_jp
0
170
OTelCol_TailSampling_and_SpanMetrics
gumamon
1
160
20241120_JAWS_東京_ランチタイムLT#17_AWS認定全冠の先へ
tsumita
2
270
初心者向けAWS Securityの勉強会mini Security-JAWSを9ヶ月ぐらい実施してきての近況
cmusudakeisuke
0
120
EventHub Startup CTO of the year 2024 ピッチ資料
eventhub
0
120
RubyのWebアプリケーションを50倍速くする方法 / How to Make a Ruby Web Application 50 Times Faster
hogelog
3
940
ドメインの本質を掴む / Get the essence of the domain
sinsoku
2
150
データプロダクトの定義からはじめる、データコントラクト駆動なデータ基盤
chanyou0311
2
310
【Startup CTO of the Year 2024 / Audience Award】アセンド取締役CTO 丹羽健
niwatakeru
0
1k
SSMRunbook作成の勘所_20241120
koichiotomo
2
140
AIチャットボット開発への生成AI活用
ryomrt
0
170
AWS Lambda のトラブルシュートをしていて思うこと
kazzpapa3
2
180
Featured
See All Featured
A Philosophy of Restraint
colly
203
16k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
44
6.8k
The Language of Interfaces
destraynor
154
24k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
506
140k
Making the Leap to Tech Lead
cromwellryan
133
8.9k
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
6
410
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
329
21k
What's in a price? How to price your products and services
michaelherold
243
12k
Designing for Performance
lara
604
68k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
246
1.3M
Building Adaptive Systems
keathley
38
2.3k
Building Better People: How to give real-time feedback that sticks.
wjessup
364
19k
Transcript
Sean Sullivan November 15, 2018 AWS User Group Albany NY
SAFE LAMBDA DEPLOYMENTS
software engineer Portland Oregon back office systems Hudson’s Bay Company
About me
None
saksfifthavenue.com saksoff5th.com lordandtaylor.com thebay.com
saksfifthavenue.com
undifferentiated heavy lifting AWS
provisioning servers AWS serverless
None
None
system plumbing business logic
None
None
HBC 2018 microservice architecture multi-tenant services increased adoption of AWS
Lambda safe deployments
None
HBC email types • order acknowledgement • order shipment partial
• order shipment full • order cancel • ready for pickup in store
Queue consumer Event queue Email Dashboard UI Email Sender Email
Render External Email Provider Feature Flag service
Email Render Product Detail service Delivery Date Estimation service request
HTML Feature Flag service
HBC email system • multi-tenant design • Cloudwatch Metrics •
Cloudwatch Alerts
HBC email system • code coverage threshold • components deployed
independently • safe deployments
aws-cli
$ brew install aws-cli
aws cloudformation package \ --template-file my-template.yaml \ --s3-bucket mycorp-codedeploy \
--s3-prefix my-lambda-func/jars \ --output-template-file package/2325bd1e.yaml
aws cloudformation deploy \ --template-file package/2325bd1e.yaml \ --stack-name mylambda-func—dev \
--parameter-overrides Stage=dev \ --region us-east-1 \ --capabilities CAPABILITY_IAM \ --notification-arns arn:aws:sns:us- east-1:123456789:myteam-cf-notifications
Mark Zuckerberg
Move Fast and Break Things Move Slow and Don’t Break
Things
Move Fast and Don’t Break Things Move Purposefully and Fix
Things
manual testing automated testing
how often do you release code to production?
safe AWS Lambda deployments?
https://www.youtube.com/watch?v=UIp6sLyvoC0
None
None
Traffic Shifting
You can now shift incoming traffic between two AWS Lambda
function versions based on pre-assigned weights. You can now also use AWS CodeDeploy to automatically manage the rollout of new function versions. This allows you to gradually shift traffic between two versions source: aws.amazon.com
Traffic Shifting configurations AllAtOnce Canary10Percent30Minutes Canary10Percent5Minutes Canary10Percent10Minutes Canary10Percent15Minutes
Linear10PercentEvery10Minutes Linear10PercentEvery1Minute Linear10PercentEvery2Minutes Linear10PercentEvery3Minutes Traffic Shifting configurations
all-at-once traffic shifting gradual traffic shifting
aws cloudformation deploy \ --template-file package/2325bd1e.yaml \ --stack-name mylambda-func—dev \
--parameter-overrides Stage=dev \ --parameter-overrides DeploymentPref=AllAtOnce \ --region us-east-1 \ --capabilities CAPABILITY_IAM \ --notification-arns arn:aws:sns:us- east-1:123456789:myteam-cf-notifications
Traffic Hooks
AWS traffic hooks • PreTraffic hook • PostTraffic hook
AWS CodeDeploy UI https://console.aws.amazon.com/codesuite/codedeploy/deployments
https://github.com/awslabs/serverless-application-model/pull/605
Future work at HBC additional validation logic in Pre Traffic
hook implement Post Traffic hook utilize AWS Cloud9 IDE
Final thoughts
traffic shifting
small incremental releases
engineering velocity is a competitive advantage
The end
None