SlideShare a Scribd company logo
1 of 33
Download to read offline
Stream Driven
London Serverless Conference 2018
Antonio Terreno - CTO

@javame
Quick one about myself
• Background in Consulting, coding for about 20 years now
• Second gig as CTO, third startup
• Wasn’t keen on Dynamo nor Node.js
• Always wanted to leverage events
• Tried microservices
What do we do
What do we do
What do we do
lab-stream-process
• We receive data every 10 seconds from each IOT device
• Firehose buffers it
• From API Gateway it goes into DynamoDB
• Kappa architecture
ingest phase
lab-stream-process
• Cascading DynamoDB table
• 10s, 5min, 30min, 1h, 1d, 1m
• A function of the time stamp of an energy reading determines the key
of the next dynamo key and so on
process phase
lessons learnt:
• If you want you can do immutable with any db, but I’d probably choose
a truly immutable one right now (kinesis?)
• If you are doing IOT you should strongly consider aggregating at edge
• 360*24*1000 = 8.64M requests…
• 360*24*1000000 = 8.64B requests to Api Gateway / min writes to DDB
lab-stream-crm
• An index in Kibana for Each table in Dynamo
• Plus ‘some’ aggregation
• The elastic search indexes power a bunch of Kibana Dashboard and
the internal user management system
manage phase
manage ui
Lessons learnt
• 1:1 mapping is easy and already quite powerful
• aggregating is hard (esp. mutable objects)
• Candidate #1 for 2019 rewrite
• Use Kinesis / Build a proper event log?
• Do a first round of aggregation in DDB?
• Leave it, it w and use EMR/Athena (sad face)
Alternative (no streams)
lab-stream-user
• Switch Status Change
• User Status Change
• 3rd parties integration “changing” our data
lab-stream-user
Lessons Learnt
• It would be hard to actually list all the streams, functions and draw a
flow diagram by now!
• Will we end up recessively calling a function updating the same record
and triggering the same event?!
• Needs either more visualisation of what’s going on or introduce more
order (SQS/Kinesis)
lab-cron-jobs
• Not everything can be real time…
• Sort of map-reduce using dynamo + streams + cron lambda
• Mainly to integrate with 3rd parties requiring ‘daily’/‘weekly’ batches
cron
Lessons Learnt
• This one works quite well, very simple, very observable
• Helps a lot also de-duping executions (such as double save on s3)
• Definitely a winner for us, but we need to be careful to do not overuse
it
lab-sqs-jobs
• Not everything should be decentralised
• Various different table source events…
• …Sending sqs messages to a single lambda
sqs
Nice side effect
Lessons Learnt
• SQS doesn’t show you in flight messages (sigh)
• We did avoid writing shared libraries for 1.5 years but now it’s time
• Usecase for https://bitsrc.io/ ?
Table Definition (terraform)
Valid View Types:
KEYS_ONLY 
NEW_IMAGE, 
OLD_IMAGE 
NEW_AND_OLD_IMAGES
Stream handler (serverless)
Starting positions:
TRIM_HORIZON
LATEST
AT_TIMESTAMP 
Stream handler (node.js)
Notes from AWS docs…
• No more than 2 processes at most should be reading from the same
Streams shard at the same time. Having more than 2 readers per
shard may result in throttling.
• All data in DynamoDB Streams is subject to a 24 hour lifetime
24 hours of λ
Further considerations
• Too decentralised: hard to keep track of
• Too centralised: next monolith YES if you are processing not if you are
event sourcing
• Streams make ‘complex’ architectures easy peasy (CQRS, Event
Sourcing, Kappa Architecture, etc)
Q&A
Thanks!

More Related Content

What's hot

Apache Incubator Samza: Stream Processing at LinkedIn
Apache Incubator Samza: Stream Processing at LinkedInApache Incubator Samza: Stream Processing at LinkedIn
Apache Incubator Samza: Stream Processing at LinkedInChris Riccomini
 
Nyc storm meetup_robdoherty
Nyc storm meetup_robdohertyNyc storm meetup_robdoherty
Nyc storm meetup_robdohertyRobert Doherty
 
ACDKOCHI19 - Become Thanos of the Lambda Land: Wield all the Infinity Stones
ACDKOCHI19 - Become Thanos of the Lambda Land: Wield all the Infinity StonesACDKOCHI19 - Become Thanos of the Lambda Land: Wield all the Infinity Stones
ACDKOCHI19 - Become Thanos of the Lambda Land: Wield all the Infinity StonesAWS User Group Kochi
 
DigitalOcean Microservices Talk Rocket Internet Conf '16
DigitalOcean Microservices Talk Rocket Internet Conf '16DigitalOcean Microservices Talk Rocket Internet Conf '16
DigitalOcean Microservices Talk Rocket Internet Conf '16Matthew Campbell
 
Experiences sharing about Lambda, Kinesis, and Postgresql
Experiences sharing about Lambda, Kinesis, and PostgresqlExperiences sharing about Lambda, Kinesis, and Postgresql
Experiences sharing about Lambda, Kinesis, and PostgresqlOkis Chuang
 
C# Async on iOS and Android - Miguel de Icaza, CTO of Xamarin
C# Async on iOS and Android - Miguel de Icaza, CTO of XamarinC# Async on iOS and Android - Miguel de Icaza, CTO of Xamarin
C# Async on iOS and Android - Miguel de Icaza, CTO of XamarinXamarin
 
Dask for Fast Distributed Batch Scoring of Computer Vision Workloads
Dask for Fast Distributed Batch Scoring of Computer Vision WorkloadsDask for Fast Distributed Batch Scoring of Computer Vision Workloads
Dask for Fast Distributed Batch Scoring of Computer Vision WorkloadsMathew Salvaris
 
Quarterly Technology Briefing, Manchester, UK September 2013
Quarterly Technology Briefing, Manchester, UK September 2013Quarterly Technology Briefing, Manchester, UK September 2013
Quarterly Technology Briefing, Manchester, UK September 2013Thoughtworks
 
Performance Tales of Serverless - CloudNative London 2018
Performance Tales of Serverless - CloudNative London 2018Performance Tales of Serverless - CloudNative London 2018
Performance Tales of Serverless - CloudNative London 2018☁️ Mikhail Shilkov
 
Introduction to the Serverless paradigm
Introduction to the Serverless paradigmIntroduction to the Serverless paradigm
Introduction to the Serverless paradigmAlex Casalboni
 
Reactive Xamarin. UA Mobile 2016.
Reactive Xamarin. UA Mobile 2016.Reactive Xamarin. UA Mobile 2016.
Reactive Xamarin. UA Mobile 2016.UA Mobile
 
Nextflow and AWS Batch - GCC/BOSC 2018
Nextflow and AWS Batch - GCC/BOSC 2018Nextflow and AWS Batch - GCC/BOSC 2018
Nextflow and AWS Batch - GCC/BOSC 2018Francesco Strozzi
 
JavaScript innovaties: ECMAScript 6 & 7
JavaScript innovaties: ECMAScript 6 & 7JavaScript innovaties: ECMAScript 6 & 7
JavaScript innovaties: ECMAScript 6 & 7Rick Beerendonk
 
Semi-automated bank transfers with Rails and Shinsei
Semi-automated bank transfers with Rails and ShinseiSemi-automated bank transfers with Rails and Shinsei
Semi-automated bank transfers with Rails and ShinseiDavid Stosik
 
Cloud Academy's AWS Hands on-labs
Cloud Academy's AWS Hands on-labsCloud Academy's AWS Hands on-labs
Cloud Academy's AWS Hands on-labsAlex Casalboni
 

What's hot (20)

EventMachine
EventMachineEventMachine
EventMachine
 
What's new with Visual Studio for Mac
What's new with Visual Studio for MacWhat's new with Visual Studio for Mac
What's new with Visual Studio for Mac
 
Apache Incubator Samza: Stream Processing at LinkedIn
Apache Incubator Samza: Stream Processing at LinkedInApache Incubator Samza: Stream Processing at LinkedIn
Apache Incubator Samza: Stream Processing at LinkedIn
 
Nyc storm meetup_robdoherty
Nyc storm meetup_robdohertyNyc storm meetup_robdoherty
Nyc storm meetup_robdoherty
 
ACDKOCHI19 - Become Thanos of the Lambda Land: Wield all the Infinity Stones
ACDKOCHI19 - Become Thanos of the Lambda Land: Wield all the Infinity StonesACDKOCHI19 - Become Thanos of the Lambda Land: Wield all the Infinity Stones
ACDKOCHI19 - Become Thanos of the Lambda Land: Wield all the Infinity Stones
 
React meets o OCalm
React meets o OCalmReact meets o OCalm
React meets o OCalm
 
Pywps
PywpsPywps
Pywps
 
DigitalOcean Microservices Talk Rocket Internet Conf '16
DigitalOcean Microservices Talk Rocket Internet Conf '16DigitalOcean Microservices Talk Rocket Internet Conf '16
DigitalOcean Microservices Talk Rocket Internet Conf '16
 
Experiences sharing about Lambda, Kinesis, and Postgresql
Experiences sharing about Lambda, Kinesis, and PostgresqlExperiences sharing about Lambda, Kinesis, and Postgresql
Experiences sharing about Lambda, Kinesis, and Postgresql
 
C# Async on iOS and Android - Miguel de Icaza, CTO of Xamarin
C# Async on iOS and Android - Miguel de Icaza, CTO of XamarinC# Async on iOS and Android - Miguel de Icaza, CTO of Xamarin
C# Async on iOS and Android - Miguel de Icaza, CTO of Xamarin
 
Dask for Fast Distributed Batch Scoring of Computer Vision Workloads
Dask for Fast Distributed Batch Scoring of Computer Vision WorkloadsDask for Fast Distributed Batch Scoring of Computer Vision Workloads
Dask for Fast Distributed Batch Scoring of Computer Vision Workloads
 
Quarterly Technology Briefing, Manchester, UK September 2013
Quarterly Technology Briefing, Manchester, UK September 2013Quarterly Technology Briefing, Manchester, UK September 2013
Quarterly Technology Briefing, Manchester, UK September 2013
 
Performance Tales of Serverless - CloudNative London 2018
Performance Tales of Serverless - CloudNative London 2018Performance Tales of Serverless - CloudNative London 2018
Performance Tales of Serverless - CloudNative London 2018
 
Introduction to the Serverless paradigm
Introduction to the Serverless paradigmIntroduction to the Serverless paradigm
Introduction to the Serverless paradigm
 
Reactive Xamarin. UA Mobile 2016.
Reactive Xamarin. UA Mobile 2016.Reactive Xamarin. UA Mobile 2016.
Reactive Xamarin. UA Mobile 2016.
 
Nextflow and AWS Batch - GCC/BOSC 2018
Nextflow and AWS Batch - GCC/BOSC 2018Nextflow and AWS Batch - GCC/BOSC 2018
Nextflow and AWS Batch - GCC/BOSC 2018
 
JavaScript innovaties: ECMAScript 6 & 7
JavaScript innovaties: ECMAScript 6 & 7JavaScript innovaties: ECMAScript 6 & 7
JavaScript innovaties: ECMAScript 6 & 7
 
Semi-automated bank transfers with Rails and Shinsei
Semi-automated bank transfers with Rails and ShinseiSemi-automated bank transfers with Rails and Shinsei
Semi-automated bank transfers with Rails and Shinsei
 
Zentral QueryCon 2018
Zentral QueryCon 2018Zentral QueryCon 2018
Zentral QueryCon 2018
 
Cloud Academy's AWS Hands on-labs
Cloud Academy's AWS Hands on-labsCloud Academy's AWS Hands on-labs
Cloud Academy's AWS Hands on-labs
 

Similar to Serverless conference-labrador-at-2018

John adams talk cloudy
John adams   talk cloudyJohn adams   talk cloudy
John adams talk cloudyJohn Adams
 
Cloud Security Monitoring and Spark Analytics
Cloud Security Monitoring and Spark AnalyticsCloud Security Monitoring and Spark Analytics
Cloud Security Monitoring and Spark Analyticsamesar0
 
AWS re:Invent presentation: Unmeltable Infrastructure at Scale by Loggly
AWS re:Invent presentation: Unmeltable Infrastructure at Scale by Loggly AWS re:Invent presentation: Unmeltable Infrastructure at Scale by Loggly
AWS re:Invent presentation: Unmeltable Infrastructure at Scale by Loggly SolarWinds Loggly
 
Infrastructure at Scale: Apache Kafka, Twitter Storm & Elastic Search (ARC303...
Infrastructure at Scale: Apache Kafka, Twitter Storm & Elastic Search (ARC303...Infrastructure at Scale: Apache Kafka, Twitter Storm & Elastic Search (ARC303...
Infrastructure at Scale: Apache Kafka, Twitter Storm & Elastic Search (ARC303...Amazon Web Services
 
Cooking a rabbit pie
Cooking a rabbit pieCooking a rabbit pie
Cooking a rabbit pieTomas Doran
 
Chirp 2010: Scaling Twitter
Chirp 2010: Scaling TwitterChirp 2010: Scaling Twitter
Chirp 2010: Scaling TwitterJohn Adams
 
Rails performance at Justin.tv - Guillaume Luccisano
Rails performance at Justin.tv - Guillaume LuccisanoRails performance at Justin.tv - Guillaume Luccisano
Rails performance at Justin.tv - Guillaume LuccisanoGuillaume Luccisano
 
Fixing twitter
Fixing twitterFixing twitter
Fixing twitterRoger Xia
 
Fixing Twitter Improving The Performance And Scalability Of The Worlds Most ...
Fixing Twitter  Improving The Performance And Scalability Of The Worlds Most ...Fixing Twitter  Improving The Performance And Scalability Of The Worlds Most ...
Fixing Twitter Improving The Performance And Scalability Of The Worlds Most ...smallerror
 
Fixing Twitter Improving The Performance And Scalability Of The Worlds Most ...
Fixing Twitter  Improving The Performance And Scalability Of The Worlds Most ...Fixing Twitter  Improving The Performance And Scalability Of The Worlds Most ...
Fixing Twitter Improving The Performance And Scalability Of The Worlds Most ...xlight
 
The challenges of live events scalability
The challenges of live events scalabilityThe challenges of live events scalability
The challenges of live events scalabilityGuy Tomer
 
Icinga Web 2 is more
Icinga Web 2 is moreIcinga Web 2 is more
Icinga Web 2 is moreIcinga
 
TenMax Data Pipeline Experience Sharing
TenMax Data Pipeline Experience SharingTenMax Data Pipeline Experience Sharing
TenMax Data Pipeline Experience SharingChen-en Lu
 
Springone2gx 2014 Reactive Streams and Reactor
Springone2gx 2014 Reactive Streams and ReactorSpringone2gx 2014 Reactive Streams and Reactor
Springone2gx 2014 Reactive Streams and ReactorStéphane Maldini
 
Lotuscript for large systems
Lotuscript for large systemsLotuscript for large systems
Lotuscript for large systemsBill Buchan
 
[DBA]_HiramFleitas_SQL_PASS_Summit_2017_Summary
[DBA]_HiramFleitas_SQL_PASS_Summit_2017_Summary[DBA]_HiramFleitas_SQL_PASS_Summit_2017_Summary
[DBA]_HiramFleitas_SQL_PASS_Summit_2017_SummaryHiram Fleitas León
 
Building Big Data Streaming Architectures
Building Big Data Streaming ArchitecturesBuilding Big Data Streaming Architectures
Building Big Data Streaming ArchitecturesDavid Martínez Rego
 
OpenNebulaConf 2013 - Monitoring of OpenNebula installations by Florian Heigl
OpenNebulaConf 2013 - Monitoring of OpenNebula installations by Florian Heigl OpenNebulaConf 2013 - Monitoring of OpenNebula installations by Florian Heigl
OpenNebulaConf 2013 - Monitoring of OpenNebula installations by Florian Heigl OpenNebula Project
 

Similar to Serverless conference-labrador-at-2018 (20)

John adams talk cloudy
John adams   talk cloudyJohn adams   talk cloudy
John adams talk cloudy
 
Cloud Security Monitoring and Spark Analytics
Cloud Security Monitoring and Spark AnalyticsCloud Security Monitoring and Spark Analytics
Cloud Security Monitoring and Spark Analytics
 
AWS re:Invent presentation: Unmeltable Infrastructure at Scale by Loggly
AWS re:Invent presentation: Unmeltable Infrastructure at Scale by Loggly AWS re:Invent presentation: Unmeltable Infrastructure at Scale by Loggly
AWS re:Invent presentation: Unmeltable Infrastructure at Scale by Loggly
 
Infrastructure at Scale: Apache Kafka, Twitter Storm & Elastic Search (ARC303...
Infrastructure at Scale: Apache Kafka, Twitter Storm & Elastic Search (ARC303...Infrastructure at Scale: Apache Kafka, Twitter Storm & Elastic Search (ARC303...
Infrastructure at Scale: Apache Kafka, Twitter Storm & Elastic Search (ARC303...
 
Collecting 600M events/day
Collecting 600M events/dayCollecting 600M events/day
Collecting 600M events/day
 
Cooking a rabbit pie
Cooking a rabbit pieCooking a rabbit pie
Cooking a rabbit pie
 
Chirp 2010: Scaling Twitter
Chirp 2010: Scaling TwitterChirp 2010: Scaling Twitter
Chirp 2010: Scaling Twitter
 
Rails performance at Justin.tv - Guillaume Luccisano
Rails performance at Justin.tv - Guillaume LuccisanoRails performance at Justin.tv - Guillaume Luccisano
Rails performance at Justin.tv - Guillaume Luccisano
 
Fixing twitter
Fixing twitterFixing twitter
Fixing twitter
 
Fixing_Twitter
Fixing_TwitterFixing_Twitter
Fixing_Twitter
 
Fixing Twitter Improving The Performance And Scalability Of The Worlds Most ...
Fixing Twitter  Improving The Performance And Scalability Of The Worlds Most ...Fixing Twitter  Improving The Performance And Scalability Of The Worlds Most ...
Fixing Twitter Improving The Performance And Scalability Of The Worlds Most ...
 
Fixing Twitter Improving The Performance And Scalability Of The Worlds Most ...
Fixing Twitter  Improving The Performance And Scalability Of The Worlds Most ...Fixing Twitter  Improving The Performance And Scalability Of The Worlds Most ...
Fixing Twitter Improving The Performance And Scalability Of The Worlds Most ...
 
The challenges of live events scalability
The challenges of live events scalabilityThe challenges of live events scalability
The challenges of live events scalability
 
Icinga Web 2 is more
Icinga Web 2 is moreIcinga Web 2 is more
Icinga Web 2 is more
 
TenMax Data Pipeline Experience Sharing
TenMax Data Pipeline Experience SharingTenMax Data Pipeline Experience Sharing
TenMax Data Pipeline Experience Sharing
 
Springone2gx 2014 Reactive Streams and Reactor
Springone2gx 2014 Reactive Streams and ReactorSpringone2gx 2014 Reactive Streams and Reactor
Springone2gx 2014 Reactive Streams and Reactor
 
Lotuscript for large systems
Lotuscript for large systemsLotuscript for large systems
Lotuscript for large systems
 
[DBA]_HiramFleitas_SQL_PASS_Summit_2017_Summary
[DBA]_HiramFleitas_SQL_PASS_Summit_2017_Summary[DBA]_HiramFleitas_SQL_PASS_Summit_2017_Summary
[DBA]_HiramFleitas_SQL_PASS_Summit_2017_Summary
 
Building Big Data Streaming Architectures
Building Big Data Streaming ArchitecturesBuilding Big Data Streaming Architectures
Building Big Data Streaming Architectures
 
OpenNebulaConf 2013 - Monitoring of OpenNebula installations by Florian Heigl
OpenNebulaConf 2013 - Monitoring of OpenNebula installations by Florian Heigl OpenNebulaConf 2013 - Monitoring of OpenNebula installations by Florian Heigl
OpenNebulaConf 2013 - Monitoring of OpenNebula installations by Florian Heigl
 

More from Antonio Terreno

More from Antonio Terreno (12)

Blend it up - leancamp london presentation
Blend it up - leancamp london presentationBlend it up - leancamp london presentation
Blend it up - leancamp london presentation
 
Programmer Anarchy
Programmer AnarchyProgrammer Anarchy
Programmer Anarchy
 
Socket.io
Socket.ioSocket.io
Socket.io
 
Agiler without a schema @forward
Agiler without a schema @forwardAgiler without a schema @forward
Agiler without a schema @forward
 
Mongo db
Mongo dbMongo db
Mongo db
 
J2Me Il Micro Mondo Java
J2Me Il Micro Mondo JavaJ2Me Il Micro Mondo Java
J2Me Il Micro Mondo Java
 
Domain Driven Design Javaday Roma2007
Domain Driven Design Javaday Roma2007Domain Driven Design Javaday Roma2007
Domain Driven Design Javaday Roma2007
 
Jc06 Antonio Terreno Fluidtime
Jc06 Antonio Terreno FluidtimeJc06 Antonio Terreno Fluidtime
Jc06 Antonio Terreno Fluidtime
 
Kommons
KommonsKommons
Kommons
 
From Amber To Green in Four Weeks
From Amber To Green in Four WeeksFrom Amber To Green in Four Weeks
From Amber To Green in Four Weeks
 
Time Boxing
Time BoxingTime Boxing
Time Boxing
 
Importance Of Being Driven
Importance Of Being DrivenImportance Of Being Driven
Importance Of Being Driven
 

Recently uploaded

Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraDeakin University
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):comworks
 
Next-generation AAM aircraft unveiled by Supernal, S-A2
Next-generation AAM aircraft unveiled by Supernal, S-A2Next-generation AAM aircraft unveiled by Supernal, S-A2
Next-generation AAM aircraft unveiled by Supernal, S-A2Hyundai Motor Group
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
Snow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter RoadsSnow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter RoadsHyundai Motor Group
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsMemoori
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Scott Keck-Warren
 
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your BudgetHyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your BudgetEnjoy Anytime
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersThousandEyes
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Alan Dix
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxnull - The Open Security Community
 

Recently uploaded (20)

Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning era
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):
 
Next-generation AAM aircraft unveiled by Supernal, S-A2
Next-generation AAM aircraft unveiled by Supernal, S-A2Next-generation AAM aircraft unveiled by Supernal, S-A2
Next-generation AAM aircraft unveiled by Supernal, S-A2
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
Snow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter RoadsSnow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter Roads
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial Buildings
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024
 
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your BudgetHyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
 

Serverless conference-labrador-at-2018

  • 1. Stream Driven London Serverless Conference 2018 Antonio Terreno - CTO
 @javame
  • 2. Quick one about myself • Background in Consulting, coding for about 20 years now • Second gig as CTO, third startup • Wasn’t keen on Dynamo nor Node.js • Always wanted to leverage events • Tried microservices
  • 6. lab-stream-process • We receive data every 10 seconds from each IOT device • Firehose buffers it • From API Gateway it goes into DynamoDB • Kappa architecture
  • 8. lab-stream-process • Cascading DynamoDB table • 10s, 5min, 30min, 1h, 1d, 1m • A function of the time stamp of an energy reading determines the key of the next dynamo key and so on
  • 10. lessons learnt: • If you want you can do immutable with any db, but I’d probably choose a truly immutable one right now (kinesis?) • If you are doing IOT you should strongly consider aggregating at edge • 360*24*1000 = 8.64M requests… • 360*24*1000000 = 8.64B requests to Api Gateway / min writes to DDB
  • 11. lab-stream-crm • An index in Kibana for Each table in Dynamo • Plus ‘some’ aggregation • The elastic search indexes power a bunch of Kibana Dashboard and the internal user management system
  • 14. Lessons learnt • 1:1 mapping is easy and already quite powerful • aggregating is hard (esp. mutable objects) • Candidate #1 for 2019 rewrite • Use Kinesis / Build a proper event log? • Do a first round of aggregation in DDB? • Leave it, it w and use EMR/Athena (sad face)
  • 16. lab-stream-user • Switch Status Change • User Status Change • 3rd parties integration “changing” our data
  • 18. Lessons Learnt • It would be hard to actually list all the streams, functions and draw a flow diagram by now! • Will we end up recessively calling a function updating the same record and triggering the same event?! • Needs either more visualisation of what’s going on or introduce more order (SQS/Kinesis)
  • 19. lab-cron-jobs • Not everything can be real time… • Sort of map-reduce using dynamo + streams + cron lambda • Mainly to integrate with 3rd parties requiring ‘daily’/‘weekly’ batches
  • 20. cron
  • 21. Lessons Learnt • This one works quite well, very simple, very observable • Helps a lot also de-duping executions (such as double save on s3) • Definitely a winner for us, but we need to be careful to do not overuse it
  • 22. lab-sqs-jobs • Not everything should be decentralised • Various different table source events… • …Sending sqs messages to a single lambda
  • 23. sqs
  • 25. Lessons Learnt • SQS doesn’t show you in flight messages (sigh) • We did avoid writing shared libraries for 1.5 years but now it’s time • Usecase for https://bitsrc.io/ ?
  • 26. Table Definition (terraform) Valid View Types: KEYS_ONLY  NEW_IMAGE,  OLD_IMAGE  NEW_AND_OLD_IMAGES
  • 27. Stream handler (serverless) Starting positions: TRIM_HORIZON LATEST AT_TIMESTAMP 
  • 29. Notes from AWS docs… • No more than 2 processes at most should be reading from the same Streams shard at the same time. Having more than 2 readers per shard may result in throttling. • All data in DynamoDB Streams is subject to a 24 hour lifetime
  • 31. Further considerations • Too decentralised: hard to keep track of • Too centralised: next monolith YES if you are processing not if you are event sourcing • Streams make ‘complex’ architectures easy peasy (CQRS, Event Sourcing, Kappa Architecture, etc)
  • 32. Q&A