18
PROST: A Programmable Structured Peer-to-Peer overlay Network Marius Portmann, S Marius Portmann, Sé bastien Ardon bastien Ardon Patrick S Patrick Sé nac nac University of Queensland, Brisbane, Australia ENSICA Toulouse, France

PROST: A Programmable Structured Peer-to-Peer · PDF filePROST: A Programmable Structured Peer-to-Peer overlay Network Marius Portmann, ... Implementation with CHORD, in java dynamic

Embed Size (px)

Citation preview

Page 1: PROST: A Programmable Structured Peer-to-Peer · PDF filePROST: A Programmable Structured Peer-to-Peer overlay Network Marius Portmann, ... Implementation with CHORD, in java dynamic

PROST: A ProgrammableStructured Peer-to-Peer

overlay NetworkMarius Portmann, SMarius Portmann, Séébastien Ardonbastien Ardon

Patrick SPatrick Séénacnac

University of Queensland, Brisbane, Australia

ENSICA Toulouse, France

Page 2: PROST: A Programmable Structured Peer-to-Peer · PDF filePROST: A Programmable Structured Peer-to-Peer overlay Network Marius Portmann, ... Implementation with CHORD, in java dynamic

Prost: a Programmable structured P2P system

Context: overlay networks

NETWORK

END-HOSTS

OVERLAY

Page 3: PROST: A Programmable Structured Peer-to-Peer · PDF filePROST: A Programmable Structured Peer-to-Peer overlay Network Marius Portmann, ... Implementation with CHORD, in java dynamic

Prost: a Programmable structured P2P system

Structured peer-to-peer systems

Each node assigned and responsible for a chunk of keyEach node assigned and responsible for a chunk of keyspacespaceMapping of resources to key space done using a hashMapping of resources to key space done using a hashfunction (e.g. SHA-1)function (e.g. SHA-1)–– Most famous: Distributed Hash TablesMost famous: Distributed Hash Tables

21280

chunkchunk

keyspace

Page 4: PROST: A Programmable Structured Peer-to-Peer · PDF filePROST: A Programmable Structured Peer-to-Peer overlay Network Marius Portmann, ... Implementation with CHORD, in java dynamic

Prost: a Programmable structured P2P system

Example: DHT with CHORDCircular Circular ID ID space space ((wrapswraps))Each node stores (key,values) for all keysEach node stores (key,values) for all keyssmaller than its node id but greater thansmaller than its node id but greater thanprevious node id.previous node id.When node join/leave key,values areWhen node join/leave key,values aremigrated to neighbor nodesmigrated to neighbor nodeshash function is SHA1: nice uniform randomhash function is SHA1: nice uniform randomoutput (load balancing)output (load balancing)Routing is used Routing is used to to find the node responsiblefind the node responsiblefor a for a particular keyparticular keyA A node node uses «uses « shortcutsshortcuts » » along the along the ring:ring:fingersfingersFingers Fingers are are arranged exponentially startingarranged exponentially startingfrom the node from the node ID.ID.Each node need Each node need to to find the closestfind the closestpredecessor predecessor to to the the destination destination keykeyO(log N) messages O(log N) messages exchanged exchanged for for routingroutingfrom any from any source to source to any any destinationdestinationEach node export simple hash tablesEach node export simple hash tablesmanipulations functions (get/put)manipulations functions (get/put)

4

50

80

60

dest = 787

27

14

keyspace

1427

7 …

50

Node id IP@

Page 5: PROST: A Programmable Structured Peer-to-Peer · PDF filePROST: A Programmable Structured Peer-to-Peer overlay Network Marius Portmann, ... Implementation with CHORD, in java dynamic

Prost: a Programmable structured P2P system

Structured P2P applications

Cooperative File System (CFS)Cooperative File System (CFS)–– File storage, uses CHORD at the block levelFile storage, uses CHORD at the block level

PASTPAST–– large-scale, Internet-based, global storage utility that provides scalability, highlarge-scale, Internet-based, global storage utility that provides scalability, high

availability, persistence and securityavailability, persistence and securityI3I3–– Communication primitive (indirection) based on CHORDCommunication primitive (indirection) based on CHORD

SCRIBESCRIBE–– scalable application-level multicast infrastructure, event notification infrastructurescalable application-level multicast infrastructure, event notification infrastructure

SplitStreamSplitStream–– High-bandwidth content distribution system based on application-level multicastHigh-bandwidth content distribution system based on application-level multicast

BAYEUXBAYEUX–– application-level multicast built on top of Tapestryapplication-level multicast built on top of Tapestry

OCEANSTOREOCEANSTORE–– persistent and resilient data storagepersistent and resilient data storage

Page 6: PROST: A Programmable Structured Peer-to-Peer · PDF filePROST: A Programmable Structured Peer-to-Peer overlay Network Marius Portmann, ... Implementation with CHORD, in java dynamic

Prost: a Programmable structured P2P system

PROST ideaProliferation of new Proliferation of new ““DHTDHT””-based applications, each with-based applications, each withtheir own topologytheir own topology–– Re-inventing the wheelRe-inventing the wheel

One network per application!One network per application!–– Overhead: topology maintenanceOverhead: topology maintenance

Idea: share the topology, routing and topologyIdea: share the topology, routing and topologymaintenance between applicationsmaintenance between applications–– Common DHT APICommon DHT API

Not enough: most applications need more than DHTNot enough: most applications need more than DHTDynamically deploy application code on end-nodesDynamically deploy application code on end-nodes(peers)(peers)–– Take the programmable network paradigm to the peer-to-peerTake the programmable network paradigm to the peer-to-peer

layerlayer–– Allow to deploy new applications on a large scale, by leveragingAllow to deploy new applications on a large scale, by leveraging

an existing peer basean existing peer base

Page 7: PROST: A Programmable Structured Peer-to-Peer · PDF filePROST: A Programmable Structured Peer-to-Peer overlay Network Marius Portmann, ... Implementation with CHORD, in java dynamic

Prost: a Programmable structured P2P system

A Layered model of structured p2p

Dabek, F. et al, “Towards a common API for structured P2P overlays”, IPTPS’03

Page 8: PROST: A Programmable Structured Peer-to-Peer · PDF filePROST: A Programmable Structured Peer-to-Peer overlay Network Marius Portmann, ... Implementation with CHORD, in java dynamic

Prost: a Programmable structured P2P system

PROST

Started as an enhanced DHTStarted as an enhanced DHT–– Adding functionalities to DHTAdding functionalities to DHT–– Problem to maintain consistency and versioningProblem to maintain consistency and versioning

Why not use DOLR?Why not use DOLR?–– Objects residing on peers to provide applicationObjects residing on peers to provide application

functionalitiesfunctionalitiesmust be previously deployedmust be previously deployed

Solution: dynamically deploy objects into peers,Solution: dynamically deploy objects into peers,on-demandon-demand

Page 9: PROST: A Programmable Structured Peer-to-Peer · PDF filePROST: A Programmable Structured Peer-to-Peer overlay Network Marius Portmann, ... Implementation with CHORD, in java dynamic

Prost: a Programmable structured P2P system

Node architecture

Key -based Routing Layer (KBR )

Peerlet Manager

Peerlet Peerlet Peerlet

Programmable Peer Layer

User

Interface

Component

User

Interface

Component

Page 10: PROST: A Programmable Structured Peer-to-Peer · PDF filePROST: A Programmable Structured Peer-to-Peer overlay Network Marius Portmann, ... Implementation with CHORD, in java dynamic

Prost: a Programmable structured P2P system

Two types of applications

KBR

Application

(Peerlet)

. . . KBRKBR

Application

(Peerlet)

KBR

Application

(Peerlet)

. . . KBRKBR

Application

(Peerlet)

Application

(Peerlet)

(a)

(b)

End-node applications: file sharing, storage, etc

Per-hop applications: multicast communication, etc

Page 11: PROST: A Programmable Structured Peer-to-Peer · PDF filePROST: A Programmable Structured Peer-to-Peer overlay Network Marius Portmann, ... Implementation with CHORD, in java dynamic

Prost: a Programmable structured P2P system

PROST messages

DST KEY: destination key (ID) for this messageDST KEY: destination key (ID) for this messageAPP ID: unique application-specific IDAPP ID: unique application-specific IDAPP TYPE: 1: end-node application, 0: per-hopAPP TYPE: 1: end-node application, 0: per-hopapplicationapplication–– Analogy to Router Alert IP header fieldAnalogy to Router Alert IP header field

Peerlet Code Locator: where to download the code ifPeerlet Code Locator: where to download the code ifneededneededApplication Data: application-specific data, e.g. get/putApplication Data: application-specific data, e.g. get/putoperation and parametersoperation and parameters

dst key app id app typepeerlet

code locatorapplication data

Page 12: PROST: A Programmable Structured Peer-to-Peer · PDF filePROST: A Programmable Structured Peer-to-Peer overlay Network Marius Portmann, ... Implementation with CHORD, in java dynamic

Prost: a Programmable structured P2P system

PROST API

Based on Based on Dabek Dabek et al. et al. ““Towards a common APITowards a common APIfor structured P2P overlaysfor structured P2P overlays””–– route(k,route(k,msgmsg,,nextHopHintnextHopHint):): send a message send a message

to destination key kto destination key k–– forward(k,forward(k,msgmsg,,nextHopnextHop):): upcall to peerlet at upcall to peerlet at

intermediate nodesintermediate nodes–– deliver(k,deliver(k,msgmsg))–– Plus access to local routing information:Plus access to local routing information:

local_lookuplocal_lookup((……), ), neighbour_setneighbour_set((……),),replicaSetreplicaSet((……), update(), update(……), range(), range(……))

Page 13: PROST: A Programmable Structured Peer-to-Peer · PDF filePROST: A Programmable Structured Peer-to-Peer overlay Network Marius Portmann, ... Implementation with CHORD, in java dynamic

Prost: a Programmable structured P2P system

Typical operationdst key = 78App ID = ‘P2PTV v1.9’App TYPE = ‘1’Peerlet code locator = ‘https://secure.p2ptv.com/cgi?code-currentApp DATA: addReceiver(4,…)

4

50

80

60

7

27

14

PROST NETWORK

appType=1? appID installed?

yes

download and install peerlets

no

forward(78,appData,60)

yes

P2PTVpeerlet route(80,60,appData)

deliver(78,appData)

Page 14: PROST: A Programmable Structured Peer-to-Peer · PDF filePROST: A Programmable Structured Peer-to-Peer overlay Network Marius Portmann, ... Implementation with CHORD, in java dynamic

Prost: a Programmable structured P2P system

Node security policies

Security policies are configured in eachSecurity policies are configured in eachnodenode–– allow/deny peerlets to be installed, usingallow/deny peerlets to be installed, using

peerlet provider identitypeerlet provider identityapplication IDapplication IDlocal policy (deny/allow all)local policy (deny/allow all)

Allow graceful degradation of the serviceAllow graceful degradation of the service–– if peerlet denied installation, try first node inif peerlet denied installation, try first node in

replicaSet replicaSet (recursively)(recursively)

Page 15: PROST: A Programmable Structured Peer-to-Peer · PDF filePROST: A Programmable Structured Peer-to-Peer overlay Network Marius Portmann, ... Implementation with CHORD, in java dynamic

Prost: a Programmable structured P2P system

Challenges

Similar to programmable networks:Similar to programmable networks:–– resource managementresource management

admission controladmission control–– securitysecurity

trust model, code authenticationtrust model, code authenticationsandboxingsandboxinguse to Crypto-based IDsuse to Crypto-based IDs

New to p2p-based New to p2p-based ““activeactive”” networking networking–– dynamicity of execution environment: nodes join anddynamicity of execution environment: nodes join and

leaveleaveprocess migration?process migration?

Page 16: PROST: A Programmable Structured Peer-to-Peer · PDF filePROST: A Programmable Structured Peer-to-Peer overlay Network Marius Portmann, ... Implementation with CHORD, in java dynamic

Prost: a Programmable structured P2P system

Implementation

Implementation with CHORD, in javaImplementation with CHORD, in javadynamic code execution through network classdynamic code execution through network classloaderloaderNo resource management, plan to use existingNo resource management, plan to use existingsystem such as system such as KaffeOSKaffeOS–– support the OS abstraction of support the OS abstraction of processprocess–– process separationprocess separation–– precise memory and CPU accountingprecise memory and CPU accounting

No process migration, for the moment considerNo process migration, for the moment considerprocess are statelessprocess are stateless

Page 17: PROST: A Programmable Structured Peer-to-Peer · PDF filePROST: A Programmable Structured Peer-to-Peer overlay Network Marius Portmann, ... Implementation with CHORD, in java dynamic

Prost: a Programmable structured P2P system

Future work

further investigate the use of strong verifiablefurther investigate the use of strong verifiableidentitiesidentitiesadmission control, resource managementadmission control, resource management–– use results from the AN communityuse results from the AN community

develop and promote PROST as a P2Pdevelop and promote PROST as a P2Presearch experimentation platformresearch experimentation platform–– implementation using the Bamboo DHTimplementation using the Bamboo DHT–– large scale deployment over large scale deployment over planetlabplanetlab

Page 18: PROST: A Programmable Structured Peer-to-Peer · PDF filePROST: A Programmable Structured Peer-to-Peer overlay Network Marius Portmann, ... Implementation with CHORD, in java dynamic

Prost: a Programmable structured P2P system

questions questions