SlideShare a Scribd company logo
1 of 37
Download to read offline
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 1/37
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 2/37
Breaking REST Chains:
A Fastify & Mercurius Pathway to GraphQL Glory
Luca Del Puppo
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 3/37
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 4/37
Luca Del Puppo
Senior Software Developer
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 5/37
JavaScript enthusiast
TypeScript lover
“Youtuber”
“Writer”
Love sport: running,
hiking
Love animals
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 6/37
Why GraphQL?_
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 7/37
Rest API
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 8/37
Desktop
Browsers
Mobile
Browsers
Other
Browsers
TVs,
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 9/37
SmartWatch
s..
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 10/37
Bill is 22.
He is a Junior Backend
Developer who fights with the
Frontend and Mobile
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 11/37
developers to build a specific
endpoint for every single view,
with just some different fields
but the same logic
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 12/37
Desktop
Browsers
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 13/37
Mobile
Browsers
Other
Browsers
TVs,
SmartWatch
s..
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 14/37
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 15/37
Schema
Queries
Mutations
Subscriptions
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 16/37
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 17/37
You can scale your server "easily"_
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 18/37
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 19/37
But remember
every layer is a cost
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 20/37
Why Mercurius?_
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 21/37
is a high-performance GraphQL adapter for the web
framework
It has many core features and plugins for building world-class
production-ready applications
It supports advanced features out of the box, such as
and Subscriptions
It's entirely Open Source and made available under the MIT license
Fantastic community
Mercurius Fastify
Apollo
Federation specifications
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 22/37
Caching of query parsing and validation
Automatic loader integration to avoid the N+1 problem
Just-In-Time compiler via graphql-jit
Subscriptions
Federation support
Federated subscriptions support
Gateway implementation, including Subscriptions
Batched query support
Customizable persisted queries
Core features_
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 23/37
Today recipe_
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 24/37
. Build a GraphQL server with Mercurius Fastify and JavaScript
2. Convert it to TypeScript
3. Resolve 1+N problem
4. Add Custom Directives or Validations
5. Add Authentication
6. Working with Federation
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 25/37
Let's get our hands dirty_
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 26/37
Conclusion_
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 27/37
Don't hate REST API
Build one use from everyone
Build with Mercurius is a piece of cake
Don't forget, using Mercurius all the Fastify's benefits are there with
you
Be careful with the layers in your Applications
Give the right power to your Frontend Developers
Don't forget to monitor your server
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 28/37
About this presentations_
Slides
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 29/37
Code
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 30/37
Resources to read_
Fastify:
Mercurius:
Nearform Blog:
Backend Caffe:
https://fastify.dev/
https://mercurius.dev/
https://nearform.hashnode.dev/
https://backend.cafe/
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 31/37
Resources to watch_
Nearform:
Adventures in Nodeland:
https://www.youtube.com/@Nearform​
https://www.youtube.com/@adventuresinnodeland
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 32/37
Book_
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 33/37
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 34/37
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 35/37
Luca Del Puppo
@puppo92
Luca Del Puppo
Puppo_92
@puppo
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 36/37
We are hiring
23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory
https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 37/37
Thank you!_
Speaker notes

More Related Content

More from Commit University

More from Commit University (20)

Backstage l'Internal Developer Portal Open Source per una migliore Developer ...
Backstage l'Internal Developer Portal Open Source per una migliore Developer ...Backstage l'Internal Developer Portal Open Source per una migliore Developer ...
Backstage l'Internal Developer Portal Open Source per una migliore Developer ...
 
Prisma the ORM that node was waiting for
Prisma the ORM that node was waiting forPrisma the ORM that node was waiting for
Prisma the ORM that node was waiting for
 
Decision-making for Software Development Teams - Commit University
Decision-making for Software Development Teams - Commit UniversityDecision-making for Software Development Teams - Commit University
Decision-making for Software Development Teams - Commit University
 
Component Design Pattern nei Game Engine.pdf
Component Design Pattern nei Game Engine.pdfComponent Design Pattern nei Game Engine.pdf
Component Design Pattern nei Game Engine.pdf
 
Un viaggio alla scoperta dei Language Models e dell’intelligenza artificiale ...
Un viaggio alla scoperta dei Language Models e dell’intelligenza artificiale ...Un viaggio alla scoperta dei Language Models e dell’intelligenza artificiale ...
Un viaggio alla scoperta dei Language Models e dell’intelligenza artificiale ...
 
Prototipazione Low-Code con AWS Step Functions
Prototipazione Low-Code con AWS Step FunctionsPrototipazione Low-Code con AWS Step Functions
Prototipazione Low-Code con AWS Step Functions
 
KMM survival guide: how to tackle struggles between Kotlin and Swift
KMM survival guide: how to tackle struggles between Kotlin and SwiftKMM survival guide: how to tackle struggles between Kotlin and Swift
KMM survival guide: how to tackle struggles between Kotlin and Swift
 
Da Vuex a Pinia: come fare la migrazione
Da Vuex a Pinia: come fare la migrazioneDa Vuex a Pinia: come fare la migrazione
Da Vuex a Pinia: come fare la migrazione
 
Orchestrare Micro-frontend con micro-lc
Orchestrare Micro-frontend con micro-lcOrchestrare Micro-frontend con micro-lc
Orchestrare Micro-frontend con micro-lc
 
Fastify has defeated Lagacy-Code
Fastify has defeated Lagacy-CodeFastify has defeated Lagacy-Code
Fastify has defeated Lagacy-Code
 
SwiftUI vs UIKit
SwiftUI vs UIKitSwiftUI vs UIKit
SwiftUI vs UIKit
 
Alpine.js: the outsider Javascript framework
Alpine.js: the outsider Javascript frameworkAlpine.js: the outsider Javascript framework
Alpine.js: the outsider Javascript framework
 
Modificazione del comportamento: come la Gamification cattura l'attenzione
Modificazione del comportamento: come la Gamification cattura l'attenzioneModificazione del comportamento: come la Gamification cattura l'attenzione
Modificazione del comportamento: come la Gamification cattura l'attenzione
 
API moderne e real-time per applicazioni innovative
API moderne e real-time per applicazioni innovativeAPI moderne e real-time per applicazioni innovative
API moderne e real-time per applicazioni innovative
 
State manager in Vue.js, from zero to Vuex
State manager in Vue.js, from zero to VuexState manager in Vue.js, from zero to Vuex
State manager in Vue.js, from zero to Vuex
 
La leggenda del Magento senza testa
La leggenda del Magento senza testa La leggenda del Magento senza testa
La leggenda del Magento senza testa
 
Kubernetes: istruzioni per l'uso
Kubernetes: istruzioni per l'usoKubernetes: istruzioni per l'uso
Kubernetes: istruzioni per l'uso
 
Rilasci senza paura (o panico) con Azure DevOps
Rilasci senza paura (o panico) con Azure DevOpsRilasci senza paura (o panico) con Azure DevOps
Rilasci senza paura (o panico) con Azure DevOps
 
Come abbiamo scalato Dazn con micro-architetture
Come abbiamo scalato Dazn con micro-architettureCome abbiamo scalato Dazn con micro-architetture
Come abbiamo scalato Dazn con micro-architetture
 
Software modularity, microservices ed headless platform all in one. Liferay: ...
Software modularity, microservices ed headless platform all in one. Liferay: ...Software modularity, microservices ed headless platform all in one. Liferay: ...
Software modularity, microservices ed headless platform all in one. Liferay: ...
 

Recently uploaded

Hyatt driving innovation and exceptional customer experiences with FIDO passw...
Hyatt driving innovation and exceptional customer experiences with FIDO passw...Hyatt driving innovation and exceptional customer experiences with FIDO passw...
Hyatt driving innovation and exceptional customer experiences with FIDO passw...
FIDO Alliance
 
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc
 

Recently uploaded (20)

AI mind or machine power point presentation
AI mind or machine power point presentationAI mind or machine power point presentation
AI mind or machine power point presentation
 
Extensible Python: Robustness through Addition - PyCon 2024
Extensible Python: Robustness through Addition - PyCon 2024Extensible Python: Robustness through Addition - PyCon 2024
Extensible Python: Robustness through Addition - PyCon 2024
 
Event-Driven Architecture Masterclass: Engineering a Robust, High-performance...
Event-Driven Architecture Masterclass: Engineering a Robust, High-performance...Event-Driven Architecture Masterclass: Engineering a Robust, High-performance...
Event-Driven Architecture Masterclass: Engineering a Robust, High-performance...
 
The Value of Certifying Products for FDO _ Paul at FIDO Alliance.pdf
The Value of Certifying Products for FDO _ Paul at FIDO Alliance.pdfThe Value of Certifying Products for FDO _ Paul at FIDO Alliance.pdf
The Value of Certifying Products for FDO _ Paul at FIDO Alliance.pdf
 
Secure Zero Touch enabled Edge compute with Dell NativeEdge via FDO _ Brad at...
Secure Zero Touch enabled Edge compute with Dell NativeEdge via FDO _ Brad at...Secure Zero Touch enabled Edge compute with Dell NativeEdge via FDO _ Brad at...
Secure Zero Touch enabled Edge compute with Dell NativeEdge via FDO _ Brad at...
 
Hyatt driving innovation and exceptional customer experiences with FIDO passw...
Hyatt driving innovation and exceptional customer experiences with FIDO passw...Hyatt driving innovation and exceptional customer experiences with FIDO passw...
Hyatt driving innovation and exceptional customer experiences with FIDO passw...
 
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
 
Introduction to FIDO Authentication and Passkeys.pptx
Introduction to FIDO Authentication and Passkeys.pptxIntroduction to FIDO Authentication and Passkeys.pptx
Introduction to FIDO Authentication and Passkeys.pptx
 
WebRTC and SIP not just audio and video @ OpenSIPS 2024
WebRTC and SIP not just audio and video @ OpenSIPS 2024WebRTC and SIP not just audio and video @ OpenSIPS 2024
WebRTC and SIP not just audio and video @ OpenSIPS 2024
 
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdf
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdfLinux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdf
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdf
 
Vector Search @ sw2con for slideshare.pptx
Vector Search @ sw2con for slideshare.pptxVector Search @ sw2con for slideshare.pptx
Vector Search @ sw2con for slideshare.pptx
 
JavaScript Usage Statistics 2024 - The Ultimate Guide
JavaScript Usage Statistics 2024 - The Ultimate GuideJavaScript Usage Statistics 2024 - The Ultimate Guide
JavaScript Usage Statistics 2024 - The Ultimate Guide
 
Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...
Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...
Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...
 
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdf
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdfHow Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdf
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdf
 
Where to Learn More About FDO _ Richard at FIDO Alliance.pdf
Where to Learn More About FDO _ Richard at FIDO Alliance.pdfWhere to Learn More About FDO _ Richard at FIDO Alliance.pdf
Where to Learn More About FDO _ Richard at FIDO Alliance.pdf
 
ERP Contender Series: Acumatica vs. Sage Intacct
ERP Contender Series: Acumatica vs. Sage IntacctERP Contender Series: Acumatica vs. Sage Intacct
ERP Contender Series: Acumatica vs. Sage Intacct
 
The Metaverse: Are We There Yet?
The  Metaverse:    Are   We  There  Yet?The  Metaverse:    Are   We  There  Yet?
The Metaverse: Are We There Yet?
 
Collecting & Temporal Analysis of Behavioral Web Data - Tales From The Inside
Collecting & Temporal Analysis of Behavioral Web Data - Tales From The InsideCollecting & Temporal Analysis of Behavioral Web Data - Tales From The Inside
Collecting & Temporal Analysis of Behavioral Web Data - Tales From The Inside
 
Design Guidelines for Passkeys 2024.pptx
Design Guidelines for Passkeys 2024.pptxDesign Guidelines for Passkeys 2024.pptx
Design Guidelines for Passkeys 2024.pptx
 
Introduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdf
Introduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdfIntroduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdf
Introduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdf
 

Breaking REST Chains_ A Fastify & Mercurius Pathway to GraphQL Glory.pdf

  • 1. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 1/37
  • 2. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 2/37 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory Luca Del Puppo
  • 3. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 3/37
  • 4. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 4/37 Luca Del Puppo Senior Software Developer
  • 5. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 5/37 JavaScript enthusiast TypeScript lover “Youtuber” “Writer” Love sport: running, hiking Love animals
  • 6. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 6/37 Why GraphQL?_
  • 7. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 7/37 Rest API
  • 8. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 8/37 Desktop Browsers Mobile Browsers Other Browsers TVs,
  • 9. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 9/37 SmartWatch s..
  • 10. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 10/37 Bill is 22. He is a Junior Backend Developer who fights with the Frontend and Mobile
  • 11. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 11/37 developers to build a specific endpoint for every single view, with just some different fields but the same logic
  • 12. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 12/37 Desktop Browsers
  • 13. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 13/37 Mobile Browsers Other Browsers TVs, SmartWatch s..
  • 14. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 14/37
  • 15. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 15/37 Schema Queries Mutations Subscriptions
  • 16. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 16/37
  • 17. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 17/37 You can scale your server "easily"_
  • 18. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 18/37
  • 19. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 19/37 But remember every layer is a cost
  • 20. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 20/37 Why Mercurius?_
  • 21. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 21/37 is a high-performance GraphQL adapter for the web framework It has many core features and plugins for building world-class production-ready applications It supports advanced features out of the box, such as and Subscriptions It's entirely Open Source and made available under the MIT license Fantastic community Mercurius Fastify Apollo Federation specifications
  • 22. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 22/37 Caching of query parsing and validation Automatic loader integration to avoid the N+1 problem Just-In-Time compiler via graphql-jit Subscriptions Federation support Federated subscriptions support Gateway implementation, including Subscriptions Batched query support Customizable persisted queries Core features_
  • 23. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 23/37 Today recipe_
  • 24. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 24/37 . Build a GraphQL server with Mercurius Fastify and JavaScript 2. Convert it to TypeScript 3. Resolve 1+N problem 4. Add Custom Directives or Validations 5. Add Authentication 6. Working with Federation
  • 25. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 25/37 Let's get our hands dirty_
  • 26. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 26/37 Conclusion_
  • 27. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 27/37 Don't hate REST API Build one use from everyone Build with Mercurius is a piece of cake Don't forget, using Mercurius all the Fastify's benefits are there with you Be careful with the layers in your Applications Give the right power to your Frontend Developers Don't forget to monitor your server
  • 28. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 28/37 About this presentations_ Slides
  • 29. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 29/37 Code
  • 30. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 30/37 Resources to read_ Fastify: Mercurius: Nearform Blog: Backend Caffe: https://fastify.dev/ https://mercurius.dev/ https://nearform.hashnode.dev/ https://backend.cafe/
  • 31. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 31/37 Resources to watch_ Nearform: Adventures in Nodeland: https://www.youtube.com/@Nearform​ https://www.youtube.com/@adventuresinnodeland
  • 32. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 32/37 Book_
  • 33. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 33/37
  • 34. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 34/37
  • 35. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 35/37 Luca Del Puppo @puppo92 Luca Del Puppo Puppo_92 @puppo
  • 36. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 36/37 We are hiring
  • 37. 23/02/24, 10:45 Breaking REST Chains: A Fastify & Mercurius Pathway to GraphQL Glory https://slides.com/puppo92/breaking-rest-chains-a-fastify-mercurius-pathway-to-graphql-glory/fullscreen 37/37 Thank you!_ Speaker notes