SlideShare une entreprise Scribd logo
1  sur  28
Télécharger pour lire hors ligne
Caching patterns
for lazy devs
for lazy loading
Luigi Fugaro
Solution Architect @Redis
More than 20 years of experience in IT.
I started my career in 1998 as a webmaster doing HTML, JavaScript,
Applets, and some graphics with Paint Shop Pro.
I then switched to Delphi, Clipper, Visual Basic, and then he finally started
working on real Java projects. I’ve been developing all kinds of web
applications, dealing with both backend and frontend frameworks.
Jumping from project to project, from company to company, in 2012 I
joined Red Hat as a consultant. An amazing experience lasted more than
7 years.
Next, I had the privilege to learn all about observability and monitoring
with Datadog working with all kind of companies.
In 2021 I received a call from Redis, a technology made in Italy, where
apps and data merge together and they enjoy it.
Luigi Fugaro
Solutions Architect
luigi.fugaro@redis.com
#VOXXEDTICINO 2
❖ Caching is everywhere
❖ Software Architecture
❖ Caching Patterns
❖ Demo
❖ Q&A
Agenda
#VOXXEDTICINO 3
Caching is everywhere
4
#VOXXEDTICINO 5
Caching is everywhere
❖ The first time I heard about cache,
it was about browser cache with
Netscape Navigator.
#VOXXEDTICINO 6
❖ The first time I heard about cache,
it was about browser cache with
Netscape Navigator.
❖ Second time for CPUs, L1&L2
Cache and Cache Mode
(Write-Back).
Caching is everywhere
#VOXXEDTICINO 7
❖ The first time I heard about cache,
it was about browser cache with
Netscape Navigator.
❖ Second time for CPUs, L1&L2 Cache
and Cache Mode (Write-Back).
❖ Third time for HTTP Server Cache
and CDN for “static-content”
(images/js/css/…).
Caching is everywhere
#VOXXEDTICINO 8
❖ The first time I heard about cache,
it was about browser cache with
Netscape Navigator.
❖ Second time for CPUs, L1&L2 Cache
and Cache Mode (Write-Back).
❖ Third time for HTTP Server Cache
and CDN for “static-content”
(images/js/css/…).
❖ Session management,
One-Time-Password, and so on…
Caching is everywhere
#VOXXEDTICINO 9
❖ The first time I heard about cache,
it was about browser cache with
Netscape Navigator.
❖ Second time for CPUs, L1&L2 Cache
and Cache Mode (Write-Back).
❖ Third time for HTTP Server Cache
and CDN for “static-content”
(images/js/css/…).
❖ Session management,
One-Time-Password, and so on…
❖ On backend, L1 Cache (session)
and L2 Cache with data access
framework such as Hibernate.
Caching is everywhere
10
Software Architecture
https://www.microservices.com/reference-architecture/
#VOXXEDTICINO 11
Software Architecture
https://martinfowler.com/articles/microservices/images/sketch.png
#VOXXEDTICINO 12
Software Architecture
https://martinfowler.com/articles/microservices/images/sketch.png
Colocated cache
#VOXXEDTICINO 13
Synching with source
Synching with source
Synching with source
Software Architecture
Colocated cache
Distributed cache
#VOXXEDTICINO 14
Synching with source
Software Architecture
15
Caching Patterns
#VOXXEDTICINO 16
Caching Patterns
❖ Cache-aside (Lazy-loading)
❖ Read-Through
❖ Write-Through
❖ Write-Behind (Write-Back)
❖ Refresh-Ahead
❖ Read-Replica
#VOXXEDTICINO 17
Caching Patterns
❖ Cache-aside (Lazy-loading)
❖ Read-Through
❖ Write-Through
❖ Write-Behind (Write-Back)
❖ Refresh-Ahead
❖ Read-Replica
#VOXXEDTICINO 18
Caching Patterns
❖ Cache-aside (Lazy-loading)
❖ Read-Through
❖ Write-Through
❖ Write-Behind (Write-Back)
❖ Refresh-Ahead
❖ Read-Replica
@Service
@CacheConfig(cacheNames={"person"})
public class PersonService {
private final PersonRepository repository;
public PersonService(PersonRepository repository) {
this.repository = repository;
}
@Cacheable(unless="#result == null")
public Optional<Person> findById(Long id) {
return repository.findById(id);
}
@Cacheable(unless="#result == null")
public List<Person> findAll() {
return repository.findAll();
}
@CachePut(key = "#result.id", unless = "#result == null")
public Person save(Person Person) {
return repository.save(Person);
}
@CacheEvict
public void deleteById(Long id) {
repository.deleteById(id);
}
@CacheEvict
public void deleteAll() {
repository.deleteAll();
}
}
#VOXXEDTICINO 19
Caching Patterns
❖ Cache-aside (Lazy-loading)
❖ Read-Through
❖ Write-Through
❖ Write-Behind (Write-Back)
❖ Refresh-Ahead
❖ Read-Replica
#VOXXEDTICINO 20
Caching Patterns
❖ Cache-aside (Lazy-loading)
❖ Read-Through
❖ Write-Through
❖ Write-Behind (Write-Back)
❖ Refresh-Ahead
❖ Read-Replica
#VOXXEDTICINO 21
Caching Patterns
❖ Cache-aside (Lazy-loading)
❖ Read-Through
❖ Write-Through
❖ Write-Behind (Write-Back)
❖ Refresh-Ahead
❖ Read-Replica
#VOXXEDTICINO 22
Caching Patterns
❖ Cache-aside (Lazy-loading)
❖ Read-Through
❖ Write-Through
❖ Write-Behind (Write-Back)
❖ Refresh-Ahead
❖ Read-Replica
#VOXXEDTICINO 23
Caching Patterns
❖ Cache-aside (Lazy-loading)
❖ Read-Through
❖ Write-Through
❖ Write-Behind (Write-Back)
❖ Refresh-Ahead
❖ Read-Replica
24
Demo
#VOXXEDTICINO 25
Demo
★ Cache Provider
redisGears
Implementation details…
❏ Serverless Engine
Q&A
#VOXXEDTICINO 27
Redis Enterprise Real-Time Data Platform
Hashes
Bitmaps
Strings
Bit field
Streams
Hyperloglog
Sorted Sets
Sets
Geospatial
Redis Core Redis Modules
Lists
Linear Scalability HA Geo-Distribution
Durability Backup & Restore Tiered-Memory Access Security
Multi-Tenant
Data Structures
BloomFilter
Search
Graph
TimeSeries
AI
JSON
Gears
Grazie!
l.fugaro@gmail.com
@foogaro
@foogaro
https:/
/www.linkedin.com/in/luigifugaro/

Contenu connexe

Similaire à Caching Patterns for lazy devs for lazy loading - Luigi Fugaro VDTJAN23

Mobile Web Application Development (An Insight)
Mobile Web Application Development (An Insight)Mobile Web Application Development (An Insight)
Mobile Web Application Development (An Insight)Naveen Krishnamurthy
 
Developer's Guide to JavaScript and Web Cryptography
Developer's Guide to JavaScript and Web CryptographyDeveloper's Guide to JavaScript and Web Cryptography
Developer's Guide to JavaScript and Web CryptographyKevin Hakanson
 
AstroLabs_Academy_Learning_to_Code-Coding_Bootcamp_Day1.pdf
AstroLabs_Academy_Learning_to_Code-Coding_Bootcamp_Day1.pdfAstroLabs_Academy_Learning_to_Code-Coding_Bootcamp_Day1.pdf
AstroLabs_Academy_Learning_to_Code-Coding_Bootcamp_Day1.pdfFarHanWasif1
 
DockerCon EU 2015: Day 1 General Session
DockerCon EU 2015: Day 1 General SessionDockerCon EU 2015: Day 1 General Session
DockerCon EU 2015: Day 1 General SessionDocker, Inc.
 
Docker - Der Wal in der Kiste
Docker - Der Wal in der KisteDocker - Der Wal in der Kiste
Docker - Der Wal in der KisteUlrich Krause
 
Html5 workshop part 1
Html5 workshop part 1Html5 workshop part 1
Html5 workshop part 1NAILBITER
 
Cloud-Native .Net des applications containerisées .Net sur Linux, Windows e...
 Cloud-Native .Net des applications containerisées .Net sur Linux, Windows e... Cloud-Native .Net des applications containerisées .Net sur Linux, Windows e...
Cloud-Native .Net des applications containerisées .Net sur Linux, Windows e...VMware Tanzu
 
Apache Flex and the imperfect Web
Apache Flex and the imperfect WebApache Flex and the imperfect Web
Apache Flex and the imperfect Webmasuland
 
Docker in development (Story)
Docker in development (Story)Docker in development (Story)
Docker in development (Story)Quan Nguyen
 
ITKonekt 2023: The Busy Platform Engineers Guide to API Gateways
ITKonekt 2023: The Busy Platform Engineers Guide to API GatewaysITKonekt 2023: The Busy Platform Engineers Guide to API Gateways
ITKonekt 2023: The Busy Platform Engineers Guide to API GatewaysDaniel Bryant
 
Front End Development | Introduction
Front End Development | IntroductionFront End Development | Introduction
Front End Development | IntroductionJohnTaieb
 
Bahrain ch9 introduction to docker 5th birthday
Bahrain ch9 introduction to docker 5th birthday Bahrain ch9 introduction to docker 5th birthday
Bahrain ch9 introduction to docker 5th birthday Walid Shaari
 
Ask Us Anything: Dries Buytaert and Team Tell All on Drupal 8
Ask Us Anything: Dries Buytaert and Team Tell All on Drupal 8Ask Us Anything: Dries Buytaert and Team Tell All on Drupal 8
Ask Us Anything: Dries Buytaert and Team Tell All on Drupal 8Acquia
 

Similaire à Caching Patterns for lazy devs for lazy loading - Luigi Fugaro VDTJAN23 (20)

Mobile Web Application Development (An Insight)
Mobile Web Application Development (An Insight)Mobile Web Application Development (An Insight)
Mobile Web Application Development (An Insight)
 
Developer's Guide to JavaScript and Web Cryptography
Developer's Guide to JavaScript and Web CryptographyDeveloper's Guide to JavaScript and Web Cryptography
Developer's Guide to JavaScript and Web Cryptography
 
AstroLabs_Academy_Learning_to_Code-Coding_Bootcamp_Day1.pdf
AstroLabs_Academy_Learning_to_Code-Coding_Bootcamp_Day1.pdfAstroLabs_Academy_Learning_to_Code-Coding_Bootcamp_Day1.pdf
AstroLabs_Academy_Learning_to_Code-Coding_Bootcamp_Day1.pdf
 
DockerCon EU 2015: Day 1 General Session
DockerCon EU 2015: Day 1 General SessionDockerCon EU 2015: Day 1 General Session
DockerCon EU 2015: Day 1 General Session
 
Docker - Der Wal in der Kiste
Docker - Der Wal in der KisteDocker - Der Wal in der Kiste
Docker - Der Wal in der Kiste
 
Html5 workshop part 1
Html5 workshop part 1Html5 workshop part 1
Html5 workshop part 1
 
Cloud-Native .Net des applications containerisées .Net sur Linux, Windows e...
 Cloud-Native .Net des applications containerisées .Net sur Linux, Windows e... Cloud-Native .Net des applications containerisées .Net sur Linux, Windows e...
Cloud-Native .Net des applications containerisées .Net sur Linux, Windows e...
 
Web summit.pptx
Web summit.pptxWeb summit.pptx
Web summit.pptx
 
Apache Flex and the imperfect Web
Apache Flex and the imperfect WebApache Flex and the imperfect Web
Apache Flex and the imperfect Web
 
Docker in development (Story)
Docker in development (Story)Docker in development (Story)
Docker in development (Story)
 
DevCon5 (July 2014) - Acision SDK
DevCon5 (July 2014) - Acision SDKDevCon5 (July 2014) - Acision SDK
DevCon5 (July 2014) - Acision SDK
 
ITKonekt 2023: The Busy Platform Engineers Guide to API Gateways
ITKonekt 2023: The Busy Platform Engineers Guide to API GatewaysITKonekt 2023: The Busy Platform Engineers Guide to API Gateways
ITKonekt 2023: The Busy Platform Engineers Guide to API Gateways
 
susanta_resume
susanta_resumesusanta_resume
susanta_resume
 
resume
resumeresume
resume
 
TechDayConf Edition 1 - 2020
TechDayConf Edition 1 -  2020TechDayConf Edition 1 -  2020
TechDayConf Edition 1 - 2020
 
VUC 24-May-2013 - Crocodile
VUC 24-May-2013 - CrocodileVUC 24-May-2013 - Crocodile
VUC 24-May-2013 - Crocodile
 
Front End Development | Introduction
Front End Development | IntroductionFront End Development | Introduction
Front End Development | Introduction
 
Dmeeker Finala
Dmeeker FinalaDmeeker Finala
Dmeeker Finala
 
Bahrain ch9 introduction to docker 5th birthday
Bahrain ch9 introduction to docker 5th birthday Bahrain ch9 introduction to docker 5th birthday
Bahrain ch9 introduction to docker 5th birthday
 
Ask Us Anything: Dries Buytaert and Team Tell All on Drupal 8
Ask Us Anything: Dries Buytaert and Team Tell All on Drupal 8Ask Us Anything: Dries Buytaert and Team Tell All on Drupal 8
Ask Us Anything: Dries Buytaert and Team Tell All on Drupal 8
 

Plus de Luigi Fugaro

Ottimizzare le performance dell'API Server K8s come utilizzare cache e eventi...
Ottimizzare le performance dell'API Server K8s come utilizzare cache e eventi...Ottimizzare le performance dell'API Server K8s come utilizzare cache e eventi...
Ottimizzare le performance dell'API Server K8s come utilizzare cache e eventi...Luigi Fugaro
 
Sharp Coding 2023 - Luigi Fugaro - ACRE.pdf
Sharp Coding 2023 - Luigi Fugaro - ACRE.pdfSharp Coding 2023 - Luigi Fugaro - ACRE.pdf
Sharp Coding 2023 - Luigi Fugaro - ACRE.pdfLuigi Fugaro
 
Red Hat Summit Connect 2023 - Redis Enterprise, the engine of Generative AI
Red Hat Summit Connect 2023 - Redis Enterprise, the engine of Generative AIRed Hat Summit Connect 2023 - Redis Enterprise, the engine of Generative AI
Red Hat Summit Connect 2023 - Redis Enterprise, the engine of Generative AILuigi Fugaro
 
Unleashing the Power of Vector Search in .NET - DotNETConf2024.pdf
Unleashing the Power of Vector Search in .NET - DotNETConf2024.pdfUnleashing the Power of Vector Search in .NET - DotNETConf2024.pdf
Unleashing the Power of Vector Search in .NET - DotNETConf2024.pdfLuigi Fugaro
 
Unleashing the Power of Vector Search in .NET - SharpCoding2024.pdf
Unleashing the Power of Vector Search in .NET - SharpCoding2024.pdfUnleashing the Power of Vector Search in .NET - SharpCoding2024.pdf
Unleashing the Power of Vector Search in .NET - SharpCoding2024.pdfLuigi Fugaro
 
Codemotion Milan '22 - Real Time Data - No CRDTs, no party!
Codemotion Milan '22 - Real Time Data - No CRDTs, no party!Codemotion Milan '22 - Real Time Data - No CRDTs, no party!
Codemotion Milan '22 - Real Time Data - No CRDTs, no party!Luigi Fugaro
 
OpenSlava 2018 - Cloud Native Applications with OpenShift
OpenSlava 2018 - Cloud Native Applications with OpenShiftOpenSlava 2018 - Cloud Native Applications with OpenShift
OpenSlava 2018 - Cloud Native Applications with OpenShiftLuigi Fugaro
 
Redis - Non solo cache
Redis - Non solo cacheRedis - Non solo cache
Redis - Non solo cacheLuigi Fugaro
 
JDV for Codemotion Rome 2017
JDV for Codemotion Rome 2017JDV for Codemotion Rome 2017
JDV for Codemotion Rome 2017Luigi Fugaro
 
2.5tier Javaday (italian)
2.5tier Javaday (italian)2.5tier Javaday (italian)
2.5tier Javaday (italian)Luigi Fugaro
 

Plus de Luigi Fugaro (10)

Ottimizzare le performance dell'API Server K8s come utilizzare cache e eventi...
Ottimizzare le performance dell'API Server K8s come utilizzare cache e eventi...Ottimizzare le performance dell'API Server K8s come utilizzare cache e eventi...
Ottimizzare le performance dell'API Server K8s come utilizzare cache e eventi...
 
Sharp Coding 2023 - Luigi Fugaro - ACRE.pdf
Sharp Coding 2023 - Luigi Fugaro - ACRE.pdfSharp Coding 2023 - Luigi Fugaro - ACRE.pdf
Sharp Coding 2023 - Luigi Fugaro - ACRE.pdf
 
Red Hat Summit Connect 2023 - Redis Enterprise, the engine of Generative AI
Red Hat Summit Connect 2023 - Redis Enterprise, the engine of Generative AIRed Hat Summit Connect 2023 - Redis Enterprise, the engine of Generative AI
Red Hat Summit Connect 2023 - Redis Enterprise, the engine of Generative AI
 
Unleashing the Power of Vector Search in .NET - DotNETConf2024.pdf
Unleashing the Power of Vector Search in .NET - DotNETConf2024.pdfUnleashing the Power of Vector Search in .NET - DotNETConf2024.pdf
Unleashing the Power of Vector Search in .NET - DotNETConf2024.pdf
 
Unleashing the Power of Vector Search in .NET - SharpCoding2024.pdf
Unleashing the Power of Vector Search in .NET - SharpCoding2024.pdfUnleashing the Power of Vector Search in .NET - SharpCoding2024.pdf
Unleashing the Power of Vector Search in .NET - SharpCoding2024.pdf
 
Codemotion Milan '22 - Real Time Data - No CRDTs, no party!
Codemotion Milan '22 - Real Time Data - No CRDTs, no party!Codemotion Milan '22 - Real Time Data - No CRDTs, no party!
Codemotion Milan '22 - Real Time Data - No CRDTs, no party!
 
OpenSlava 2018 - Cloud Native Applications with OpenShift
OpenSlava 2018 - Cloud Native Applications with OpenShiftOpenSlava 2018 - Cloud Native Applications with OpenShift
OpenSlava 2018 - Cloud Native Applications with OpenShift
 
Redis - Non solo cache
Redis - Non solo cacheRedis - Non solo cache
Redis - Non solo cache
 
JDV for Codemotion Rome 2017
JDV for Codemotion Rome 2017JDV for Codemotion Rome 2017
JDV for Codemotion Rome 2017
 
2.5tier Javaday (italian)
2.5tier Javaday (italian)2.5tier Javaday (italian)
2.5tier Javaday (italian)
 

Dernier

Ukraine War presentation: KNOW THE BASICS
Ukraine War presentation: KNOW THE BASICSUkraine War presentation: KNOW THE BASICS
Ukraine War presentation: KNOW THE BASICSAishani27
 
Dubai Call Girls Wifey O52&786472 Call Girls Dubai
Dubai Call Girls Wifey O52&786472 Call Girls DubaiDubai Call Girls Wifey O52&786472 Call Girls Dubai
Dubai Call Girls Wifey O52&786472 Call Girls Dubaihf8803863
 
Brighton SEO | April 2024 | Data Storytelling
Brighton SEO | April 2024 | Data StorytellingBrighton SEO | April 2024 | Data Storytelling
Brighton SEO | April 2024 | Data StorytellingNeil Barnes
 
Indian Call Girls in Abu Dhabi O5286O24O8 Call Girls in Abu Dhabi By Independ...
Indian Call Girls in Abu Dhabi O5286O24O8 Call Girls in Abu Dhabi By Independ...Indian Call Girls in Abu Dhabi O5286O24O8 Call Girls in Abu Dhabi By Independ...
Indian Call Girls in Abu Dhabi O5286O24O8 Call Girls in Abu Dhabi By Independ...dajasot375
 
Industrialised data - the key to AI success.pdf
Industrialised data - the key to AI success.pdfIndustrialised data - the key to AI success.pdf
Industrialised data - the key to AI success.pdfLars Albertsson
 
Delhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip CallDelhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Callshivangimorya083
 
VIP High Profile Call Girls Amravati Aarushi 8250192130 Independent Escort Se...
VIP High Profile Call Girls Amravati Aarushi 8250192130 Independent Escort Se...VIP High Profile Call Girls Amravati Aarushi 8250192130 Independent Escort Se...
VIP High Profile Call Girls Amravati Aarushi 8250192130 Independent Escort Se...Suhani Kapoor
 
Market Analysis in the 5 Largest Economic Countries in Southeast Asia.pdf
Market Analysis in the 5 Largest Economic Countries in Southeast Asia.pdfMarket Analysis in the 5 Largest Economic Countries in Southeast Asia.pdf
Market Analysis in the 5 Largest Economic Countries in Southeast Asia.pdfRachmat Ramadhan H
 
20240419 - Measurecamp Amsterdam - SAM.pdf
20240419 - Measurecamp Amsterdam - SAM.pdf20240419 - Measurecamp Amsterdam - SAM.pdf
20240419 - Measurecamp Amsterdam - SAM.pdfHuman37
 
꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Call
꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Call꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Call
꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Callshivangimorya083
 
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130Suhani Kapoor
 
Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...
Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...
Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...Jack DiGiovanna
 
{Pooja: 9892124323 } Call Girl in Mumbai | Jas Kaur Rate 4500 Free Hotel Del...
{Pooja:  9892124323 } Call Girl in Mumbai | Jas Kaur Rate 4500 Free Hotel Del...{Pooja:  9892124323 } Call Girl in Mumbai | Jas Kaur Rate 4500 Free Hotel Del...
{Pooja: 9892124323 } Call Girl in Mumbai | Jas Kaur Rate 4500 Free Hotel Del...Pooja Nehwal
 
100-Concepts-of-AI by Anupama Kate .pptx
100-Concepts-of-AI by Anupama Kate .pptx100-Concepts-of-AI by Anupama Kate .pptx
100-Concepts-of-AI by Anupama Kate .pptxAnupama Kate
 
Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝soniya singh
 
Delhi Call Girls Punjabi Bagh 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls Punjabi Bagh 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip CallDelhi Call Girls Punjabi Bagh 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls Punjabi Bagh 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Callshivangimorya083
 
Unveiling Insights: The Role of a Data Analyst
Unveiling Insights: The Role of a Data AnalystUnveiling Insights: The Role of a Data Analyst
Unveiling Insights: The Role of a Data AnalystSamantha Rae Coolbeth
 

Dernier (20)

Ukraine War presentation: KNOW THE BASICS
Ukraine War presentation: KNOW THE BASICSUkraine War presentation: KNOW THE BASICS
Ukraine War presentation: KNOW THE BASICS
 
Dubai Call Girls Wifey O52&786472 Call Girls Dubai
Dubai Call Girls Wifey O52&786472 Call Girls DubaiDubai Call Girls Wifey O52&786472 Call Girls Dubai
Dubai Call Girls Wifey O52&786472 Call Girls Dubai
 
Brighton SEO | April 2024 | Data Storytelling
Brighton SEO | April 2024 | Data StorytellingBrighton SEO | April 2024 | Data Storytelling
Brighton SEO | April 2024 | Data Storytelling
 
Indian Call Girls in Abu Dhabi O5286O24O8 Call Girls in Abu Dhabi By Independ...
Indian Call Girls in Abu Dhabi O5286O24O8 Call Girls in Abu Dhabi By Independ...Indian Call Girls in Abu Dhabi O5286O24O8 Call Girls in Abu Dhabi By Independ...
Indian Call Girls in Abu Dhabi O5286O24O8 Call Girls in Abu Dhabi By Independ...
 
Industrialised data - the key to AI success.pdf
Industrialised data - the key to AI success.pdfIndustrialised data - the key to AI success.pdf
Industrialised data - the key to AI success.pdf
 
꧁❤ Aerocity Call Girls Service Aerocity Delhi ❤꧂ 9999965857 ☎️ Hard And Sexy ...
꧁❤ Aerocity Call Girls Service Aerocity Delhi ❤꧂ 9999965857 ☎️ Hard And Sexy ...꧁❤ Aerocity Call Girls Service Aerocity Delhi ❤꧂ 9999965857 ☎️ Hard And Sexy ...
꧁❤ Aerocity Call Girls Service Aerocity Delhi ❤꧂ 9999965857 ☎️ Hard And Sexy ...
 
Delhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip CallDelhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
 
VIP High Profile Call Girls Amravati Aarushi 8250192130 Independent Escort Se...
VIP High Profile Call Girls Amravati Aarushi 8250192130 Independent Escort Se...VIP High Profile Call Girls Amravati Aarushi 8250192130 Independent Escort Se...
VIP High Profile Call Girls Amravati Aarushi 8250192130 Independent Escort Se...
 
Market Analysis in the 5 Largest Economic Countries in Southeast Asia.pdf
Market Analysis in the 5 Largest Economic Countries in Southeast Asia.pdfMarket Analysis in the 5 Largest Economic Countries in Southeast Asia.pdf
Market Analysis in the 5 Largest Economic Countries in Southeast Asia.pdf
 
20240419 - Measurecamp Amsterdam - SAM.pdf
20240419 - Measurecamp Amsterdam - SAM.pdf20240419 - Measurecamp Amsterdam - SAM.pdf
20240419 - Measurecamp Amsterdam - SAM.pdf
 
꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Call
꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Call꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Call
꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Call
 
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
 
Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...
Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...
Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...
 
{Pooja: 9892124323 } Call Girl in Mumbai | Jas Kaur Rate 4500 Free Hotel Del...
{Pooja:  9892124323 } Call Girl in Mumbai | Jas Kaur Rate 4500 Free Hotel Del...{Pooja:  9892124323 } Call Girl in Mumbai | Jas Kaur Rate 4500 Free Hotel Del...
{Pooja: 9892124323 } Call Girl in Mumbai | Jas Kaur Rate 4500 Free Hotel Del...
 
100-Concepts-of-AI by Anupama Kate .pptx
100-Concepts-of-AI by Anupama Kate .pptx100-Concepts-of-AI by Anupama Kate .pptx
100-Concepts-of-AI by Anupama Kate .pptx
 
Deep Generative Learning for All - The Gen AI Hype (Spring 2024)
Deep Generative Learning for All - The Gen AI Hype (Spring 2024)Deep Generative Learning for All - The Gen AI Hype (Spring 2024)
Deep Generative Learning for All - The Gen AI Hype (Spring 2024)
 
Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝
 
Delhi Call Girls Punjabi Bagh 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls Punjabi Bagh 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip CallDelhi Call Girls Punjabi Bagh 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls Punjabi Bagh 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
 
Unveiling Insights: The Role of a Data Analyst
Unveiling Insights: The Role of a Data AnalystUnveiling Insights: The Role of a Data Analyst
Unveiling Insights: The Role of a Data Analyst
 
VIP Call Girls Service Charbagh { Lucknow Call Girls Service 9548273370 } Boo...
VIP Call Girls Service Charbagh { Lucknow Call Girls Service 9548273370 } Boo...VIP Call Girls Service Charbagh { Lucknow Call Girls Service 9548273370 } Boo...
VIP Call Girls Service Charbagh { Lucknow Call Girls Service 9548273370 } Boo...
 

Caching Patterns for lazy devs for lazy loading - Luigi Fugaro VDTJAN23

  • 1. Caching patterns for lazy devs for lazy loading Luigi Fugaro Solution Architect @Redis
  • 2. More than 20 years of experience in IT. I started my career in 1998 as a webmaster doing HTML, JavaScript, Applets, and some graphics with Paint Shop Pro. I then switched to Delphi, Clipper, Visual Basic, and then he finally started working on real Java projects. I’ve been developing all kinds of web applications, dealing with both backend and frontend frameworks. Jumping from project to project, from company to company, in 2012 I joined Red Hat as a consultant. An amazing experience lasted more than 7 years. Next, I had the privilege to learn all about observability and monitoring with Datadog working with all kind of companies. In 2021 I received a call from Redis, a technology made in Italy, where apps and data merge together and they enjoy it. Luigi Fugaro Solutions Architect luigi.fugaro@redis.com #VOXXEDTICINO 2
  • 3. ❖ Caching is everywhere ❖ Software Architecture ❖ Caching Patterns ❖ Demo ❖ Q&A Agenda #VOXXEDTICINO 3
  • 5. #VOXXEDTICINO 5 Caching is everywhere ❖ The first time I heard about cache, it was about browser cache with Netscape Navigator.
  • 6. #VOXXEDTICINO 6 ❖ The first time I heard about cache, it was about browser cache with Netscape Navigator. ❖ Second time for CPUs, L1&L2 Cache and Cache Mode (Write-Back). Caching is everywhere
  • 7. #VOXXEDTICINO 7 ❖ The first time I heard about cache, it was about browser cache with Netscape Navigator. ❖ Second time for CPUs, L1&L2 Cache and Cache Mode (Write-Back). ❖ Third time for HTTP Server Cache and CDN for “static-content” (images/js/css/…). Caching is everywhere
  • 8. #VOXXEDTICINO 8 ❖ The first time I heard about cache, it was about browser cache with Netscape Navigator. ❖ Second time for CPUs, L1&L2 Cache and Cache Mode (Write-Back). ❖ Third time for HTTP Server Cache and CDN for “static-content” (images/js/css/…). ❖ Session management, One-Time-Password, and so on… Caching is everywhere
  • 9. #VOXXEDTICINO 9 ❖ The first time I heard about cache, it was about browser cache with Netscape Navigator. ❖ Second time for CPUs, L1&L2 Cache and Cache Mode (Write-Back). ❖ Third time for HTTP Server Cache and CDN for “static-content” (images/js/css/…). ❖ Session management, One-Time-Password, and so on… ❖ On backend, L1 Cache (session) and L2 Cache with data access framework such as Hibernate. Caching is everywhere
  • 13. Colocated cache #VOXXEDTICINO 13 Synching with source Synching with source Synching with source Software Architecture
  • 14. Colocated cache Distributed cache #VOXXEDTICINO 14 Synching with source Software Architecture
  • 16. #VOXXEDTICINO 16 Caching Patterns ❖ Cache-aside (Lazy-loading) ❖ Read-Through ❖ Write-Through ❖ Write-Behind (Write-Back) ❖ Refresh-Ahead ❖ Read-Replica
  • 17. #VOXXEDTICINO 17 Caching Patterns ❖ Cache-aside (Lazy-loading) ❖ Read-Through ❖ Write-Through ❖ Write-Behind (Write-Back) ❖ Refresh-Ahead ❖ Read-Replica
  • 18. #VOXXEDTICINO 18 Caching Patterns ❖ Cache-aside (Lazy-loading) ❖ Read-Through ❖ Write-Through ❖ Write-Behind (Write-Back) ❖ Refresh-Ahead ❖ Read-Replica @Service @CacheConfig(cacheNames={"person"}) public class PersonService { private final PersonRepository repository; public PersonService(PersonRepository repository) { this.repository = repository; } @Cacheable(unless="#result == null") public Optional<Person> findById(Long id) { return repository.findById(id); } @Cacheable(unless="#result == null") public List<Person> findAll() { return repository.findAll(); } @CachePut(key = "#result.id", unless = "#result == null") public Person save(Person Person) { return repository.save(Person); } @CacheEvict public void deleteById(Long id) { repository.deleteById(id); } @CacheEvict public void deleteAll() { repository.deleteAll(); } }
  • 19. #VOXXEDTICINO 19 Caching Patterns ❖ Cache-aside (Lazy-loading) ❖ Read-Through ❖ Write-Through ❖ Write-Behind (Write-Back) ❖ Refresh-Ahead ❖ Read-Replica
  • 20. #VOXXEDTICINO 20 Caching Patterns ❖ Cache-aside (Lazy-loading) ❖ Read-Through ❖ Write-Through ❖ Write-Behind (Write-Back) ❖ Refresh-Ahead ❖ Read-Replica
  • 21. #VOXXEDTICINO 21 Caching Patterns ❖ Cache-aside (Lazy-loading) ❖ Read-Through ❖ Write-Through ❖ Write-Behind (Write-Back) ❖ Refresh-Ahead ❖ Read-Replica
  • 22. #VOXXEDTICINO 22 Caching Patterns ❖ Cache-aside (Lazy-loading) ❖ Read-Through ❖ Write-Through ❖ Write-Behind (Write-Back) ❖ Refresh-Ahead ❖ Read-Replica
  • 23. #VOXXEDTICINO 23 Caching Patterns ❖ Cache-aside (Lazy-loading) ❖ Read-Through ❖ Write-Through ❖ Write-Behind (Write-Back) ❖ Refresh-Ahead ❖ Read-Replica
  • 25. #VOXXEDTICINO 25 Demo ★ Cache Provider redisGears Implementation details… ❏ Serverless Engine
  • 26. Q&A
  • 27. #VOXXEDTICINO 27 Redis Enterprise Real-Time Data Platform Hashes Bitmaps Strings Bit field Streams Hyperloglog Sorted Sets Sets Geospatial Redis Core Redis Modules Lists Linear Scalability HA Geo-Distribution Durability Backup & Restore Tiered-Memory Access Security Multi-Tenant Data Structures BloomFilter Search Graph TimeSeries AI JSON Gears