SlideShare a Scribd company logo
1 of 23
Elena van
Engelen
Senior Solution Software Engineer @
PostNL
Event-driven high-performance dashboards with DynamoDB
materialized views and Kotlin Lambda
Elena van Engelen @ PostNL
Roll container
• Is used to
transport
packages &
letters
• Can be carried
by trucks
• Can be folded
when not in use
Where are all the roll
containers?
What do we
want to
achieve?
Where are Events
coming from?
• IoT events
• Scan events
What we are working
with:
• Fully serverless
• Large volume of events
• Sub second performance
• Process raw event data
• Data aggregation, filtering
and sorting
• Kotlin/Java Engineering
team
Event-driven high-
performance
dashboards
with
• DynamoDB materialized
views
• Kotlin Lambda
DynamoDB
Materialized
Views
Dashboard example
Example
materialized
view
DynamoDB Materialized
views - Wins
• Sub-second
performance
• Integration with
AppSync (VTL)
• Component
decoupling
• No logic in front-end
DynamoDB
Materialized views
- Challenges
• Query limitations
• Reusability
• Maintenance
overhead
Kotlin Lambdas
Why Kotlin?
• Fast & efficient execution
• Supports lightweight
concurrency
• AWS SDK Support
• Agnostic of AWS runtime
version
• Runs on ARM 64
• Multiplatform:
JVM/JS/Native(GraalVM)
Kotlin/JVM vs Kotlin/JS
vs Kotlin/GraalVM
Benchmark
• Generates DynamoDB
materialized view
• DynamoDB parallel scans
• Lightweight concurrency
• Lambda Power Tuner used
to generate executions
• Compared on different
memory size
Cold Start -
Kotlin/JVM vs.
Kotlin/JS
vs.
Kotlin/GraalVM
Average speed
Kotlin/JVM vs.
Kotlin/JS
vs.
Kotlin/GraalVM
Is
Kotlin/Native
the silver
bullet?
• AWS SDK v2 support for
GraalVM Native
• Arm64 architecture
• Need to provide runtime
• Kotlin AWS SDK for native
is WIP
Architecture
23
Conclusion
• For sub-second performance
• Snappy results for data aggregation & filtering
• Best used when access patterns are known
DynamoDB Materialized Views
• Go native!
• Reduce footprint
• Improve performance
Kotlin Lambdas
Questions ?

More Related Content

Similar to AWSCommunityDay.pptx

Vitalii Bondarenko and Eugene Berko "Cloud AI Platform as an accelerator of e...
Vitalii Bondarenko and Eugene Berko "Cloud AI Platform as an accelerator of e...Vitalii Bondarenko and Eugene Berko "Cloud AI Platform as an accelerator of e...
Vitalii Bondarenko and Eugene Berko "Cloud AI Platform as an accelerator of e...
Lviv Startup Club
 
Resume_sukanta_updated
Resume_sukanta_updatedResume_sukanta_updated
Resume_sukanta_updated
Sukanta Saha
 
Resume_APRIL_updated
Resume_APRIL_updatedResume_APRIL_updated
Resume_APRIL_updated
Sukanta Saha
 

Similar to AWSCommunityDay.pptx (20)

Ohio Devfest - Visual Analysis with GCP
Ohio Devfest - Visual Analysis with GCPOhio Devfest - Visual Analysis with GCP
Ohio Devfest - Visual Analysis with GCP
 
Serverless brewbox
Serverless   brewboxServerless   brewbox
Serverless brewbox
 
Vitalii Bondarenko and Eugene Berko "Cloud AI Platform as an accelerator of e...
Vitalii Bondarenko and Eugene Berko "Cloud AI Platform as an accelerator of e...Vitalii Bondarenko and Eugene Berko "Cloud AI Platform as an accelerator of e...
Vitalii Bondarenko and Eugene Berko "Cloud AI Platform as an accelerator of e...
 
AWS for the Java Developer
AWS for the Java DeveloperAWS for the Java Developer
AWS for the Java Developer
 
2016-06 - Design your api management strategy - AWS - Microservices on AWS
2016-06 - Design your api management strategy - AWS - Microservices on AWS2016-06 - Design your api management strategy - AWS - Microservices on AWS
2016-06 - Design your api management strategy - AWS - Microservices on AWS
 
Getting Started with Serverless Architectures
Getting Started with Serverless ArchitecturesGetting Started with Serverless Architectures
Getting Started with Serverless Architectures
 
Serverless without Code (Lambda)
Serverless without Code (Lambda)Serverless without Code (Lambda)
Serverless without Code (Lambda)
 
Containers, Serverless and Functions in a nutshell
Containers, Serverless and Functions in a nutshellContainers, Serverless and Functions in a nutshell
Containers, Serverless and Functions in a nutshell
 
Velocity NYC 2016 - Containers @ Netflix
Velocity NYC 2016 - Containers @ NetflixVelocity NYC 2016 - Containers @ Netflix
Velocity NYC 2016 - Containers @ Netflix
 
IT Talk «Microservices & Serverless Architectures», Alexander Chichenin (Solu...
IT Talk «Microservices & Serverless Architectures», Alexander Chichenin (Solu...IT Talk «Microservices & Serverless Architectures», Alexander Chichenin (Solu...
IT Talk «Microservices & Serverless Architectures», Alexander Chichenin (Solu...
 
AZUG Lightning Talk - Application autoscaling on Kubernetes with Kubernetes E...
AZUG Lightning Talk - Application autoscaling on Kubernetes with Kubernetes E...AZUG Lightning Talk - Application autoscaling on Kubernetes with Kubernetes E...
AZUG Lightning Talk - Application autoscaling on Kubernetes with Kubernetes E...
 
AMIS Oracle OpenWorld 2015 Review – part 3- PaaS Database, Integration, Ident...
AMIS Oracle OpenWorld 2015 Review – part 3- PaaS Database, Integration, Ident...AMIS Oracle OpenWorld 2015 Review – part 3- PaaS Database, Integration, Ident...
AMIS Oracle OpenWorld 2015 Review – part 3- PaaS Database, Integration, Ident...
 
Continuous Deployment into the Unknown with Artifactory, Bintray, Docker and ...
Continuous Deployment into the Unknown with Artifactory, Bintray, Docker and ...Continuous Deployment into the Unknown with Artifactory, Bintray, Docker and ...
Continuous Deployment into the Unknown with Artifactory, Bintray, Docker and ...
 
Resume_sukanta_updated
Resume_sukanta_updatedResume_sukanta_updated
Resume_sukanta_updated
 
Resume_APRIL_updated
Resume_APRIL_updatedResume_APRIL_updated
Resume_APRIL_updated
 
Resume april updated
Resume april updatedResume april updated
Resume april updated
 
Resume
ResumeResume
Resume
 
Microservices Architecture and Containers.
Microservices Architecture and Containers.Microservices Architecture and Containers.
Microservices Architecture and Containers.
 
Microservices: The Best Practices
Microservices: The Best PracticesMicroservices: The Best Practices
Microservices: The Best Practices
 
DockerCon SF 2015 : Reliably shipping containers in a resource rich world usi...
DockerCon SF 2015 : Reliably shipping containers in a resource rich world usi...DockerCon SF 2015 : Reliably shipping containers in a resource rich world usi...
DockerCon SF 2015 : Reliably shipping containers in a resource rich world usi...
 

Recently uploaded

+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
Health
 
CALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female service
CALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female serviceCALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female service
CALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female service
anilsa9823
 
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online  ☂️CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online  ☂️
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️
anilsa9823
 

Recently uploaded (20)

Vip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS Live
Vip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS LiveVip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS Live
Vip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS Live
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
 
Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Models
 
Right Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsRight Money Management App For Your Financial Goals
Right Money Management App For Your Financial Goals
 
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
 
How To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsHow To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.js
 
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
 
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
 
Software Quality Assurance Interview Questions
Software Quality Assurance Interview QuestionsSoftware Quality Assurance Interview Questions
Software Quality Assurance Interview Questions
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
 
CALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female service
CALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female serviceCALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female service
CALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female service
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTV
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
 
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
 
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf
 
Diamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionDiamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with Precision
 
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online  ☂️CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online  ☂️
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️
 
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AI
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AISyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AI
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AI
 
Microsoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdfMicrosoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdf
 

AWSCommunityDay.pptx

Editor's Notes

  1. Good evening! My name is Elena van Engelen and I am a Senior Software Engineer at PostNL. I started my software engineering career 22 years ago…. yes I know, I dont look that old ;). Since then I worked in quite a few fun companies, such as Sun Microsystems which since then merged with Oracle, KPN, and bol.com. And now I am having a lot of fun at PostNL with AWS Serverless cloud solutions. So today I’ll be talking about…
  2. MCP – Mission control platform But before I dive into our solution, let me give of bit a little context to the problem we are trying to solve. The main actor in this use case is a roll contaner – (no its not a container for ..)
  3. Roll containers are used everywhere at Post NL Is used to pick up customer packages Is used to transport packages Is used to group packages per destination to transport the packages to the distribution centers closest to the final destination of the packages Can be carried by trucks or rolled manually Can be folded to save storage when not in use
  4. How we keep track of the roll cages? More than 505 mil updates p/d The number of updates and movement of rollcontainers leads me to the PostNL problem
  5. One problem: Where are all the roll containers? Supply and demand Do we have too many available roll containers at a given location? Do we need more roll containers at a given location? Usage over time and predictions Do we have enough roll containers for peak season? Can we relocate roll containers in preparation for peak season? Lost roll containers Where are roll containers? Where were roll containers last seen? At PostNL we have over 300K Roll containers. But where are they and how are they used? Mission Control Platform aims to gain real time as well as historical insights into where roll containers are and how are they used, and make predictions
  6. One problem: Where are all the roll containers? Supply and demand Do we have too many available roll containers at a given location? Do we need more roll containers at a given location? Usage over time and predictions Do we have enough roll containers for peak season? Can we relocate roll containers in preparation for peak season? Lost roll containers Where are roll containers? Where were roll containers last seen? At PostNL we have over 300K Roll containers. But where are they and how are they used? Mission Control Platform aims to gain real time as well as historical insights into where roll containers are and how are they used, and make predictions
  7. We want to be able tp process the raw event data, analyse it, aggregate it into dashboards that help users on the floor to plan delivery processes better, streamline delivery processes and prevent any problems or delays. So how d you
  8. * Iot events from sensors of roll cages tell us there location (at a PotsNL location, in a truck, at a customer location) Scan events give us insites into the products in the roll cages, priority with which roll cage should be handled and process stage it is in QR code to process delivery, Iot is where they are now and scanning is where they are going to 4 mins
  9. * Full serverless Team Kotlin/Java With these contraints
  10. Which brings me to the main topics of my presentation, Dynamo DB materialised views & Kotlin Lambda (6 mins in)
  11. Considering all these requirements , and because in our case the access patterns are known, we chose dnamodb for its performance
  12. Maintenance overhead, for example in some simple query changes that in some databases like sequel database could just be generating a new query based on user selection without a need in any code changes. For materialised view such changes would offten require business logic changes that create such a materialised view
  13. Before I go into our reasons for choosing Koltin, I want to briefly introduce the language. Someone once asked me, isn’t Kotlin for front end development of android applications? Actually, Kotlin was invented 11 years ago as a cross-platform general purpose language and in 2019 was afficially adopted by Google for android app development. However it is widely used for backend development by a large number of big and small companies. Examples include: JetBrains, Rabobank, ING, Albert Hein, Jumbo, bol.com, NS , Google, Netflix, and Amazon used it to build Amazon Quantum Ledger Database (QLDB). Kotlin is loved for its clear and concise programming constructs, with less lines of code.
  14. Multiplatform: JVM/JS/Native(GraalVM) , these runtimes perform differently so we decided to compare them. Standard Kotlin Native we are waiting for Kotlin AWS SDK from AWS which is WIP, therefore choose GlaalVM in stad of LLVM for the native runtime because AWS SDK v2 supports it. Kotlin AWS SDK for LLVM based native is working in progress. GralVM uses static analysis of the code and uses Ahead of Time (AoT) compilation
  15. CDK – infrustructure as code. CDK in Kotlin is not generally available – its still WIP, we are using typecript You can run Kotlin on multiple platforms, on top of JVM on top of JS, but there are some tradeoffs between them and I’d like to focus on this in the next part of my presentation
  16. We see majod diff , on runtime duration and cold start, and then show the slide, Add bullet points animation, font bigger less text Add units Benchmark is lambda generate materialised view, put to the right 6 mins
  17. 1000MB JVM = 15 seconds & JS = 5 seconds & GraalVM 1,5 seconds 4000MB JVM = 5 seconds & JS 2 seconds & graal is 0,5 second , as we add memory the gap reduces
  18. 1000MB JS = almost 4 seconds & JVM = 1 second & 900 ms 4000MB JS 1 second & JVM = 0,460 seconds & GraalVM 300 ms
  19. https://aws.amazon.com/blogs/developer/aws-sdk-for-kotlin-alpha-release/ announced Ussed docker image
  20. This how we are using kotlin lambdas and dynamo 2 flows, real time and reporting. Real time shoes when roll cage has left the building in real time Dynamocaly generating materialised views by pre processing lambda AppSynch works very well with dynamo DB , we use Velocity templates
  21. 1 min If you want sub second performance, and access patterns are known, then materialised views are a good option. It does not need to be a front end application that consumes the materialised views, it can also be a backend application that needs the data. Go Native with Kotlin Lambdas to reduce cold start & improve performance
  22. 2 mins