2. Peer to Peer Middleware
Automatic placement and subsequent location of the distributed
objects managed by peer to peer systems
Third generation of peer to peer systems provide middleware for
application independent management of distributed resources
Objective
Place resources on participating nodes that are widely spread over
the Internet
Route messages to them on behalf of clients
Hide location of resources from the clients
Satisfy the requirements of availability, trust, load-balancing and
locality
3. Requirements
Functional requirements
Allow clients to find and communicate with all resources
Add/Remove of resources by the clients
Add/Remove hosts by the clients
Interface to application programmers should be simple and
independent of types of distributed resources
Non functional requirements
Global Scalability
Load balancing
Optimization for local interaction between neighboring peers
Accommodation to highly dynamic host availability
Security of data
Anonymity, deniability and resistance to censorship
4. Routing Overlay
Definition
- A distributed algorithm for middleware to route requests from any
client to a host that holds the object to which the request is
addressed
It locates nodes and objects
Any node can access any object by routing request through a sequence
of nodes with the knowledge of locating the destination object
GUID (Global User ID) – opaque identifier is used as names, but do
not contain location information
Client should submit the request including object’s GUID to the
routing overlay – to route the request to a node where the object
resides
5. Task of overlay routing
1. Routing of requests to objects
2. Insertion of objects
3. Deletion of objects
4. Node addition and removal
Tasks of client
1. Specify GUID and an operation to the routing overlay
2. Provide a new resource after computing its GUID
3. Remove a resource
4. Join or leave the network
When client publishes new resource, it calculates GUID and ask the
routing overlay to publish it
Routing overlay publishes the resource by storing the resource in the
node whose GUID is closest to the resource GUID
6. Distributed hash table (DHT) – to construct overlay network and the
overlay nodes are connected over existing network (underlay
network)
7. Basic programming interfaces for DHT
Put(GUID,data) – publish an object with GUID. Data is stored in all
the nodes which are responsible for replica
Remove(GUID) – remove all the replicas of object with GUID
Get(GUID) – retrieve the data associated with GUID
GUIDs are hashes of shared resources and the associated data is the
IP address of client sharing that resource.
8. Distributed object location and routing
DOLR layer maintains the mapping between GUIDs and the
addresses of the nodes at which replicas of the objects are located
DOLR layer routes the requests to the nearest available replica.
Programming interface for DOLR
publish(GUID)
unpublish(GUID)
sendToObj(msg, GUID, [n]) – send message to n replicas of object
Advantages of DHT
Scalabiltiy and all are ideal candidates for web scale storage
Resistant to node failures
Extensive data replication