Searching for shared Searching for Shared Resources Resources Important to P2P applications a Two distinct categories: Two distinct categories Client-side searching Server-side searching A server acts as the reservoir of all c地m The greatest advantage is that the user need Client-side searching is limited to the users Connection may be made of only to peers that Faster than server-side searching May send an avalanche of requests and may low down server's services Searching Technique in P2P Chapter 7: P2P Application Models development Searching for content in pure P2P-based model Searching for content in P2P with simple discovery P2P application design Searching for content in P2P with discovery and Both server-side and client-side searching can be adopted Searching for content in P2P with discovery, lookup and content server-based model nly server-side searching can be adopted Case P2P Application Structure of the P2P Application File sharing takes place between two connected peers regardless of file extensIo Three components Listener: Handles requests of incoming peer connections Server: Maintains the database required for the application Browser: Shows results to the peer through a user-friendly interface and acts as an interactive layer for the clien7 哈工大计算机学院 李全龙 Network Application Development P2P Application Development 37 Searching for Shared Resources Important to P2P applications Two distinct categories: Server-side searching A server acts as the reservoir of all information The greatest advantage is that the user need not worry about the location of a file Connection may be made of only to peers that possess required content May send an avalanche of requests and may slow down server’s services 哈工大计算机学院 李全龙 Network Application Development P2P Application Development 38 Searching for Shared Resources Two distinct categories: Client-side searching Comes into play when peers are connected with each other and are communicating without the involvement of any other machine or server Client-side searching is limited to the user’s machine Faster than server-side searching 哈工大计算机学院 李全龙 Network Application Development P2P Application Development 39 Searching Technique in P2P Models Searching for content in pure P2P-based model Client-side searching Searching for content in P2P with simple discovery server-based model Client-side searching also Searching for content in P2P with discovery and lookup server-based model Both server-side and client-side searching can be adopted Searching for content in P2P with discovery, lookup, and content server-based model Only server-side searching can be adopted 哈工大计算机学院 李全龙 Network Application Development P2P Application Development 40 Chapter 7: P2P Application development Chapter goal: P2P application model P2P application design P2P example 哈工大计算机学院 李全龙 Network Application Development P2P Application Development 41 Case P2P Application File sharing takes place between two connected peers regardless of file extensions Three components: Listener: Handles requests of incoming peer connections Server: Maintains the database required for the application Browser: Shows results to the peer through a user-friendly interface and acts as an interactive layer for the client 哈工大计算机学院 李全龙 Network Application Development P2P Application Development 42 Structure of the P2P Application