SlideShare a Scribd company logo
1 of 22
Download to read offline
Module:
Content Exchange
ResNetLab on Tour
Agenda
➔ Bitswap: Content Exchange Protocol
● Modular architecture
● Common Request Patterns
● Bitswap’s operation
➔ 1:1 Exchanges with Graphsync
➔ Bitswap vs. Graphsync
Content in
IPFS
● Content is chunked in blocks
● Blocks are abstraction serialized
information
● Blocks are uniquely identified by a
Content IDentifier (CID, i.e. hash of the
block)
● Structured as a DAG (link of blocks),
IPLD graphs
File
..
CID1 CID2 CID3
CONTENT ADDRESSING CONTENT DISCOVERY
& ROUTING
CONTENT EXCHANGE
● Chunking
● Linking Chunks
in Merkle DAGs
● From Data to
Data Structures with IPLD
● Anatomy of the IPFS CID
● Routing & Provider
Records
● DHT-based Routing
● Gossip-based Routing
● Bitswap
● GraphSync
MUTABLE NAMES &
MESSAGE DELIVERY
● Dynamic Data
● IPNS
● PubSub
● CRDTs
IPFS Components
a
● Bitswap is a message-oriented
protocol to exchange blocks in a
P2P network.
● Bitswap is IPFS’
content-exchange protocol.
Bitswap’s Modular
Architecture
Bitswap’s Modular
Architecture
● Bitswap is a message-oriented
protocol to exchange blocks in a
P2P network.
● Bitswap is IPFS’
content-exchange protocol.
Bitswap’s Modular
Architecture
● Bitswap is a message-oriented
protocol to exchange blocks in a
P2P network.
● Bitswap is IPFS’
content-exchange protocol.
Bitswap’s Modular
Architecture
● Bitswap is a message-oriented
protocol to exchange blocks in a
P2P network.
● Bitswap is IPFS’
content-exchange protocol.
Bitswap’s Modular
Architecture
● Bitswap is a message-oriented
protocol to exchange blocks in a
P2P network.
● Bitswap is IPFS’
content-exchange protocol.
● IPFS asks Bitswap for blocks
● Bitswap fetches blocks from the
network
● Message-oriented protocol:
○ Requests: WANT-HAVE / WANT-BLOCK
/ CANCEL
○ Responses: HAVE / BLOCK /
DONT_HAVE
IPFS
Blockstore
Bitswap
The IPFS Example
Bitswap
Operation
Common Retrieval Patterns
How content is requested affects the operation of Bitswap
(what blocks are requested, in what order, and how the DAG is traversed)
Level 1
Level 2
Level 3
Request all nodes at each
level of a DAG (eg a file)
web
web/page
web/page/doc.html
Request nodes down a DAG
(eg web/page/doc.html)
<contents>
Bitswap
Discovery
● Broadcast WANT to connected
Peers
● If there’s no response, ask DHT
who has root CID
WANT-
HAVE
CID1
WANT
CID1
WANT-
HAVE
CID1
Providers CID1
DHT
Connected Peers
Bitswap
Sessions
● Peers who respond are added to
the Session
● Subsequent requests are sent
only to peers in the session
HAVE
(CID1)
HAVE
(CID1)
Provider CID1
DHT
Connected Peers
● HAVE message
○ Sometimes we don’t want a
whole block
○ We just want to know who has
a block (eg for discovery)
● Two kinds of WANT messages
○ want-have
○ want-block
● If the block is small enough,
send the whole block (instead
of sending HAVE)
Root Block
RTT
want-have CID1?
Peer A Peer B Peer C Peer D
HAVE CID1 ✓
want-block CID1 ▫
Block (CID1) ▧
HAVE CID1 ✓
HAVE CID1 ✓
Discovery:
Ask who has
CID1
Peer B has
CID1
Request block
from Peer B
Peer C & D
have CID1
Peer B
sends block
Subsequent
Requests
● DONT_HAVE message
○ Allows peer to indicate that it
does NOT have a block
○ Requester can set a flag to tell
responder to send DONT_HAVE
in response to want-block or
want-have
● Requests:
○ want-block
○ want-have
● Respond with combination of
○ HAVE, DONT_HAVE
○ block
Peer A sends
either
- want-block ▫ -
want-have ?
for each CID
that it wants
▫▫▫?
????
???▫
▫▫??
????
??▫▫
▧▧✗✓
✓✓✗✓
✗✓✓▧
▧▧✓✓
✗✓✓▧
▧▧✓✓
Peers B, C & D
respond with
- Block ▧
- HAVE ✓
- DONT_HAVE ✗
for each CID
Peer A Peer B Peer C Peer D
Ledger
Wantlist
● Nodes send WANT messages to
peers
● Each node remembers the want
list for each of its peers
● The wantlist is discarded when
the peer disconnects
WANT
CID1
1
WANT
CID2
1 2
Block
(CID1)
1 2
Block
(CID1)
Peer A Peer B
Peer B
remembers
Peer A’s
wantlist
Peer B
receives
Block (CID1)
Peer B
removes
CID1 from
wantlist for
Peer A
A
A
A
Peer B
sends Block
(CID1) to
Peer A
Wantlist
CANCEL
● Nodes send WANT
messages to peers
● Each node remembers the
want list for each of its
peers
● The wantlist is discarded
when the peer disconnects
WANT
CID1
1
WANT
CID2
1 2
Block
(CID1)
1 2
CANCEL
(CID1)
Peer A Peer B
A
A
A
Peer B
remembers
Peer A’s
wantlist
Peer B
receives
Block (CID1)
Peer B
removes
CID1 from
wantlist for
Peer A
Peer B
sends Block
(CID1) to
Peer A
CONTENT ADDRESSING CONTENT DISCOVERY
& ROUTING
CONTENT EXCHANGE
● Chunking
● Linking Chunks
in Merkle DAGs
● From Data to
Data Structures with IPLD
● Anatomy of the IPFS CID
● Routing & Provider
Records
● DHT-based Routing
● Gossip-based Routing
● Bitswap
● GraphSync
MUTABLE NAMES &
MESSAGE DELIVERY
● Dynamic Data
● IPNS
● PubSub
● CRDTs
IPFS Components
a
Graphsync
Operation
Single CID + Metadata
Several Blocks
● Request-response protocol to synchronize
graphs across peers.
● Uses IPLD selectors to request the blocks
of the graph to be exchanged
○ IPLD is a decentralized data
structure (DAG structure)
○ Selectors identify a subset of nodes
in the structure.
● 1:1 stream exchange (content is not
exchanged block by block like in Bitswap)
○ 1:1 exchanges in IPFS
○ Exchange of blockchain information
and user data in Filecoin
Graphsync vs. Bitswap
Bitswap Graphsync
Protocol type Message-oriented Request-Response
Content exchange Block by block Stream
Request patterns CID Path
/ipfs/<path_to>/cid
IPLD Selector
/sel/<path>/<cid>/*
Multi-path download Yes No, 1:1 exchange
Use cases File-sharing / download
Block exchange
Accelerate content routing
File sharing / download
Blockchain sync
Large dataset sync
Thank you for watching
Reach out in case you have questions or comments!
Bitswap’s modular
architecture
● Bitswap is a message-oriented
protocol to exchange blocks in a
P2P network.
● Bitswap is IPFS’
content-exchange protocol.

More Related Content

What's hot

Apache Arrow Workshop at VLDB 2019 / BOSS Session
Apache Arrow Workshop at VLDB 2019 / BOSS SessionApache Arrow Workshop at VLDB 2019 / BOSS Session
Apache Arrow Workshop at VLDB 2019 / BOSS SessionWes McKinney
 
The columnar roadmap: Apache Parquet and Apache Arrow
The columnar roadmap: Apache Parquet and Apache ArrowThe columnar roadmap: Apache Parquet and Apache Arrow
The columnar roadmap: Apache Parquet and Apache ArrowJulien Le Dem
 
Introduction to IPFS & Filecoin
Introduction to IPFS & FilecoinIntroduction to IPFS & Filecoin
Introduction to IPFS & FilecoinTinaBregovi
 
Network LACP/Bonding/Teaming with Mikrotik
Network LACP/Bonding/Teaming with MikrotikNetwork LACP/Bonding/Teaming with Mikrotik
Network LACP/Bonding/Teaming with MikrotikGLC Networks
 
BGP Flowspec (RFC5575) Case study and Discussion
BGP Flowspec (RFC5575) Case study and DiscussionBGP Flowspec (RFC5575) Case study and Discussion
BGP Flowspec (RFC5575) Case study and DiscussionAPNIC
 
Apache sqoop with an use case
Apache sqoop with an use caseApache sqoop with an use case
Apache sqoop with an use caseDavin Abraham
 
Apache Arrow: In Theory, In Practice
Apache Arrow: In Theory, In PracticeApache Arrow: In Theory, In Practice
Apache Arrow: In Theory, In PracticeDremio Corporation
 
The Dark Web : Hidden Services
The Dark Web : Hidden ServicesThe Dark Web : Hidden Services
The Dark Web : Hidden ServicesAnshu Singh
 
Using LLVM to accelerate processing of data in Apache Arrow
Using LLVM to accelerate processing of data in Apache ArrowUsing LLVM to accelerate processing of data in Apache Arrow
Using LLVM to accelerate processing of data in Apache ArrowDataWorks Summit
 
Comparison of SRv6 Extensions uSID, SRv6+, C-SRH
Comparison of SRv6 Extensions uSID, SRv6+, C-SRHComparison of SRv6 Extensions uSID, SRv6+, C-SRH
Comparison of SRv6 Extensions uSID, SRv6+, C-SRHKentaro Ebisawa
 
The columnar roadmap: Apache Parquet and Apache Arrow
The columnar roadmap: Apache Parquet and Apache ArrowThe columnar roadmap: Apache Parquet and Apache Arrow
The columnar roadmap: Apache Parquet and Apache ArrowDataWorks Summit
 
Big Data Security with Hadoop
Big Data Security with HadoopBig Data Security with Hadoop
Big Data Security with HadoopCloudera, Inc.
 
Sparkler - Spark Crawler
Sparkler - Spark Crawler Sparkler - Spark Crawler
Sparkler - Spark Crawler Thamme Gowda
 
Mum bandwidth management and qos
Mum   bandwidth management and qosMum   bandwidth management and qos
Mum bandwidth management and qosTeav Sovandara
 
A comparison of segment routing data-plane encodings
A comparison of segment routing data-plane encodingsA comparison of segment routing data-plane encodings
A comparison of segment routing data-plane encodingsGunter Van de Velde
 
Introduction to Apache Sqoop
Introduction to Apache SqoopIntroduction to Apache Sqoop
Introduction to Apache SqoopAvkash Chauhan
 
Hdp developer apache spark using python (lab guide) by hortonworks university...
Hdp developer apache spark using python (lab guide) by hortonworks university...Hdp developer apache spark using python (lab guide) by hortonworks university...
Hdp developer apache spark using python (lab guide) by hortonworks university...ssusercda69b
 

What's hot (20)

Detailed iSCSI presentation
Detailed iSCSI presentationDetailed iSCSI presentation
Detailed iSCSI presentation
 
Apache Arrow Workshop at VLDB 2019 / BOSS Session
Apache Arrow Workshop at VLDB 2019 / BOSS SessionApache Arrow Workshop at VLDB 2019 / BOSS Session
Apache Arrow Workshop at VLDB 2019 / BOSS Session
 
The columnar roadmap: Apache Parquet and Apache Arrow
The columnar roadmap: Apache Parquet and Apache ArrowThe columnar roadmap: Apache Parquet and Apache Arrow
The columnar roadmap: Apache Parquet and Apache Arrow
 
Tor Network
Tor NetworkTor Network
Tor Network
 
Introduction to IPFS & Filecoin
Introduction to IPFS & FilecoinIntroduction to IPFS & Filecoin
Introduction to IPFS & Filecoin
 
Network LACP/Bonding/Teaming with Mikrotik
Network LACP/Bonding/Teaming with MikrotikNetwork LACP/Bonding/Teaming with Mikrotik
Network LACP/Bonding/Teaming with Mikrotik
 
HDFS Erasure Coding in Action
HDFS Erasure Coding in Action HDFS Erasure Coding in Action
HDFS Erasure Coding in Action
 
BGP Flowspec (RFC5575) Case study and Discussion
BGP Flowspec (RFC5575) Case study and DiscussionBGP Flowspec (RFC5575) Case study and Discussion
BGP Flowspec (RFC5575) Case study and Discussion
 
Apache sqoop with an use case
Apache sqoop with an use caseApache sqoop with an use case
Apache sqoop with an use case
 
Apache Arrow: In Theory, In Practice
Apache Arrow: In Theory, In PracticeApache Arrow: In Theory, In Practice
Apache Arrow: In Theory, In Practice
 
The Dark Web : Hidden Services
The Dark Web : Hidden ServicesThe Dark Web : Hidden Services
The Dark Web : Hidden Services
 
Using LLVM to accelerate processing of data in Apache Arrow
Using LLVM to accelerate processing of data in Apache ArrowUsing LLVM to accelerate processing of data in Apache Arrow
Using LLVM to accelerate processing of data in Apache Arrow
 
Comparison of SRv6 Extensions uSID, SRv6+, C-SRH
Comparison of SRv6 Extensions uSID, SRv6+, C-SRHComparison of SRv6 Extensions uSID, SRv6+, C-SRH
Comparison of SRv6 Extensions uSID, SRv6+, C-SRH
 
The columnar roadmap: Apache Parquet and Apache Arrow
The columnar roadmap: Apache Parquet and Apache ArrowThe columnar roadmap: Apache Parquet and Apache Arrow
The columnar roadmap: Apache Parquet and Apache Arrow
 
Big Data Security with Hadoop
Big Data Security with HadoopBig Data Security with Hadoop
Big Data Security with Hadoop
 
Sparkler - Spark Crawler
Sparkler - Spark Crawler Sparkler - Spark Crawler
Sparkler - Spark Crawler
 
Mum bandwidth management and qos
Mum   bandwidth management and qosMum   bandwidth management and qos
Mum bandwidth management and qos
 
A comparison of segment routing data-plane encodings
A comparison of segment routing data-plane encodingsA comparison of segment routing data-plane encodings
A comparison of segment routing data-plane encodings
 
Introduction to Apache Sqoop
Introduction to Apache SqoopIntroduction to Apache Sqoop
Introduction to Apache Sqoop
 
Hdp developer apache spark using python (lab guide) by hortonworks university...
Hdp developer apache spark using python (lab guide) by hortonworks university...Hdp developer apache spark using python (lab guide) by hortonworks university...
Hdp developer apache spark using python (lab guide) by hortonworks university...
 

Similar to Module: Content Exchange in IPFS

Module: Beyond bitswap
Module: Beyond bitswapModule: Beyond bitswap
Module: Beyond bitswapIoannis Psaras
 
brief introduction of drbd in SLE12SP2
brief introduction of drbd in SLE12SP2brief introduction of drbd in SLE12SP2
brief introduction of drbd in SLE12SP2Nick Wang
 
Module: InterPlanetary Linked Data (IPLD)
Module: InterPlanetary Linked Data (IPLD)Module: InterPlanetary Linked Data (IPLD)
Module: InterPlanetary Linked Data (IPLD)Ioannis Psaras
 
2019.06.27 Intro to Ceph
2019.06.27 Intro to Ceph2019.06.27 Intro to Ceph
2019.06.27 Intro to CephCeph Community
 
A Brief Introduction of TiDB (Percona Live)
A Brief Introduction of TiDB (Percona Live)A Brief Introduction of TiDB (Percona Live)
A Brief Introduction of TiDB (Percona Live)PingCAP
 
Hadoop architecture meetup
Hadoop architecture meetupHadoop architecture meetup
Hadoop architecture meetupvmoorthy
 
RIO Distribution: Reconstructing the onion - Shyamsundar Ranganathan
RIO Distribution: Reconstructing the onion - Shyamsundar RanganathanRIO Distribution: Reconstructing the onion - Shyamsundar Ranganathan
RIO Distribution: Reconstructing the onion - Shyamsundar RanganathanGluster.org
 
Basics of Network Layer and Transport Layer
Basics of Network Layer and Transport LayerBasics of Network Layer and Transport Layer
Basics of Network Layer and Transport LayerRubal Sagwal
 
Machine Learning + Graph Databases for Better Recommendations V1 08/06/2022
Machine Learning + Graph Databases for Better Recommendations V1 08/06/2022Machine Learning + Graph Databases for Better Recommendations V1 08/06/2022
Machine Learning + Graph Databases for Better Recommendations V1 08/06/2022ArangoDB Database
 
SolrCloud in Public Cloud: Scaling Compute Independently from Storage - Ilan ...
SolrCloud in Public Cloud: Scaling Compute Independently from Storage - Ilan ...SolrCloud in Public Cloud: Scaling Compute Independently from Storage - Ilan ...
SolrCloud in Public Cloud: Scaling Compute Independently from Storage - Ilan ...Lucidworks
 
FOSDEM MySQL and Friends Devroom
FOSDEM MySQL and Friends DevroomFOSDEM MySQL and Friends Devroom
FOSDEM MySQL and Friends DevroomMorgan Tocker
 
Machine Learning + Graph Databases for Better Recommendations
Machine Learning + Graph Databases for Better RecommendationsMachine Learning + Graph Databases for Better Recommendations
Machine Learning + Graph Databases for Better RecommendationsChristopherWoodward16
 
NoSQL document oriented data access for .net systems with postgresql and marten
NoSQL document oriented data access for .net systems with postgresql and martenNoSQL document oriented data access for .net systems with postgresql and marten
NoSQL document oriented data access for .net systems with postgresql and martenBojan Veljanovski
 
BCHGraz - Meetup #10 - DASH (digital cash) by Valentin Kalinov
BCHGraz - Meetup #10 - DASH (digital cash) by Valentin KalinovBCHGraz - Meetup #10 - DASH (digital cash) by Valentin Kalinov
BCHGraz - Meetup #10 - DASH (digital cash) by Valentin KalinovBlockchainHub Graz
 
A Day in the Life of a Druid Implementor and Druid's Roadmap
A Day in the Life of a Druid Implementor and Druid's RoadmapA Day in the Life of a Druid Implementor and Druid's Roadmap
A Day in the Life of a Druid Implementor and Druid's RoadmapItai Yaffe
 
Internet Protocol Deep-Dive
Internet Protocol Deep-DiveInternet Protocol Deep-Dive
Internet Protocol Deep-DiveGLC Networks
 
Druid meetup 2018-03-13
Druid meetup 2018-03-13Druid meetup 2018-03-13
Druid meetup 2018-03-13gianmerlino
 

Similar to Module: Content Exchange in IPFS (20)

Module: Beyond bitswap
Module: Beyond bitswapModule: Beyond bitswap
Module: Beyond bitswap
 
Zipkin
ZipkinZipkin
Zipkin
 
brief introduction of drbd in SLE12SP2
brief introduction of drbd in SLE12SP2brief introduction of drbd in SLE12SP2
brief introduction of drbd in SLE12SP2
 
Module: InterPlanetary Linked Data (IPLD)
Module: InterPlanetary Linked Data (IPLD)Module: InterPlanetary Linked Data (IPLD)
Module: InterPlanetary Linked Data (IPLD)
 
2019.06.27 Intro to Ceph
2019.06.27 Intro to Ceph2019.06.27 Intro to Ceph
2019.06.27 Intro to Ceph
 
A Brief Introduction of TiDB (Percona Live)
A Brief Introduction of TiDB (Percona Live)A Brief Introduction of TiDB (Percona Live)
A Brief Introduction of TiDB (Percona Live)
 
Hadoop architecture meetup
Hadoop architecture meetupHadoop architecture meetup
Hadoop architecture meetup
 
RIO Distribution: Reconstructing the onion - Shyamsundar Ranganathan
RIO Distribution: Reconstructing the onion - Shyamsundar RanganathanRIO Distribution: Reconstructing the onion - Shyamsundar Ranganathan
RIO Distribution: Reconstructing the onion - Shyamsundar Ranganathan
 
Basics of Network Layer and Transport Layer
Basics of Network Layer and Transport LayerBasics of Network Layer and Transport Layer
Basics of Network Layer and Transport Layer
 
Machine Learning + Graph Databases for Better Recommendations V1 08/06/2022
Machine Learning + Graph Databases for Better Recommendations V1 08/06/2022Machine Learning + Graph Databases for Better Recommendations V1 08/06/2022
Machine Learning + Graph Databases for Better Recommendations V1 08/06/2022
 
SolrCloud in Public Cloud: Scaling Compute Independently from Storage - Ilan ...
SolrCloud in Public Cloud: Scaling Compute Independently from Storage - Ilan ...SolrCloud in Public Cloud: Scaling Compute Independently from Storage - Ilan ...
SolrCloud in Public Cloud: Scaling Compute Independently from Storage - Ilan ...
 
FOSDEM MySQL and Friends Devroom
FOSDEM MySQL and Friends DevroomFOSDEM MySQL and Friends Devroom
FOSDEM MySQL and Friends Devroom
 
Machine Learning + Graph Databases for Better Recommendations
Machine Learning + Graph Databases for Better RecommendationsMachine Learning + Graph Databases for Better Recommendations
Machine Learning + Graph Databases for Better Recommendations
 
NoSQL document oriented data access for .net systems with postgresql and marten
NoSQL document oriented data access for .net systems with postgresql and martenNoSQL document oriented data access for .net systems with postgresql and marten
NoSQL document oriented data access for .net systems with postgresql and marten
 
Dash(digital cash)
Dash(digital cash)Dash(digital cash)
Dash(digital cash)
 
BCHGraz - Meetup #10 - DASH (digital cash) by Valentin Kalinov
BCHGraz - Meetup #10 - DASH (digital cash) by Valentin KalinovBCHGraz - Meetup #10 - DASH (digital cash) by Valentin Kalinov
BCHGraz - Meetup #10 - DASH (digital cash) by Valentin Kalinov
 
A Day in the Life of a Druid Implementor and Druid's Roadmap
A Day in the Life of a Druid Implementor and Druid's RoadmapA Day in the Life of a Druid Implementor and Druid's Roadmap
A Day in the Life of a Druid Implementor and Druid's Roadmap
 
Internet Protocol Deep-Dive
Internet Protocol Deep-DiveInternet Protocol Deep-Dive
Internet Protocol Deep-Dive
 
Druid meetup 2018-03-13
Druid meetup 2018-03-13Druid meetup 2018-03-13
Druid meetup 2018-03-13
 
MongoDB FabLab León
MongoDB FabLab LeónMongoDB FabLab León
MongoDB FabLab León
 

Recently uploaded

Call Girls In Saket Delhi 💯Call Us 🔝8264348440🔝
Call Girls In Saket Delhi 💯Call Us 🔝8264348440🔝Call Girls In Saket Delhi 💯Call Us 🔝8264348440🔝
Call Girls In Saket Delhi 💯Call Us 🔝8264348440🔝soniya singh
 
'Future Evolution of the Internet' delivered by Geoff Huston at Everything Op...
'Future Evolution of the Internet' delivered by Geoff Huston at Everything Op...'Future Evolution of the Internet' delivered by Geoff Huston at Everything Op...
'Future Evolution of the Internet' delivered by Geoff Huston at Everything Op...APNIC
 
How is AI changing journalism? (v. April 2024)
How is AI changing journalism? (v. April 2024)How is AI changing journalism? (v. April 2024)
How is AI changing journalism? (v. April 2024)Damian Radcliffe
 
(+971568250507 ))# Young Call Girls in Ajman By Pakistani Call Girls in ...
(+971568250507  ))#  Young Call Girls  in Ajman  By Pakistani Call Girls  in ...(+971568250507  ))#  Young Call Girls  in Ajman  By Pakistani Call Girls  in ...
(+971568250507 ))# Young Call Girls in Ajman By Pakistani Call Girls in ...Escorts Call Girls
 
On Starlink, presented by Geoff Huston at NZNOG 2024
On Starlink, presented by Geoff Huston at NZNOG 2024On Starlink, presented by Geoff Huston at NZNOG 2024
On Starlink, presented by Geoff Huston at NZNOG 2024APNIC
 
AWS Community DAY Albertini-Ellan Cloud Security (1).pptx
AWS Community DAY Albertini-Ellan Cloud Security (1).pptxAWS Community DAY Albertini-Ellan Cloud Security (1).pptx
AWS Community DAY Albertini-Ellan Cloud Security (1).pptxellan12
 
VIP 7001035870 Find & Meet Hyderabad Call Girls LB Nagar high-profile Call Girl
VIP 7001035870 Find & Meet Hyderabad Call Girls LB Nagar high-profile Call GirlVIP 7001035870 Find & Meet Hyderabad Call Girls LB Nagar high-profile Call Girl
VIP 7001035870 Find & Meet Hyderabad Call Girls LB Nagar high-profile Call Girladitipandeya
 
WhatsApp 📞 8448380779 ✅Call Girls In Mamura Sector 66 ( Noida)
WhatsApp 📞 8448380779 ✅Call Girls In Mamura Sector 66 ( Noida)WhatsApp 📞 8448380779 ✅Call Girls In Mamura Sector 66 ( Noida)
WhatsApp 📞 8448380779 ✅Call Girls In Mamura Sector 66 ( Noida)Delhi Call girls
 
✂️ 👅 Independent Andheri Escorts With Room Vashi Call Girls 💃 9004004663
✂️ 👅 Independent Andheri Escorts With Room Vashi Call Girls 💃 9004004663✂️ 👅 Independent Andheri Escorts With Room Vashi Call Girls 💃 9004004663
✂️ 👅 Independent Andheri Escorts With Room Vashi Call Girls 💃 9004004663Call Girls Mumbai
 
Call Girls Service Chandigarh Lucky ❤️ 7710465962 Independent Call Girls In C...
Call Girls Service Chandigarh Lucky ❤️ 7710465962 Independent Call Girls In C...Call Girls Service Chandigarh Lucky ❤️ 7710465962 Independent Call Girls In C...
Call Girls Service Chandigarh Lucky ❤️ 7710465962 Independent Call Girls In C...Sheetaleventcompany
 
Delhi Call Girls Rohini 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls Rohini 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip CallDelhi Call Girls Rohini 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls Rohini 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Callshivangimorya083
 
Call Now ☎ 8264348440 !! Call Girls in Sarai Rohilla Escort Service Delhi N.C.R.
Call Now ☎ 8264348440 !! Call Girls in Sarai Rohilla Escort Service Delhi N.C.R.Call Now ☎ 8264348440 !! Call Girls in Sarai Rohilla Escort Service Delhi N.C.R.
Call Now ☎ 8264348440 !! Call Girls in Sarai Rohilla Escort Service Delhi N.C.R.soniya singh
 
Call Girls In Pratap Nagar Delhi 💯Call Us 🔝8264348440🔝
Call Girls In Pratap Nagar Delhi 💯Call Us 🔝8264348440🔝Call Girls In Pratap Nagar Delhi 💯Call Us 🔝8264348440🔝
Call Girls In Pratap Nagar Delhi 💯Call Us 🔝8264348440🔝soniya singh
 
INDIVIDUAL ASSIGNMENT #3 CBG, PRESENTATION.
INDIVIDUAL ASSIGNMENT #3 CBG, PRESENTATION.INDIVIDUAL ASSIGNMENT #3 CBG, PRESENTATION.
INDIVIDUAL ASSIGNMENT #3 CBG, PRESENTATION.CarlotaBedoya1
 
Pune Airport ( Call Girls ) Pune 6297143586 Hot Model With Sexy Bhabi Ready...
Pune Airport ( Call Girls ) Pune  6297143586  Hot Model With Sexy Bhabi Ready...Pune Airport ( Call Girls ) Pune  6297143586  Hot Model With Sexy Bhabi Ready...
Pune Airport ( Call Girls ) Pune 6297143586 Hot Model With Sexy Bhabi Ready...tanu pandey
 
Hot Call Girls |Delhi |Hauz Khas ☎ 9711199171 Book Your One night Stand
Hot Call Girls |Delhi |Hauz Khas ☎ 9711199171 Book Your One night StandHot Call Girls |Delhi |Hauz Khas ☎ 9711199171 Book Your One night Stand
Hot Call Girls |Delhi |Hauz Khas ☎ 9711199171 Book Your One night Standkumarajju5765
 

Recently uploaded (20)

Call Girls In Saket Delhi 💯Call Us 🔝8264348440🔝
Call Girls In Saket Delhi 💯Call Us 🔝8264348440🔝Call Girls In Saket Delhi 💯Call Us 🔝8264348440🔝
Call Girls In Saket Delhi 💯Call Us 🔝8264348440🔝
 
'Future Evolution of the Internet' delivered by Geoff Huston at Everything Op...
'Future Evolution of the Internet' delivered by Geoff Huston at Everything Op...'Future Evolution of the Internet' delivered by Geoff Huston at Everything Op...
'Future Evolution of the Internet' delivered by Geoff Huston at Everything Op...
 
How is AI changing journalism? (v. April 2024)
How is AI changing journalism? (v. April 2024)How is AI changing journalism? (v. April 2024)
How is AI changing journalism? (v. April 2024)
 
(+971568250507 ))# Young Call Girls in Ajman By Pakistani Call Girls in ...
(+971568250507  ))#  Young Call Girls  in Ajman  By Pakistani Call Girls  in ...(+971568250507  ))#  Young Call Girls  in Ajman  By Pakistani Call Girls  in ...
(+971568250507 ))# Young Call Girls in Ajman By Pakistani Call Girls in ...
 
Rohini Sector 22 Call Girls Delhi 9999965857 @Sabina Saikh No Advance
Rohini Sector 22 Call Girls Delhi 9999965857 @Sabina Saikh No AdvanceRohini Sector 22 Call Girls Delhi 9999965857 @Sabina Saikh No Advance
Rohini Sector 22 Call Girls Delhi 9999965857 @Sabina Saikh No Advance
 
On Starlink, presented by Geoff Huston at NZNOG 2024
On Starlink, presented by Geoff Huston at NZNOG 2024On Starlink, presented by Geoff Huston at NZNOG 2024
On Starlink, presented by Geoff Huston at NZNOG 2024
 
Rohini Sector 6 Call Girls Delhi 9999965857 @Sabina Saikh No Advance
Rohini Sector 6 Call Girls Delhi 9999965857 @Sabina Saikh No AdvanceRohini Sector 6 Call Girls Delhi 9999965857 @Sabina Saikh No Advance
Rohini Sector 6 Call Girls Delhi 9999965857 @Sabina Saikh No Advance
 
AWS Community DAY Albertini-Ellan Cloud Security (1).pptx
AWS Community DAY Albertini-Ellan Cloud Security (1).pptxAWS Community DAY Albertini-Ellan Cloud Security (1).pptx
AWS Community DAY Albertini-Ellan Cloud Security (1).pptx
 
VIP 7001035870 Find & Meet Hyderabad Call Girls LB Nagar high-profile Call Girl
VIP 7001035870 Find & Meet Hyderabad Call Girls LB Nagar high-profile Call GirlVIP 7001035870 Find & Meet Hyderabad Call Girls LB Nagar high-profile Call Girl
VIP 7001035870 Find & Meet Hyderabad Call Girls LB Nagar high-profile Call Girl
 
@9999965857 🫦 Sexy Desi Call Girls Laxmi Nagar 💓 High Profile Escorts Delhi 🫶
@9999965857 🫦 Sexy Desi Call Girls Laxmi Nagar 💓 High Profile Escorts Delhi 🫶@9999965857 🫦 Sexy Desi Call Girls Laxmi Nagar 💓 High Profile Escorts Delhi 🫶
@9999965857 🫦 Sexy Desi Call Girls Laxmi Nagar 💓 High Profile Escorts Delhi 🫶
 
WhatsApp 📞 8448380779 ✅Call Girls In Mamura Sector 66 ( Noida)
WhatsApp 📞 8448380779 ✅Call Girls In Mamura Sector 66 ( Noida)WhatsApp 📞 8448380779 ✅Call Girls In Mamura Sector 66 ( Noida)
WhatsApp 📞 8448380779 ✅Call Girls In Mamura Sector 66 ( Noida)
 
✂️ 👅 Independent Andheri Escorts With Room Vashi Call Girls 💃 9004004663
✂️ 👅 Independent Andheri Escorts With Room Vashi Call Girls 💃 9004004663✂️ 👅 Independent Andheri Escorts With Room Vashi Call Girls 💃 9004004663
✂️ 👅 Independent Andheri Escorts With Room Vashi Call Girls 💃 9004004663
 
Call Girls Service Chandigarh Lucky ❤️ 7710465962 Independent Call Girls In C...
Call Girls Service Chandigarh Lucky ❤️ 7710465962 Independent Call Girls In C...Call Girls Service Chandigarh Lucky ❤️ 7710465962 Independent Call Girls In C...
Call Girls Service Chandigarh Lucky ❤️ 7710465962 Independent Call Girls In C...
 
Delhi Call Girls Rohini 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls Rohini 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip CallDelhi Call Girls Rohini 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls Rohini 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
 
Call Now ☎ 8264348440 !! Call Girls in Sarai Rohilla Escort Service Delhi N.C.R.
Call Now ☎ 8264348440 !! Call Girls in Sarai Rohilla Escort Service Delhi N.C.R.Call Now ☎ 8264348440 !! Call Girls in Sarai Rohilla Escort Service Delhi N.C.R.
Call Now ☎ 8264348440 !! Call Girls in Sarai Rohilla Escort Service Delhi N.C.R.
 
Call Girls In Pratap Nagar Delhi 💯Call Us 🔝8264348440🔝
Call Girls In Pratap Nagar Delhi 💯Call Us 🔝8264348440🔝Call Girls In Pratap Nagar Delhi 💯Call Us 🔝8264348440🔝
Call Girls In Pratap Nagar Delhi 💯Call Us 🔝8264348440🔝
 
(INDIRA) Call Girl Pune Call Now 8250077686 Pune Escorts 24x7
(INDIRA) Call Girl Pune Call Now 8250077686 Pune Escorts 24x7(INDIRA) Call Girl Pune Call Now 8250077686 Pune Escorts 24x7
(INDIRA) Call Girl Pune Call Now 8250077686 Pune Escorts 24x7
 
INDIVIDUAL ASSIGNMENT #3 CBG, PRESENTATION.
INDIVIDUAL ASSIGNMENT #3 CBG, PRESENTATION.INDIVIDUAL ASSIGNMENT #3 CBG, PRESENTATION.
INDIVIDUAL ASSIGNMENT #3 CBG, PRESENTATION.
 
Pune Airport ( Call Girls ) Pune 6297143586 Hot Model With Sexy Bhabi Ready...
Pune Airport ( Call Girls ) Pune  6297143586  Hot Model With Sexy Bhabi Ready...Pune Airport ( Call Girls ) Pune  6297143586  Hot Model With Sexy Bhabi Ready...
Pune Airport ( Call Girls ) Pune 6297143586 Hot Model With Sexy Bhabi Ready...
 
Hot Call Girls |Delhi |Hauz Khas ☎ 9711199171 Book Your One night Stand
Hot Call Girls |Delhi |Hauz Khas ☎ 9711199171 Book Your One night StandHot Call Girls |Delhi |Hauz Khas ☎ 9711199171 Book Your One night Stand
Hot Call Girls |Delhi |Hauz Khas ☎ 9711199171 Book Your One night Stand
 

Module: Content Exchange in IPFS

  • 2. Agenda ➔ Bitswap: Content Exchange Protocol ● Modular architecture ● Common Request Patterns ● Bitswap’s operation ➔ 1:1 Exchanges with Graphsync ➔ Bitswap vs. Graphsync
  • 3. Content in IPFS ● Content is chunked in blocks ● Blocks are abstraction serialized information ● Blocks are uniquely identified by a Content IDentifier (CID, i.e. hash of the block) ● Structured as a DAG (link of blocks), IPLD graphs File .. CID1 CID2 CID3
  • 4. CONTENT ADDRESSING CONTENT DISCOVERY & ROUTING CONTENT EXCHANGE ● Chunking ● Linking Chunks in Merkle DAGs ● From Data to Data Structures with IPLD ● Anatomy of the IPFS CID ● Routing & Provider Records ● DHT-based Routing ● Gossip-based Routing ● Bitswap ● GraphSync MUTABLE NAMES & MESSAGE DELIVERY ● Dynamic Data ● IPNS ● PubSub ● CRDTs IPFS Components a
  • 5. ● Bitswap is a message-oriented protocol to exchange blocks in a P2P network. ● Bitswap is IPFS’ content-exchange protocol. Bitswap’s Modular Architecture
  • 6. Bitswap’s Modular Architecture ● Bitswap is a message-oriented protocol to exchange blocks in a P2P network. ● Bitswap is IPFS’ content-exchange protocol.
  • 7. Bitswap’s Modular Architecture ● Bitswap is a message-oriented protocol to exchange blocks in a P2P network. ● Bitswap is IPFS’ content-exchange protocol.
  • 8. Bitswap’s Modular Architecture ● Bitswap is a message-oriented protocol to exchange blocks in a P2P network. ● Bitswap is IPFS’ content-exchange protocol.
  • 9. Bitswap’s Modular Architecture ● Bitswap is a message-oriented protocol to exchange blocks in a P2P network. ● Bitswap is IPFS’ content-exchange protocol.
  • 10. ● IPFS asks Bitswap for blocks ● Bitswap fetches blocks from the network ● Message-oriented protocol: ○ Requests: WANT-HAVE / WANT-BLOCK / CANCEL ○ Responses: HAVE / BLOCK / DONT_HAVE IPFS Blockstore Bitswap The IPFS Example Bitswap Operation
  • 11. Common Retrieval Patterns How content is requested affects the operation of Bitswap (what blocks are requested, in what order, and how the DAG is traversed) Level 1 Level 2 Level 3 Request all nodes at each level of a DAG (eg a file) web web/page web/page/doc.html Request nodes down a DAG (eg web/page/doc.html) <contents>
  • 12. Bitswap Discovery ● Broadcast WANT to connected Peers ● If there’s no response, ask DHT who has root CID WANT- HAVE CID1 WANT CID1 WANT- HAVE CID1 Providers CID1 DHT Connected Peers
  • 13. Bitswap Sessions ● Peers who respond are added to the Session ● Subsequent requests are sent only to peers in the session HAVE (CID1) HAVE (CID1) Provider CID1 DHT Connected Peers
  • 14. ● HAVE message ○ Sometimes we don’t want a whole block ○ We just want to know who has a block (eg for discovery) ● Two kinds of WANT messages ○ want-have ○ want-block ● If the block is small enough, send the whole block (instead of sending HAVE) Root Block RTT want-have CID1? Peer A Peer B Peer C Peer D HAVE CID1 ✓ want-block CID1 ▫ Block (CID1) ▧ HAVE CID1 ✓ HAVE CID1 ✓ Discovery: Ask who has CID1 Peer B has CID1 Request block from Peer B Peer C & D have CID1 Peer B sends block
  • 15. Subsequent Requests ● DONT_HAVE message ○ Allows peer to indicate that it does NOT have a block ○ Requester can set a flag to tell responder to send DONT_HAVE in response to want-block or want-have ● Requests: ○ want-block ○ want-have ● Respond with combination of ○ HAVE, DONT_HAVE ○ block Peer A sends either - want-block ▫ - want-have ? for each CID that it wants ▫▫▫? ???? ???▫ ▫▫?? ???? ??▫▫ ▧▧✗✓ ✓✓✗✓ ✗✓✓▧ ▧▧✓✓ ✗✓✓▧ ▧▧✓✓ Peers B, C & D respond with - Block ▧ - HAVE ✓ - DONT_HAVE ✗ for each CID Peer A Peer B Peer C Peer D
  • 16. Ledger Wantlist ● Nodes send WANT messages to peers ● Each node remembers the want list for each of its peers ● The wantlist is discarded when the peer disconnects WANT CID1 1 WANT CID2 1 2 Block (CID1) 1 2 Block (CID1) Peer A Peer B Peer B remembers Peer A’s wantlist Peer B receives Block (CID1) Peer B removes CID1 from wantlist for Peer A A A A Peer B sends Block (CID1) to Peer A
  • 17. Wantlist CANCEL ● Nodes send WANT messages to peers ● Each node remembers the want list for each of its peers ● The wantlist is discarded when the peer disconnects WANT CID1 1 WANT CID2 1 2 Block (CID1) 1 2 CANCEL (CID1) Peer A Peer B A A A Peer B remembers Peer A’s wantlist Peer B receives Block (CID1) Peer B removes CID1 from wantlist for Peer A Peer B sends Block (CID1) to Peer A
  • 18. CONTENT ADDRESSING CONTENT DISCOVERY & ROUTING CONTENT EXCHANGE ● Chunking ● Linking Chunks in Merkle DAGs ● From Data to Data Structures with IPLD ● Anatomy of the IPFS CID ● Routing & Provider Records ● DHT-based Routing ● Gossip-based Routing ● Bitswap ● GraphSync MUTABLE NAMES & MESSAGE DELIVERY ● Dynamic Data ● IPNS ● PubSub ● CRDTs IPFS Components a
  • 19. Graphsync Operation Single CID + Metadata Several Blocks ● Request-response protocol to synchronize graphs across peers. ● Uses IPLD selectors to request the blocks of the graph to be exchanged ○ IPLD is a decentralized data structure (DAG structure) ○ Selectors identify a subset of nodes in the structure. ● 1:1 stream exchange (content is not exchanged block by block like in Bitswap) ○ 1:1 exchanges in IPFS ○ Exchange of blockchain information and user data in Filecoin
  • 20. Graphsync vs. Bitswap Bitswap Graphsync Protocol type Message-oriented Request-Response Content exchange Block by block Stream Request patterns CID Path /ipfs/<path_to>/cid IPLD Selector /sel/<path>/<cid>/* Multi-path download Yes No, 1:1 exchange Use cases File-sharing / download Block exchange Accelerate content routing File sharing / download Blockchain sync Large dataset sync
  • 21. Thank you for watching Reach out in case you have questions or comments!
  • 22. Bitswap’s modular architecture ● Bitswap is a message-oriented protocol to exchange blocks in a P2P network. ● Bitswap is IPFS’ content-exchange protocol.